# Staircase — full corpus # Agents # Agents The tool registry a client connects to, and the fleet itself — every agent listed by what it does. The roster files every agent under the dimension it works on — the same ones the navigation runs on, plus the router and the agents that build other agents. The router is the way in: nobody memorises the roster, a task is described in plain language, and the router names the specialist and the skills that fit. An agent that changes production behaviour shows its work before acting: a comparison over sample records, a dry run, and a human approval gate on the consequential step. - ## The network - Key services are documented well enough that an agent can rebuild them from scratch. The documentation is the system of record, which is what keeps it honest and current. - Building agents encode how a reliable service gets constructed, so each new runtime agent is assembled from proven patterns rather than designed from nothing. The cost of adding the next agent keeps falling. - An agent that touches production behaviour shows its work first — before-and-after comparisons, dry runs, and human approval gates — so people stay in control of every consequential decision. - Business users launch pipelines, change rules, request exports, and manage copy by writing plain-language requests, work that previously required an engineer running scripts. - Because specialists share the same skills and standards, services built years apart still look and behave like siblings — easier to operate, audit, and hand over. - ## Skills - Packaged, versioned know-how — how to integrate a partner, how to model data, how to test a design — that any agent or engineer picks up. Knowledge is written once and reused everywhere, so it compounds instead of evaporating when a person leaves or a system changes. - ## Registry - One index of every agent and skill, deliberately repository-agnostic: each row names the repository that defines it, so specialists authored in different packages sit side by side in one place. Nobody memorises the roster — describe the task and the router names the specialist. - ## Tools - One tool registry is the single source both transports read, so the stdio entry and the HTTP entry cannot drift apart. - Every tool carries a title, a description, and a per-parameter description written for a model rather than for a reader who already knows the domain. - Query tools are guarded in four layers: comment and literal stripping, multi-statement rejection, a read-only statement allowlist, and an unconditional row cap. - ## Fleet - Agent definitions are compiled from one source into three runtimes, so a behaviour change is written once and lands everywhere. - A router dispatches to specialists rather than one agent carrying every capability. - Skills are separately versioned units an agent composes, not prompt text pasted into a definition. - ## Evaluations - Behavioural fixtures assert exact tool-call arguments, not output similarity, and they run in continuous integration before a deploy. - A conversational agent that stops calling the right tool fails the build rather than degrading quietly once deployed. - Per-conversation model cost is reported to a budget surface, so an agent that becomes expensive is visible as a number. - ## Runtimes - The same registry is served over a standard-input transport, a streaming HTTP transport, and an edge runtime. - Documented, working install paths exist for five separate agent clients — this is a multi-client surface, not a single-vendor integration. - Configuration is environment-supplied, so pointing the surface at a different set of jurisdictions is a configuration change rather than a release. ## Routing The way into the fleet: one agent reads a request and hands it to the specialist that owns the work. - Router Reads the current roster and names which specialist and which skills fit the task, with the reasoning behind the choice. ## Data The records, the schema over them, and what is read back out — ingestion, retrieval, reporting, reconciliation and extracts. - Counterparty document expectations Loads counterparty contact details and document requirements from spreadsheets into the graph store, mapping each requirement onto the governed vocabulary and setting aside anything that does not map. - Data-lake assistant Answers questions over the accumulated loan and partner data in plain language, and draws the chart where a chart is the answer. - Dataset fulfilment Turns an approved data request into a scoped extract — resolving which organisation it belongs to, mapping the requested field names onto the canonical model, and returning either the result directly or a time-limited download link. - Knowledge search Builds reusable retrieval agents that answer from a curated document corpus — embeddings, a search index, a knowledge library, schema and header mapping, reuse of prior decisions, confidence thresholds and a human review loop. - Metric reconciliation Reconciles the same metric across vendors and sources so the figures compare like with like, and records why they differed. - Model curator Guards the shared graph schema, so that every entity type, relationship, property, index, enumeration and required field passes one review and ingestion and query behaviour stay consistent across services. - Pipeline control panel Runs the document-processing pipeline on request: resolves which documents actually exist for a set of records, checks what has already been processed, dispatches only the remainder, replays failures, and confirms the results reached their destination. - Property data exploration Answers questions about public property and business data in plain language — appraisal and parcel records, permits, registered companies, contractor reputation, geographic filters and the schema behind them — by driving the published tool surface rather than writing queries by hand. - Public record ingestion Brings a jurisdiction's public data online: discovers the sources, collects and validates them, loads and reconciles them into the query store, then publishes the jurisdiction's query table and coverage record and wires both into the tool surface. - Question answering Resolves which approved source actually holds a figure, queries it live, and turns the verified answer into a secure, shareable, refreshing report. - Report catalog Builds and maintains the single page where existing reports are registered and found, with a command-line path for registering a new one. - Search to production Takes a retrieval system from a local prototype through to production: the index model, the migration off the local store, historical backfill, live ingestion per source, and the instructions an agent needs to use it. ## Products The borrower conversation and the assistants around it, collecting the credit, assets, liabilities, employment, income and real estate owned that the Products dimension documents. - Application document Generates the completed application document from everything the conversation collected, and takes the borrower's signature on it. - Assets Collects what the borrower holds — deposit and investment accounts, the institution each sits with, and the balance. - Co-borrower invitation Invites a co-borrower into the application and starts their own task set, which is the borrower's set plus the questions only they can answer. - Contact details Collects how to reach the borrower — telephone numbers by kind, and the electronic-mail address the application and its documents are sent to. - Correction Reopens a subject the borrower has already answered so an answer can be changed without restarting the application. - Credit Takes the borrower's consent to a credit enquiry, runs it, and brings the result back into the conversation so the liabilities it reports can be confirmed rather than typed. - Declarations Collects the declaration questions the application requires, and the follow-up detail wherever an answer needs one. - Demographic details Collects the regulated demographic questions, including the borrower's right to decline each of them. - Employment and income Collects employment and the income that comes from it — employer, role, dates, and the pay in the components a lender underwrites: base, overtime, bonus and commission. - Frequently-asked questions Answers a borrower's questions from a curated knowledge base rather than from the model's general knowledge, with the source behind each answer. - Gifts and grants Collects funds given to the borrower rather than held by them — the donor, the relationship, the amount, and whether the funds have arrived. - Liabilities Reviews the debts the credit enquiry reported, corrects them, and collects the ones it did not — the obligations that do not appear on a credit file. - Loan lookup Finds an existing application from what the borrower can remember, so a returning conversation resumes rather than restarts. - Military service Collects service history, which decides eligibility for the loan programmes that depend on it. - Mortgage details Collects the terms of the loan being applied for and of any mortgage already secured on a property the borrower owns — amount, purpose, occupancy and term. - Other income Collects income from every source that is neither employment nor a business the borrower owns — rental income, benefits, pensions, investments, support payments. - Personal identity Opens the application and collects who the borrower is — legal name, date of birth, taxpayer identifier, citizenship and marital status. - Preapproval letter Produces the preapproval letter from the priced application, and refreshes it when the price behind it moves. - Pricing Runs an actual price against the collected loan terms and explains the result in the conversation. - Rate estimate Gives a borrower an indicative rate from a short conversation, before any application exists. - Real estate owned Collects the properties the borrower already owns — address, value, how it is used, and what it earns or costs. - Residency Collects where the borrower lives now and where they lived before, with the dates, so the address history covers the required period without gaps. - Self-employment income Collects income from a business the borrower owns, including contract income reported on its own tax form. - Workspace assistant The assistant inside the internal workspace: answers a reviewer's questions about an application in progress and drafts the message going back to the borrower. ## Providers A vendor integration or a counterparty exchange — a message provider's send-and-feedback loop, a partner's file share, a partner's client list, a third-party measurement console. - File sync Builds the scheduled workflow that copies a configured storage location into an external partner's file share: the infrastructure, a planning and cost gate, per-file workers, an aggregate, and the credential and configuration handling around them. - Marketing stack Orchestrates the whole measurement stack across consoles and code — tag management, analytics, search visibility, advertising linkage, the access each of those needs, and the handoff to whoever verifies it. - Roster workflow Takes each partner's uploaded client list, matches it against the records under management, and returns partner-branded settlement and authorisation paperwork the same day. - Send lifecycle Owns the whole dispatch and feedback loop as one lifecycle: provider setup, routing, the send handoff, delivery events, and ingestion of what comes back. ## Delivery Software being built, packaged, released, deployed or tested — scaffolding an application, distributing it to tenants, implementing a design, triaging what renders wrongly. - Analytics instrumentation Wires tag management into a front end on any of the common frameworks, and works out with the team which user actions are worth tracking. - Application scaffolding Scaffolds complete applications on the standard stack, front end and back end together in one repository, with the shared packages between them. - Design implementation Translates a design into existing interface code, preserving the business logic underneath and locking in the breakpoints. - Design testing Writes the tests that verify an interface renders correctly across phone, tablet and desktop, in whichever of the two lanes fits — mocked specifications for the design itself, or real-device specifications for behaviour. - Interface triage Triages and fixes interface defects: confirms the delta against the design reference, audits recent commits for the override that caused it, applies the smallest correcting change, and strengthens the tests so it cannot return. - Marketplace architecture Architects the multi-tenant platform through which products are packaged, distributed and installed — a central account governing per-customer accounts, a registry of components and releases, and the four ecosystem products underneath it: domain routing, account management, the product deployer and the tenant-side reconciler. - Sharing portals Builds secure external file-sharing portals: hosted sign-in, private folder browsing, per-user grants, administrator-managed accounts, a custom domain, runtime configuration and a design-matched interface. ## Platform What runs underneath: the conversation runtime and its queue, batch workflows, solvers, short links, template inventory, campaign operations and the capability map. - Audience selection Defines who a communication goes to, owning the entry point, the hard suppressions, and the contract by which an eligible population is handed to the runtime that will act on it. - Batch workflows Designs large-scale batch and extract-transform-load workflows with cost gates, throttling, idempotency and a staged test path. - Capability map Knows every internal platform capability — accounts, bootstrap, build, distribution, deployment, reconciliation, persistence, connectivity, translation, product orchestration, rule decisioning and the governed vocabulary — and decides whether a request is served by something already deployed before any infrastructure is written. - Channel assembly Composes audience, template and send capabilities into one deterministic end-to-end channel service — the internal data contracts, candidate generation, scoring, allocation, outputs and runtime validation. - Contact scheduling solver Holds how one deployed scheduling solver actually works — how it prioritises records, selects a contact point, respects capacity, assigns hours, rotates between contact points and labels score tiers — and extends it without inventing a parallel runtime. - Conversation management Manages the fleet around the runtime: the queue a conversation waits in, the configuration each agent runs from, and the tasks raised for a person when a conversation needs one. - Conversation runtime Serves the conversation itself: holds the task set, runs the agent whose turn it is, calls the functions an answer triggers, and writes what was said to the loan record. - Mail campaign operations Operates the deployed mail-campaign workflow: validating the population for a run, launching it, watching it, and reconciling what came back against what was sent. - Message assistant Answers questions about what has been sent to a consumer, and lets a non-technical user propose, revise, or retire a message template through a plain-language review conversation that captures the approved wording. - Rule editor Turns a plain-language request into a concrete change to phone-interaction rules, runs it against sample records to show exactly which numbers would and would not be called, and packages that before-and-after evidence for the rule owner to approve. - Short links Builds the link-shortening and click-telemetry service behind outbound messages: issuing short tokens, storing the link as a graph record, resolving a token through a graph query, redirecting, and publishing a click fact onto the shared event bus. - Solver services Designs and scaffolds optimisation services: a distributed layer that prepares data at scale, a pure solver core, and the infrastructure that wires them together. - Template inventory Builds the systems that keep message templates versioned, reviewed and in step with whatever sends them — the repository layout, the metadata contract, discovery of the source tables, and one-time or recurring synchronisation from the operational store into a version-controlled inventory. ## Creating new agents Agents whose output is another agent — the specification it is written from, the scaffold it is built on, and the evaluation set that gates it. - Assistant builder Designs and implements task-triggered agents on the established runtime pattern — one function receiving events from the work-management surface, conversation state held externally, a model doing the reasoning, and tracing on every turn. - Audit analyser Builds analysers that read pipeline output, apply versioned audit profiles, and emit evidence-backed anomaly records for a person to review. - Operations agent builder Builds the operations agents that drive document and media pipelines: resolving the target environment from what the requester said or from their profile, discovering the deployed stack, starting and watching runs, handling replays and approval gates, and preparing configuration changes as reviewable proposals. - Spend approval Builds the workflow that watches model spend against a threshold, opens an approval task when it is crossed, and raises the limit by a configured increment only after a human completes that task. --- # Creating new agents # Creating new agents Agents whose output is another agent — the specification it is written from, the scaffold it is built on, and the evaluation set that gates it. - Assistant builder Designs and implements task-triggered agents on the established runtime pattern — one function receiving events from the work-management surface, conversation state held externally, a model doing the reasoning, and tracing on every turn. - Audit analyser Builds analysers that read pipeline output, apply versioned audit profiles, and emit evidence-backed anomaly records for a person to review. - Operations agent builder Builds the operations agents that drive document and media pipelines: resolving the target environment from what the requester said or from their profile, discovering the deployed stack, starting and watching runs, handling replays and approval gates, and preparing configuration changes as reviewable proposals. - Spend approval Builds the workflow that watches model spend against a threshold, opens an approval task when it is crossed, and raises the limit by a configured increment only after a human completes that task. --- # Data # Data The records, the schema over them, and what is read back out — ingestion, retrieval, reporting, reconciliation and extracts. - Counterparty document expectationsalso Providers Loads counterparty contact details and document requirements from spreadsheets into the graph store, mapping each requirement onto the governed vocabulary and setting aside anything that does not map. - Data-lake assistant Answers questions over the accumulated loan and partner data in plain language, and draws the chart where a chart is the answer. - Dataset fulfilment Turns an approved data request into a scoped extract — resolving which organisation it belongs to, mapping the requested field names onto the canonical model, and returning either the result directly or a time-limited download link. - Knowledge search Builds reusable retrieval agents that answer from a curated document corpus — embeddings, a search index, a knowledge library, schema and header mapping, reuse of prior decisions, confidence thresholds and a human review loop. - Metric reconciliation Reconciles the same metric across vendors and sources so the figures compare like with like, and records why they differed. - Model curator Guards the shared graph schema, so that every entity type, relationship, property, index, enumeration and required field passes one review and ingestion and query behaviour stay consistent across services. - Pipeline control panel Runs the document-processing pipeline on request: resolves which documents actually exist for a set of records, checks what has already been processed, dispatches only the remainder, replays failures, and confirms the results reached their destination. - Property data exploration Answers questions about public property and business data in plain language — appraisal and parcel records, permits, registered companies, contractor reputation, geographic filters and the schema behind them — by driving the published tool surface rather than writing queries by hand. - Public record ingestion Brings a jurisdiction's public data online: discovers the sources, collects and validates them, loads and reconciles them into the query store, then publishes the jurisdiction's query table and coverage record and wires both into the tool surface. - Question answering Resolves which approved source actually holds a figure, queries it live, and turns the verified answer into a secure, shareable, refreshing report. - Report catalog Builds and maintains the single page where existing reports are registered and found, with a command-line path for registering a new one. - Search to production Takes a retrieval system from a local prototype through to production: the index model, the migration off the local store, historical backfill, live ingestion per source, and the instructions an agent needs to use it. --- # Delivery # Delivery Software being built, packaged, released, deployed or tested — scaffolding an application, distributing it to tenants, implementing a design, triaging what renders wrongly. - Analytics instrumentationalso Providers Wires tag management into a front end on any of the common frameworks, and works out with the team which user actions are worth tracking. - Application scaffolding Scaffolds complete applications on the standard stack, front end and back end together in one repository, with the shared packages between them. - Design implementation Translates a design into existing interface code, preserving the business logic underneath and locking in the breakpoints. - Design testing Writes the tests that verify an interface renders correctly across phone, tablet and desktop, in whichever of the two lanes fits — mocked specifications for the design itself, or real-device specifications for behaviour. - Interface triage Triages and fixes interface defects: confirms the delta against the design reference, audits recent commits for the override that caused it, applies the smallest correcting change, and strengthens the tests so it cannot return. - Marketplace architecture Architects the multi-tenant platform through which products are packaged, distributed and installed — a central account governing per-customer accounts, a registry of components and releases, and the four ecosystem products underneath it: domain routing, account management, the product deployer and the tenant-side reconciler. - Sharing portalsalso Providers Builds secure external file-sharing portals: hosted sign-in, private folder browsing, per-user grants, administrator-managed accounts, a custom domain, runtime configuration and a design-matched interface. --- # Evaluations # Evaluations Behavioural fixtures asserting exact tool-call arguments, run before a deploy. A fixture states the input and the tool call that must result, with its exact arguments. It does not compare output text, because output similarity passes while the agent calls the wrong tool with plausible arguments — which is the failure that matters. The fixtures run in continuous integration before a deploy, so an agent that stops calling the right tool fails the build rather than degrading quietly once deployed. - Behavioural fixtures assert exact tool-call arguments, not output similarity, and they run in continuous integration before a deploy. - A conversational agent that stops calling the right tool fails the build rather than degrading quietly once deployed. - Per-conversation model cost is reported to a budget surface, so an agent that becomes expensive is visible as a number. ## How it works Cost is reported per conversation against a budget surface, which makes an agent that has become expensive visible as a number rather than as a surprise on an invoice. The budget it reports against is the per-environment one in Environment. --- # Fleet # Fleet One agent source compiled to three runtimes, dispatched by a router, composed from separately versioned skills. An agent is defined once and compiled into each runtime it needs to run in, so a behaviour change is written in one place and lands everywhere. The alternative — a definition per runtime — drifts within weeks and drifts silently. Dispatch is by router rather than by one agent carrying every capability. A specialist with a narrow scope is easier to evaluate, easier to fix, and easier to reason about than a general agent whose behaviour depends on which part of a long instruction won. - Agent definitions are compiled from one source into three runtimes, so a behaviour change is written once and lands everywhere. - A router dispatches to specialists rather than one agent carrying every capability. - Skills are separately versioned units an agent composes, not prompt text pasted into a definition. --- # The network # The network Three layers: agents that operate production systems, agents that build them, and the skills both draw on. Key services are documented well enough that an agent can rebuild them from scratch. The documentation is the system of record, which is what keeps it honest and current. The runtime layer is deployed services holding their own memory and telemetry, invoked by external events and operated through the tools a team already has open. The building layer lives in the engineering environment and designs, scaffolds and reviews software — several of its members exist to build runtime agents, which is what makes the network self-expanding. Skills are the packaged know-how both layers draw on. The registry is the index across all three. ## How it works A building agent encodes how a reliable service is constructed, so the next runtime agent is assembled from patterns that already worked rather than designed from nothing, and the cost of the next one keeps falling. Each layer is specified to the level a rebuild needs: a service that cannot be rebuilt from its own specification is one whose specification is not exercised, and a gap in it shows up as a rebuild that does not work. ## Three layers | Layer | What it is | | --- | --- | | Runtime agents | Long-running deployed services that operate on production systems. They hold their own memory and telemetry, are invoked by external events, and are used through the tools an operations team already has open — no engineering involvement to run one. | | Building agents | Specialists that live in the engineering environment and help design, scaffold, and review software. Several exist specifically to build new runtime agents, which is what makes the network self-expanding. | | Skills | Packaged, versioned know-how — how to integrate a partner, how to model data, how to test a design — that any agent or engineer picks up. Knowledge is written once and reused everywhere, so it compounds instead of evaporating when a person leaves or a system changes. | ## The loop 1. A need surfaces in plain language. 1. The router sends it to the right building agents, which pull in the relevant skills. 1. Those agents assemble a new runtime agent from proven patterns. 1. The runtime agent is deployed, used through the tools the team already has open, and registered. 1. Whatever was learned is captured as a skill, making the next agent cheaper to build. ## What holds it together - **Agents that build agents** — Building agents encode how a reliable service gets constructed, so each new runtime agent is assembled from proven patterns rather than designed from nothing. The cost of adding the next agent keeps falling. - **Evidence before action** — An agent that touches production behaviour shows its work first — before-and-after comparisons, dry runs, and human approval gates — so people stay in control of every consequential decision. - **Operations through conversation** — Business users launch pipelines, change rules, request exports, and manage copy by writing plain-language requests, work that previously required an engineer running scripts. - **Consistency at scale** — Because specialists share the same skills and standards, services built years apart still look and behave like siblings — easier to operate, audit, and hand over. --- # Platform # Platform What runs underneath: the conversation runtime and its queue, batch workflows, solvers, short links, template inventory, campaign operations and the capability map. - Audience selectionalso Data Defines who a communication goes to, owning the entry point, the hard suppressions, and the contract by which an eligible population is handed to the runtime that will act on it. - Batch workflows Designs large-scale batch and extract-transform-load workflows with cost gates, throttling, idempotency and a staged test path. - Capability map Knows every internal platform capability — accounts, bootstrap, build, distribution, deployment, reconciliation, persistence, connectivity, translation, product orchestration, rule decisioning and the governed vocabulary — and decides whether a request is served by something already deployed before any infrastructure is written. - Channel assembly Composes audience, template and send capabilities into one deterministic end-to-end channel service — the internal data contracts, candidate generation, scoring, allocation, outputs and runtime validation. - Contact scheduling solver Holds how one deployed scheduling solver actually works — how it prioritises records, selects a contact point, respects capacity, assigns hours, rotates between contact points and labels score tiers — and extends it without inventing a parallel runtime. - Conversation management Manages the fleet around the runtime: the queue a conversation waits in, the configuration each agent runs from, and the tasks raised for a person when a conversation needs one. - Conversation runtime Serves the conversation itself: holds the task set, runs the agent whose turn it is, calls the functions an answer triggers, and writes what was said to the loan record. - Mail campaign operations Operates the deployed mail-campaign workflow: validating the population for a run, launching it, watching it, and reconciling what came back against what was sent. - Message assistant Answers questions about what has been sent to a consumer, and lets a non-technical user propose, revise, or retire a message template through a plain-language review conversation that captures the approved wording. - Rule editor Turns a plain-language request into a concrete change to phone-interaction rules, runs it against sample records to show exactly which numbers would and would not be called, and packages that before-and-after evidence for the rule owner to approve. - Short links Builds the link-shortening and click-telemetry service behind outbound messages: issuing short tokens, storing the link as a graph record, resolving a token through a graph query, redirecting, and publishing a click fact onto the shared event bus. - Solver services Designs and scaffolds optimisation services: a distributed layer that prepares data at scale, a pure solver core, and the infrastructure that wires them together. - Template inventory Builds the systems that keep message templates versioned, reviewed and in step with whatever sends them — the repository layout, the metadata contract, discovery of the source tables, and one-time or recurring synchronisation from the operational store into a version-controlled inventory. --- # Products # Products The borrower conversation and the assistants around it, collecting the credit, assets, liabilities, employment, income and real estate owned that the Products dimension documents. - Application document Generates the completed application document from everything the conversation collected, and takes the borrower's signature on it. - Assets Collects what the borrower holds — deposit and investment accounts, the institution each sits with, and the balance. - Co-borrower invitation Invites a co-borrower into the application and starts their own task set, which is the borrower's set plus the questions only they can answer. - Contact details Collects how to reach the borrower — telephone numbers by kind, and the electronic-mail address the application and its documents are sent to. - Correction Reopens a subject the borrower has already answered so an answer can be changed without restarting the application. - Credit Takes the borrower's consent to a credit enquiry, runs it, and brings the result back into the conversation so the liabilities it reports can be confirmed rather than typed. - Declarations Collects the declaration questions the application requires, and the follow-up detail wherever an answer needs one. - Demographic details Collects the regulated demographic questions, including the borrower's right to decline each of them. - Employment and income Collects employment and the income that comes from it — employer, role, dates, and the pay in the components a lender underwrites: base, overtime, bonus and commission. - Frequently-asked questions Answers a borrower's questions from a curated knowledge base rather than from the model's general knowledge, with the source behind each answer. - Gifts and grants Collects funds given to the borrower rather than held by them — the donor, the relationship, the amount, and whether the funds have arrived. - Liabilities Reviews the debts the credit enquiry reported, corrects them, and collects the ones it did not — the obligations that do not appear on a credit file. - Loan lookup Finds an existing application from what the borrower can remember, so a returning conversation resumes rather than restarts. - Military service Collects service history, which decides eligibility for the loan programmes that depend on it. - Mortgage details Collects the terms of the loan being applied for and of any mortgage already secured on a property the borrower owns — amount, purpose, occupancy and term. - Other income Collects income from every source that is neither employment nor a business the borrower owns — rental income, benefits, pensions, investments, support payments. - Personal identity Opens the application and collects who the borrower is — legal name, date of birth, taxpayer identifier, citizenship and marital status. - Preapproval letter Produces the preapproval letter from the priced application, and refreshes it when the price behind it moves. - Pricing Runs an actual price against the collected loan terms and explains the result in the conversation. - Rate estimate Gives a borrower an indicative rate from a short conversation, before any application exists. - Real estate owned Collects the properties the borrower already owns — address, value, how it is used, and what it earns or costs. - Residency Collects where the borrower lives now and where they lived before, with the dates, so the address history covers the required period without gaps. - Self-employment income Collects income from a business the borrower owns, including contract income reported on its own tax form. - Workspace assistant The assistant inside the internal workspace: answers a reviewer's questions about an application in progress and drafts the message going back to the borrower. --- # Providers # Providers A vendor integration or a counterparty exchange — a message provider's send-and-feedback loop, a partner's file share, a partner's client list, a third-party measurement console. - File sync Builds the scheduled workflow that copies a configured storage location into an external partner's file share: the infrastructure, a planning and cost gate, per-file workers, an aggregate, and the credential and configuration handling around them. - Marketing stackalso Delivery Orchestrates the whole measurement stack across consoles and code — tag management, analytics, search visibility, advertising linkage, the access each of those needs, and the handoff to whoever verifies it. - Roster workflow Takes each partner's uploaded client list, matches it against the records under management, and returns partner-branded settlement and authorisation paperwork the same day. - Send lifecycle Owns the whole dispatch and feedback loop as one lifecycle: provider setup, routing, the send handoff, delivery events, and ingestion of what comes back. --- # Registry # Registry One index of every agent and skill, with the repository that defines each. The registry is deliberately repository-agnostic. Each row names where the specialist is defined, so agents authored in different packages sit in one index rather than in several — which is what makes the router able to dispatch across all of them. A row carries the columns below. The index is the thing a router reads and the thing a person consults when they want to know whether a capability already exists before building it again. - One index of every agent and skill, deliberately repository-agnostic: each row names the repository that defines it, so specialists authored in different packages sit side by side in one place. Nobody memorises the roster — describe the task and the router names the specialist. ## What a row carries - `Mascot` - `Agent` - `What it does` - `Repository` One index of every agent and skill, deliberately repository-agnostic: each row names the repository that defines it, so specialists authored in different packages sit side by side in one place. Nobody memorises the roster — describe the task and the router names the specialist. --- # Analytics instrumentation # Analytics instrumentation Delivery also Providers Wires tag management into a front end on any of the common frameworks, and works out with the team which user actions are worth tracking. - **Used when** — When a site needs measurement in place and the container identifier either exists or is about to. - **Loads first** - The framework's own entry point, and the container identifier, supplied as configuration rather than assumed. - **Returns** - The files changed and why. - How the container identifier is supplied. - How to verify the tag fires on a cold load and on client-side navigation. - The checklist for the person who owns the analytics and advertising accounts. - Where event discovery was asked for: the candidate list, the decisions taken, and which approved events were implemented. - **Hands off** - Marketing stack — the order of operations and the console-side setup across the marketing stack ## Others in Delivery - Application scaffolding - Design implementation - Design testing - Interface triage - Marketplace architecture - Sharing portals --- # Application document # Application document Products Generates the completed application document from everything the conversation collected, and takes the borrower's signature on it. - **Used when** — At the end of the task set, once every required subject is answered. - **Collects** - The signature, and the record of who signed and when. - **Returns** - The generated application document, and the standards-format export beside it. - The signature record against the loan. - **Evidence** - `bot-1003-document` - `bot-1003-sign` - `start-loan-application-api_calls` - `start-loan-application-taskset` ## Others in Products - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Application scaffolding # Application scaffolding Delivery Scaffolds complete applications on the standard stack, front end and back end together in one repository, with the shared packages between them. - **Used when** — When a new application needs both halves and the boundary between them is the decision that matters. - **Loads first** - The front-end and back-end skill. - The shared engineering guidelines. - **Returns** - The repository layout. - The front-end and back-end boundary decisions. - The shared package plan. - The deployment and verification plan. - **Hands off** - Design implementation — translating a design into existing interface code - Design testing — tests that verify an interface across screen sizes ## Others in Delivery - Analytics instrumentation - Design implementation - Design testing - Interface triage - Marketplace architecture - Sharing portals --- # Assets # Assets Products Collects what the borrower holds — deposit and investment accounts, the institution each sits with, and the balance. - **Used when** — After income, since the deposit and the reserves are read against it. - **Collects** - Each account, its kind, the institution and the balance. - Assets that are not accounts, through the other-asset variant. - **Returns** - One record per asset, typed so the deposit and the reserve calculation can read them. - **Hands off** - Gifts and grants — funds given to the borrower rather than held by them - **Evidence** - `bot-asset-collector` - `bot-assets-collector` - `bot-other-asset-collector` ## Others in Products - Application document - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Assistant builder # Assistant builder Creating new agents Designs and implements task-triggered agents on the established runtime pattern — one function receiving events from the work-management surface, conversation state held externally, a model doing the reasoning, and tracing on every turn. - **Used when** — When a new agent should be triggered by a task or a comment rather than run by hand, which is the shape behind most of the deployed fleet. - **Loads first** - The agent-building skill, for the runtime, state and telemetry patterns. - The shared engineering guidelines. - **Returns** - The architecture and its runtime boundaries — one function, its handlers, the external state layout. - An implementation checklist covering ingress wiring, state, the webhook construct, memory, the model and its tools, and tracing. - Deployment and configuration requirements, including the exact values a human must collect and who owns the webhook per environment. - End-to-end verification steps covering the task flow, the traces, the locking and the persistence of conversation memory. - **Hands off** - Operations agent builder — operations agents for document and media pipelines - Spend approval — approval workflows that gate model spend - Audit analyser — analysers that scan processing output for anomalies ## Others in Creating new agents - Audit analyser - Operations agent builder - Spend approval --- # Audience selection # Audience selection Platform also Data Defines who a communication goes to, owning the entry point, the hard suppressions, and the contract by which an eligible population is handed to the runtime that will act on it. - **Used when** — When a filter has to hand a population to a runtime, when a communication needs segmenting, or when eligibility boundaries are being drawn. - **Loads first** - The audience-selection skill, for the eligibility handoff and intake contract. - The shared engineering guidelines. - **Returns** - The audience entry point and who owns the hard filters. - The runtime intake contract — schema, transport, and the identifiers that travel with each record. - The plan that makes the handoff replayable and auditable. - Acceptance checks for the eligible population. - **Hands off** - Template inventory — template management - Send lifecycle — provider delivery - Channel assembly — runtime scoring ## Others in Platform - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Audit analyser # Audit analyser Creating new agents Builds analysers that read pipeline output, apply versioned audit profiles, and emit evidence-backed anomaly records for a person to review. - **Used when** — When processing output needs checking against defined expectations and the result has to carry its evidence rather than a verdict. - **Loads first** - The agent-building and batch-workflow skills. - The atomic-data skill, for the normalised shape the profiles run against. - **Returns** - The clarified input contract and any unresolved blockers. - The recommended architecture and its runtime boundaries. - The normalised data model. - The audit profile catalogue, each rule with an identifier, its assumptions and its evidence requirement. - The output contract and a sample anomaly record. - An implementation plan, a test plan, and small-sample verification commands. - Notes on personal data and auditability. ## Others in Creating new agents - Assistant builder - Operations agent builder - Spend approval --- # Batch workflows # Batch workflows Platform Designs large-scale batch and extract-transform-load workflows with cost gates, throttling, idempotency and a staged test path. - **Used when** — When a job is large enough that a rerun, a rate limit or a cost surprise is the real design problem. - **Loads first** - The batch-workflow skill. - The shared engineering guidelines. - **Returns** - The recommended architecture. - The key assumptions and the questions still open. - A concrete implementation plan. - A verification plan with a small-sample path. - **Hands off** - Solver services — the optimisation model inside a workflow ## Others in Platform - Audience selection - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Capability map # Capability map Platform Knows every internal platform capability — accounts, bootstrap, build, distribution, deployment, reconciliation, persistence, connectivity, translation, product orchestration, rule decisioning and the governed vocabulary — and decides whether a request is served by something already deployed before any infrastructure is written. - **Used when** — Whenever a request touches tenancy, product distribution, deployment, graph persistence, partner integration, translation, rule decisioning, webhooks, file transfer or address allow-listing. - **Loads first** - The build skill and product requirements for whichever capability is in scope, re-read rather than recalled. - The shared engineering guidelines. - **Returns** - Which capability the request belongs to. - Whether an existing deployment serves it, with the evidence that settled the question. - Either the integration path into what exists, or the provisioning plan for a new instance. ## Others in Platform - Audience selection - Batch workflows - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Channel assembly # Channel assembly Platform Composes audience, template and send capabilities into one deterministic end-to-end channel service — the internal data contracts, candidate generation, scoring, allocation, outputs and runtime validation. - **Used when** — When the separate communication capabilities need to become a single service that behaves the same way twice. - **Loads first** - The runtime-assembly skill. - The batch-workflow and solver skills, where allocation is an optimisation rather than a sort. - **Returns** - The runtime data contract and the candidate-generation plan. - The scoring, allocation and output contracts. - The validation and rollout plan. - Its integration points with the three capabilities it composes. - **Hands off** - Audience selection — the audience entry point and its intake contract - Template inventory — the template inventory - Send lifecycle — provider delivery and response ingestion ## Others in Platform - Audience selection - Batch workflows - Capability map - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Co-borrower invitation # Co-borrower invitation Products Invites a co-borrower into the application and starts their own task set, which is the borrower's set plus the questions only they can answer. - **Used when** — Wherever the borrower names a co-borrower, at any point in the conversation. - **Collects** - The co-borrower's name and electronic-mail address. - Their consent to join the application. - **Returns** - The invitation sent, and a co-borrower task set opened against the same application. - **Evidence** - `bot-coborrower-emails` ## Others in Products - Application document - Assets - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Contact details # Contact details Products Collects how to reach the borrower — telephone numbers by kind, and the electronic-mail address the application and its documents are sent to. - **Used when** — Early in the task set, before anything has to be delivered to the borrower. - **Collects** - Telephone numbers, by kind, with the preferred one marked. - The electronic-mail address the application uses for delivery. - A co-borrower's own contact details, through its variant. - **Returns** - The contact fields on the loan record, and a delivery address every later step can rely on. - **Hands off** - Co-borrower invitation — inviting a co-borrower into the application - **Evidence** - `bot-contact-details` - `bot-contact-details-interactive` - `bot-coborrower-contact-details-collector` ## Others in Products - Application document - Assets - Co-borrower invitation - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Contact scheduling solver # Contact scheduling solver Platform Holds how one deployed scheduling solver actually works — how it prioritises records, selects a contact point, respects capacity, assigns hours, rotates between contact points and labels score tiers — and extends it without inventing a parallel runtime. - **Used when** — When that solver is being extended, when someone needs the prioritisation and scheduling rules explained, or when a scheduled run is being operated. - **Loads first** - The solver skill, whose reference documents are the authority on the business rules. - The campaign-operation skill, when a run is being started or delivered. - **Returns** - Which path it took — build, explain, or operate. - The business rules relevant to the question: contact-point selection, scoring, capacity, hours, rotation and tiers. - For a build: architecture notes by layer, and what must stay unchanged. - For an explanation: the generated document, grounded in the reference rules. - For a run: the environment, the input contract, the execution identifiers and the verification evidence. - Any drift between the written rules and the code. ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Conversation management # Conversation management Platform Manages the fleet around the runtime: the queue a conversation waits in, the configuration each agent runs from, and the tasks raised for a person when a conversation needs one. - **Used when** — Wherever a conversation has to wait, escalate, or be picked up by someone. - **Collects** - The queue a conversation belongs to, and its state. - The configuration version each agent is running. - **Returns** - The queue position and the state transitions. - The task raised for a person, and the answer that closed it. - **Evidence** - `chatbot-queues` - `chatbot-asana-tasks` - `chatbot-assistant-template` ## Operations ### ChatMTG `POST` `/functions` #### Create Function `createFunction` Create a function that can be invoked by GPT in the conversation based on user input by calling a webhook URL with some values for the parameters defined in the function. Learn more about functions in the GPT documentation. ##### Request Execute SQL QueryGet Database Schema application/json Copy ``` { "name": "execute_sql_query", "description": "Use this to execute Trino SQL query using AWS Athena Engine version 3. In case of error you will get error message, you have to fix your query and try again. You can apply JOIN opperations. You should use only columns from get_database_schema function. You should use columns only for it's tables. You can join tables if needed using provided columns. You should check that column is not empty string before casting it to avoid errors like this INVALID_CAST_ARGUMENT: Cannot cast '' to BIGINT. You should never compare numbers with strings.You should NEVER call this function before get_database_schema has been called in the conversation. You should NEVER use columns names of the wrong table. You should NEVER cast comare number types to strings or char. You should ALWAYS limit query results by maximum 50. You should NEVER compare fields to NULL.", "parameters": { "type": "object", "properties": { "sql_query": { "type": "string", "description": "SQL query, that user asked. Table names has to be inside \"\". Subqueries are only supported for EXISTS, IN and Scalar subquery, A scalar subquery is a non-correlated subquery that returns zero or one row. It is an error for the subquery to produce more than one row. The returned value is NULL if the subquery produces no rows. Example: SELECT COUNT(*) FROM \"first-american-listings\" WHERE facalculateddaysonmarket != '' AND CAST(\"facalculateddaysonmarket\" as BIGINT) > 15. Example: {\"sql_query\": \"SELECT mtg1lender, COUNT(*) as count FROM \"table_09_fulllaunch-first-american-equity-broker-listings-assesor\" WHERE currentoriginallistingdate >= '2022-03-20' GROUP BY mtg1lender ORDER BY count DESC LIMIT 5\"}. To get current date use current_date constant" } }, "required": [ "sql_query" ] }, "webhook_url": "https://webhook.site/8efe8cf4-b7b5-4864-8b89-0302bf9749eb" } ``` application/json Copy ``` { "name": "get_database_schema", "description": "Use this function to get database schema of AWS Athena with columns and descriptions based what data should be retrived. You should ALWAYS use unfolded descriptions.", "parameters": { "type": "object", "properties": { "question": { "type": "string", "description": "what data should be retrived" } }, "required": [ "question" ] }, "webhook_url": "https://webhook.site/8efe8cf4-b7b5-4864-8b89-0302bf9749eb" } ``` ##### Response 201400403 application/json Copy Function is created ``` { "function": { "name": "get_database_schema", "description": "Use this function to get database schema of AWS Athena with columns and descriptions based what data should be retrived. You should ALWAYS use unfolded descriptions.", "parameters": { "type": "object", "properties": { "question": { "type": "string", "description": "what data should be retrived" } }, "required": [ "question" ] }, "webhook_url": "https://webhook.site/8efe8cf4-b7b5-4864-8b89-0302bf9749eb" } } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Function name | | `description`required | `string` | Function description | | `parameters`required | `object` | Function arguments | | `webhook_url`required | `string` | Url for function invocation | ##### Response `201``application/json` 1 fields Function is created | Field | Type | Description | | --- | --- | --- | | `function` | `object` | Function configuration | | `name`required | `string` | Function name | | `description`required | `string` | Function description | | `parameters`required | `object` | Function arguments | | `webhook_url`required | `string` | Url for function invocation | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `POST` `/system_prompt` #### Set System Prompt `setSystemPrompt` Set a system prompt for a ChatBot. ##### Request application/json Copy ``` { "system_prompt": "You are ChatBot called ChatMTG by US Mortgage data company called staircase. You should help users with his question about the data. NEVER mention any table or column name." } ``` ##### Response 200400403 application/json Copy System prompt is created ``` { "system_prompt": "You are ChatBot called ChatMTG by US Mortgage data company called staircase. You should help users with his question about the data. NEVER mention any table or column name." } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `system_prompt`required | `string` | System prompt content | ##### Response `200``application/json` 1 fields System prompt is created | Field | Type | Description | | --- | --- | --- | | `system_prompt`required | `string` | System prompt content | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `POST` `/temperature` #### Set Temperature `setTemperature` Set a GPT temperature for a chatbot. The temperature controls the randomness of the text generated by GPT model. Lower temperatures make the model more deterministic and repetitive, while higher temperatures make the model more varied. You can learn more about temperature in the GPT documentation. ##### Request application/json Copy ``` { "temperature": 0.55 } ``` ##### Response 200400403 application/json Copy System prompt is created ``` { "temperature": 0.55 } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `temperature`required | `number` | GPT Temperature. | ##### Response `200``application/json` 1 fields System prompt is created | Field | Type | Description | | --- | --- | --- | | `temperature`required | `number` | GPT Temperature. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/functions` #### List Functions `listFunction` Provides a list of registered functions. ##### Response 200400403 application/json Copy Functions ``` { "functions": [ { "name": "get_database_schema", "description": "Use this function to get database schema of AWS Athena with columns and descriptions based what data should be retrived. You should ALWAYS use unfolded descriptions.", "parameters": { "type": "object", "properties": { "question": { "type": "string", "description": "what data should be retrived" } }, "required": [ "question" ] }, "webhook_url": "https://webhook.site/8efe8cf4-b7b5-4864-8b89-0302bf9749eb" } ] } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` ##### Response `200``application/json` 1 fields Functions | Field | Type | Description | | --- | --- | --- | | `functions` | `array` | Functions | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/system_prompt` #### Get System Prompt `getSystemPrompt` Get a configured system prompt for a ChatBot. ##### Response 200400403404 application/json Copy System prompt ``` { "system_prompt": "You are chatbot called ChatMTG by US Mortgage data company called staircase. You should help users with his question about the data. NEVER mention any table or column name." } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Response `200``application/json` 1 fields System prompt | Field | Type | Description | | --- | --- | --- | | `system_prompt`required | `string` | System prompt content | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/temperature` #### Get Temperature `getTemperature` Get a configured GPT temperature for a ChatBot. ##### Response 200400403404 application/json Copy Temperature ``` { "temperature": 0.55 } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Response `200``application/json` 1 fields Temperature | Field | Type | Description | | --- | --- | --- | | `temperature`required | `number` | GPT Temperature. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/functions/{name}` #### Get Function `getFunction` Provides a configuration of the registered function. ##### Response 200400403404 application/json Copy Function ``` { "function": { "name": "get_database_schema", "description": "Use this function to get database schema of AWS Athena with columns and descriptions based what data should be retrived. You should ALWAYS use unfolded descriptions.", "parameters": { "type": "object", "properties": { "question": { "type": "string", "description": "what data should be retrived" } }, "required": [ "question" ] }, "webhook_url": "https://webhook.site/8efe8cf4-b7b5-4864-8b89-0302bf9749eb" } } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `get_database_schema` | Function name | ##### Response `200``application/json` 1 fields Function | Field | Type | Description | | --- | --- | --- | | `function` | `object` | Function configuration | | `name`required | `string` | Function name | | `description`required | `string` | Function description | | `parameters`required | `object` | Function arguments | | `webhook_url`required | `string` | Url for function invocation | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `DELETE` `/functions/{name}` #### Delete Function `deleteFunction` Delete a registered function. ##### Response 400403404 application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `get_database_schema` | Function name | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `204` ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Conversation runtime # Conversation runtime Platform Serves the conversation itself: holds the task set, runs the agent whose turn it is, calls the functions an answer triggers, and writes what was said to the loan record. - **Used when** — Behind every conversation above. Nothing in the fleet runs without it. - **Collects** - The message, the conversation it belongs to, and the task it advances. - **Returns** - The next message, the task state, and the record write the answer produced. - **Hands off** - Conversation management — the queue, the configuration and the work-tracking integration - **Evidence** - `chatbot` - `chats` - `chat-configuration-template` ## Operations ### Assistants `POST` `/assistants` #### Create a new assistant `createAssistant` Chat This endpoint allows for the creation of a versatile assistant capable of interacting with different platforms such as OpenAI and Google. It enables the configuration of staircase service calls (functions). Users can define attributes like the assistant's name, functionality, and the tools it will use, ensuring the assistant is tailored to specific operational needs. ##### Request Example1Example2 application/json Copy ``` { "name": "General Helper", "description": "An assistant designed to offer general help across various tasks, including scheduling, reminders, and basic inquiries.", "platforms": [ { "platform_name": "OpenAI", "model": "gpt-4-1106-preview" } ], "tools": [ { "tool_type": "retrival" }, { "tool_type": "code_interpretor" }, { "tool_type": "function", "function": { "http_method": "GET", "path": "/data/retrieve", "name": "retrieveData", "description": "Function to retrieve data from the database.", "parameters": { "type": "object", "properties": { "id": { "type": "string", "description": "The identifier of the data to retrieve." }, "fields": { "type": "array", "description": "The fields to retrieve.", "items": { "type": "string" } }, "limit": { "type": "integer", "description": "The maximum number of records to retrieve." }, "offset": { "type": "integer", "description": "The number of records to skip." }, "order_by": { "type": "string", "description": "The field to order by." }, "order_direction": { "type": "string", "description": "The direction to order by." }, "filter": { "type": "object", "description": "The filter to apply." }, "search": { "type": "string", "description": "The search to apply." } } } } } ] } ``` application/json Copy ``` { "name": "EduBot", "description": "An educational assistant designed to help students with learning, offering explanations, and quizzing capabilities.", "platforms": [ { "platform_name": "OpenAI", "model": "gpt-4-1106-preview" } ], "tools": [ { "tool_type": "function", "function": { "http_method": "POST", "path": "/education/evaluate", "name": "evaluateAnswer", "description": "Function to evaluate student responses in quizzes.", "parameters": { "type": "object", "properties": { "question": { "type": "string", "description": "The question to evaluate." }, "answer": { "type": "string", "description": "The answer to evaluate." }, "options": { "type": "array", "description": "The options to evaluate.", "items": { "type": "string" } }, "correct_answer": { "type": "string", "description": "The correct answer." }, "correct_options": { "type": "array", "description": "The correct options.", "items": { "type": "string" } }, "incorrect_answer": { "type": "string", "description": "The incorrect answer." }, "incorrect_options": { "type": "array", "description": "The incorrect options.", "items": { "type": "string" } }, "explanation": { "type": "string", "description": "The explanation." }, "metadata": { "type": "object", "description": "The metadata." } } } } } ] } ``` ##### Request body`application/json` 10 fields | Field | Type | Description | | --- | --- | --- | | `assistant_id` | `string` | Unique identifier for the assistant | | `created_at` | `integer (int64)` | Timestamp of creation | | `name` | `string` | Name of the assistant | | `description` | `string` | Description of the assistant's purpose | | `instructions` | `string` | Instructions for using the assistant | | `platforms` | `array` | List of platforms the assistant is available on | | `tools` | `array` | Tools utilized by the assistant | | `file_ids` | `string[]` | List of OpenAI file identifiers associated with the assistant | | `blob_file_ids` | `string[]` | List of `Persistence Blob` identifiers associated with the assistant | | `metadata` | `object` | Metadata related to the assistant | ##### Response `201``application/json` 10 fields Assistant created | Field | Type | Description | | --- | --- | --- | | `assistant_id` | `string` | Unique identifier for the assistant | | `created_at` | `integer (int64)` | Timestamp of creation | | `name` | `string` | Name of the assistant | | `description` | `string` | Description of the assistant's purpose | | `instructions` | `string` | Instructions for using the assistant | | `platforms` | `array` | List of platforms the assistant is available on | | `tools` | `array` | Tools utilized by the assistant | | `file_ids` | `string[]` | List of OpenAI file identifiers associated with the assistant | | `blob_file_ids` | `string[]` | List of `Persistence Blob` identifiers associated with the assistant | | `metadata` | `object` | Metadata related to the assistant | ##### Other responses `400``403` `GET` `/assistants` #### List all assistants `listAssistants` Retrieves a list of all created assistants. This endpoint is useful for obtaining an overview of all assistants available in the system. ##### Response `200``application/json` 10 fields A list of assistants | Field | Type | Description | | --- | --- | --- | | `assistant_id` | `string` | Unique identifier for the assistant | | `created_at` | `integer (int64)` | Timestamp of creation | | `name` | `string` | Name of the assistant | | `description` | `string` | Description of the assistant's purpose | | `instructions` | `string` | Instructions for using the assistant | | `platforms` | `array` | List of platforms the assistant is available on | | `tools` | `array` | Tools utilized by the assistant | | `file_ids` | `string[]` | List of OpenAI file identifiers associated with the assistant | | `blob_file_ids` | `string[]` | List of `Persistence Blob` identifiers associated with the assistant | | `metadata` | `object` | Metadata related to the assistant | ##### Other responses `403``404` ### Chats `POST` `/apps` #### Create chat app `createApp` Create Chat App Create new chat App. All incoming messages will be forwared as POST request to the provided webhook URL with app id, chat id and message submitted by user on UI. Service expects webhook to respond with 200 OK status code. JSON Schema of the request body: ``` { "type": "object", "properties": { "app_id": { "type": "string" }, "chat_id": { "type": "string" }, "message": { "type": "string" } }, "required": [ "app_id", "chat_id", "message" ] } ``` Example of the request body: ``` { "app_id": "app_id", "chat_id": "chat_id", "message": "message" } ``` ##### Request application/json Copy ``` { "webhook_url": "https://webhook.site/0a0a0a0a-0a0a-0a0a-0a0a-0a0a0a0a0a0a", "app_name": "My App" } ``` ##### Response 201400 application/json Copy App created ``` { "id": "01H9QPFE3CVK771YYD3MN9T4GQ", "webhook_url": "https://webhook.site/0a0a0a0a-0a0a-0a0a-0a0a-0a0a0a0a0a0a", "app_name": "My App" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `webhook_url`required | `string` | Webhook URLExample `https://webhook.site/0a0a0a0a-0a0a-0a0a-0a0a-0a0a0a0a0a0a` | | `app_name`required | `string` | App nameExample `My App` | ##### Response `201``application/json` 3 fields App created | Field | Type | Description | | --- | --- | --- | | `id` | `string` | App IDExample `01H9QPFE3CVK771YYD3MN9T4GQ` | | `webhook_url` | `string` | Webhook URLExample `https://webhook.site/0a0a0a0a-0a0a-0a0a-0a0a-0a0a0a0a0a0a` | | `app_name` | `string` | App nameExample `My App` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/apps/{app_id}/chats/{chat_id}/messages` #### Send message `sendMessage` Send message to chat. ##### Request application/json Copy ``` { "message": "Hello World" } ``` ##### Response 200400404 application/json Copy Message sent ``` { "message": "Message sent successfully" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `app_id` required | `string` path | `01H9QPFE3CVK771YYD3MN9T4GQ` | App ID | | `chat_id` required | `string` path | `01H9QQ1AB6HQSB8DEESRW3Z0Z8` | Chat ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | MessageExample `Hello World` | ##### Response `200``application/json` 1 fields Message sent | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response messageExample `Message sent successfully` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Runs `POST` `/runs` #### Create add message and run `createMessageAndRun` Submits a message and initiates a run process based on that message. This is typically used to trigger processing of a user's input by the assistant. ##### Request example1example2 application/json Copy ``` { "thread_id": "thread_321", "role": "user", "content": [ { "type": "text", "text": { "value": "Can you also provide tomorrow's forecast?" } } ], "assistant_id": "assistant_654" } ``` application/json Copy ``` { "thread_id": "thread_321", "role": "user", "content": [ { "type": "text", "text": { "value": "I need assistance with organizing a team event." } } ], "orchestrator_assistant_id": "assistant_9012" } ``` ##### Request body`application/json` 11 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | The identifier, which can be referenced in API endpoints. | | `message_id` | `string` | The identifier, which can be referenced in API endpoints. | | `created_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the message was created. | | `thread_id`required | `string` | The identifier of the thread that the message belongs to. | | `role`required | `string` | The role of the message.`user` | | `content`required | `string` | The content of the message. | | `file_ids` | `string[]` | The file IDs associated with the message. | | `assistant_id` | `string` | The identifier of the assistant that should process the message. | | `orchestrator_assistant_id` | `string` | The identifier of the assistant that should orchestrate the message. | | `run_id` | `string` | The identifier of the run that processed the message. | | `metadata` | `object` | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maxium of 512 characters long. | ##### Response `201``application/json` 13 fields Message added and run initiated | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | The identifier, which can be referenced in API endpoints. | | `created_at`required | `integer (int64)` | The Unix timestamp (in seconds) for when the run was created. | | `assistant_id`required | `string` | The identifier of the assistant that should process the message. | | `thread_id`required | `string` | The identifier of the thread that the message belongs to. | | `status`required | `string` | The status of the run.`completed``in_progress` | | `started_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run was started. | | `expires_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run will expire. | | `cancelled_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run was cancelled. | | `failed_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run failed. | | `completed_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run completed. | | `last_error` | `string` | The last error that occurred during the run. | | `platforms` | `array` | The platforms that the run was processed on. | | `metadata` | `object` | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maxium of 512 characters long. | ##### Other responses `403` `GET` `/runs/{run_id}` #### Get a run by ID `getRun` Retrieves the details of a specific run by its unique identifier. ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `run_id` required | `string` path | `123` | Unique identifier of the run | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | ##### Response `200``application/json` 13 fields Run details | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | The identifier, which can be referenced in API endpoints. | | `created_at`required | `integer (int64)` | The Unix timestamp (in seconds) for when the run was created. | | `assistant_id`required | `string` | The identifier of the assistant that should process the message. | | `thread_id`required | `string` | The identifier of the thread that the message belongs to. | | `status`required | `string` | The status of the run.`completed``in_progress` | | `started_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run was started. | | `expires_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run will expire. | | `cancelled_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run was cancelled. | | `failed_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run failed. | | `completed_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the run completed. | | `last_error` | `string` | The last error that occurred during the run. | | `platforms` | `array` | The platforms that the run was processed on. | | `metadata` | `object` | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maxium of 512 characters long. | ##### Other responses `403``404` ### Threads `POST` `/threads` #### Create a new thread `createThread` This endpoint allows for the creation of a new thread. Threads are used to group messages together, allowing for the tracking of conversations between users and assistants. ##### Request application/json Copy ``` { "transaction_id": "12345" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | The transaction ID associated with the thread | ##### Response `201``application/json` 3 fields Thread created | Field | Type | Description | | --- | --- | --- | | `id` | `string` | The identifier, which can be referenced in API endpoints. | | `created_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the thread was created. | | `metadata` | `object` | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maxium of 512 characters long. | ##### Other responses `400``403` `GET` `/threads` #### Fetches chat threads associated with a given transaction ID. `retrieveChatThreads` Retrieve Chat Threads by Transaction ID Fetches chat threads associated with a given transaction ID. ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` query | — | The transaction ID to fetch chat threads for. | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | ##### Response `200``application/json` 1 fields A list of chat threads. | Field | Type | Description | | --- | --- | --- | | `chat_threads` | `array` | A list of chat threads. | ##### Response `404``application/json` 1 fields Chat thread not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Chat thread not found.Example `Chat thread not found` | ##### Other responses `403` ### Messages `GET` `/threads/{thread_id}/messages` #### List all messages in a thread `listMessages` Retrieves a list of all messages in a specific thread. This endpoint is useful for obtaining an overview of all messages in a thread. ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `thread_id` required | `string` path | `123` | Unique identifier of the thread | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | ##### Response `200``application/json` 11 fields A list of messages | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | The identifier, which can be referenced in API endpoints. | | `message_id` | `string` | The identifier, which can be referenced in API endpoints. | | `created_at` | `integer (int64)` | The Unix timestamp (in seconds) for when the message was created. | | `thread_id`required | `string` | The identifier of the thread that the message belongs to. | | `role`required | `string` | The role of the message.`user` | | `content`required | `string` | The content of the message. | | `file_ids` | `string[]` | The file IDs associated with the message. | | `assistant_id` | `string` | The identifier of the assistant that should process the message. | | `orchestrator_assistant_id` | `string` | The identifier of the assistant that should orchestrate the message. | | `run_id` | `string` | The identifier of the run that processed the message. | | `metadata` | `object` | Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maxium of 512 characters long. | ##### Other responses `403``404` ### Credentials `POST` `/credentials` #### Create a new credential `createCredential` This endpoint allows for the creation of a new credential. Credentials are used to authenticate users and assistants, ensuring that only authorized users can access the system. ##### Request application/json Copy ``` { "partner": "12345", "value": "12345" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `partner` | `string` | The partner associated with the credential`Google``OpenAI` | | `value` | `string` | The value of the credential | ##### Response `201``application/json` 2 fields Credential created | Field | Type | Description | | --- | --- | --- | | `partner` | `string` | The partner associated with the credential | | `value` | `string` | The value of the credential | ##### Other responses `400``403` ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Correction # Correction Products Reopens a subject the borrower has already answered so an answer can be changed without restarting the application. - **Used when** — Wherever a borrower or a reviewer finds an answer that is wrong, at any point before or after submission. - **Collects** - The corrected answer, and which subject it belongs to. - **Returns** - The updated record, and the downstream steps the change invalidated. - **Evidence** - `bot-correction` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Counterparty document expectations # Counterparty document expectations Data also Providers Loads counterparty contact details and document requirements from spreadsheets into the graph store, mapping each requirement onto the governed vocabulary and setting aside anything that does not map. - **Used when** — When an expectations workbook arrives and its contents need to become queryable facts rather than a file. - **Loads first** - The upload skill, followed exactly. - The schema-exploration skill, to confirm the current shape of every entity and relationship it will write. - The persistence patterns, for validation, ingestion and read-back. - **Returns** - The source workbook, sheet, row count, counterparty count and contact count. - The target environment and the verified account. - The schema mappings used, and the validation and ingestion status. - Records written, by type. - The unresolved sidecar and its count. - A read-back sample, and any schema gap that prevented a fact from being stored. - **Hands off** - Model curator — extending the schema when a fact has nowhere to go ## Others in Data - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Credit # Credit Products Takes the borrower's consent to a credit enquiry, runs it, and brings the result back into the conversation so the liabilities it reports can be confirmed rather than typed. - **Used when** — After identity, and before liabilities — the enquiry is what fills the liability list the next conversation reviews. - **Collects** - Explicit consent to the enquiry, recorded as its own evidence. - The result of the enquiry, held against the loan record. - **Returns** - The credit result, and a liability list for review rather than a blank form. - **Hands off** - Liabilities — reviewing and completing the reported liabilities - **Evidence** - `bot-credit-collector` - `bot-credit-assistant` - `consent-bot` - `liabilities-bot-api_calls` - `credit-report-tasksets` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Data-lake assistant # Data-lake assistant Data Answers questions over the accumulated loan and partner data in plain language, and draws the chart where a chart is the answer. - **Used when** — When someone needs a figure out of the warehouse and does not want to write the query. - **Collects** - The question, and which body of data it should be answered from. - **Returns** - The answer, the query behind it, and a chart where one was asked for. - **Evidence** - `prompt-graphql-data` ## Operations ### ChatMTG `POST` `/handle_query` #### Handle US Data ChatMTG querying via SQL query `handleUSDataQueryingViaSQL` Endpoint function serves as an interface for users to interact with a US Data database by accepting a SQL query as an input and executing the query. ##### Request application/json Copy ``` { "sql": "select count(*) from \"sc-us-data-consumer-data\"" } ``` ##### Response 200400403 application/json Copy Success ``` Total Number of People - 258,617,916 ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `sql`required | `string` | SQL statement | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` ## Others in Data - Counterparty document expectations - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Dataset fulfilment # Dataset fulfilment Data Turns an approved data request into a scoped extract — resolving which organisation it belongs to, mapping the requested field names onto the canonical model, and returning either the result directly or a time-limited download link. - **Used when** — When someone with authority to ask needs data out of the graph store and the request arrives as a sentence rather than as a query. - **Loads first** - The persistence product's own access patterns, before any read. - Its access bootstrap, which establishes the environment and the verified credential source. - **Returns** - How it was invoked, how it read the request, and the organisation scope it resolved. - The environment, verified credential source and discovered configuration, with no secret values. - What validation found — a missing scope, an unverified requester, an unmapped field. - The extraction plan: requested field names, the canonical fields they map to, and anything unmapped. - The action taken, the workflow status, and the artifact metadata the workflow returned. - The exact missing input, when it is blocked. ## Others in Data - Counterparty document expectations - Data-lake assistant - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Declarations # Declarations Products Collects the declaration questions the application requires, and the follow-up detail wherever an answer needs one. - **Used when** — Near the end of the task set, and again whenever a later step raises a question the borrower has to answer in writing. - **Collects** - Each declaration, with the follow-up detail an affirmative answer needs. - An explicit skip, where the flow permits one, recorded as a skip rather than as a blank. - **Returns** - The declaration answers on the record, with any detail attached to the answer that needed it. - **Evidence** - `bot-additional-information` - `bot-additional-information-skip` - `chatbot-requests` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Demographic details # Demographic details Products Collects the regulated demographic questions, including the borrower's right to decline each of them. - **Used when** — In the forms stage, where the wording and the decline option are fixed by regulation rather than by the product. - **Collects** - Ethnicity, race and sex, each answerable more than once. - A recorded decline, which is a valid answer rather than a missing one. - How the information was provided — in person, by telephone, or by the borrower directly. - **Returns** - The demographic fields, with the collection method recorded beside them. - **Evidence** - `bot-demographic-details` - `bot-demographic-details-collector` - `bot-coborrower-demographic-details-collector` - `start-loan-application-forms` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Design implementation # Design implementation Delivery Translates a design into existing interface code, preserving the business logic underneath and locking in the breakpoints. - **Used when** — When a design has changed and the code has to match it without the behaviour moving. - **Loads first** - The design-to-code skill. - The responsive-test skill, for the coverage the change needs. - **Returns** - A summary of the interface changes. - The files updated and why. - The result of checking recent commits for an override that would undo the change. - Tests added or updated, with the lane chosen and the run results. - **Hands off** - Design testing — writing the tests that hold the change in place - Interface triage — triaging a defect rather than implementing a design ## Others in Delivery - Analytics instrumentation - Application scaffolding - Design testing - Interface triage - Marketplace architecture - Sharing portals --- # Design testing # Design testing Delivery Writes the tests that verify an interface renders correctly across phone, tablet and desktop, in whichever of the two lanes fits — mocked specifications for the design itself, or real-device specifications for behaviour. - **Used when** — When a design-driven change needs coverage, or when an existing design test proved too weak to catch a regression. - **Loads first** - The responsive-test skill, and the design-to-code and bug-fix skills for the context of the change. - **Returns** - The lane decision and the reasoning behind it. - The specifications created or updated. - The breakpoint and device configuration used. - The assertions added, and what each is for. - The command and results, or a clear account of why the run could not happen. - **Hands off** - Design implementation — implementing the design change itself - Interface triage — diagnosing and fixing the defect ## Others in Delivery - Analytics instrumentation - Application scaffolding - Design implementation - Interface triage - Marketplace architecture - Sharing portals --- # Employment and income # Employment and income Products Collects employment and the income that comes from it — employer, role, dates, and the pay in the components a lender underwrites: base, overtime, bonus and commission. - **Used when** — After the borrower is identified and reachable, and again for each previous employer needed to cover the required history. - **Collects** - The current employer, the role, the start date, and whether the borrower is still there. - Pay, separated into base, overtime, bonus and commission. - Previous employment, with dates, until the required history is covered. - The same for a co-borrower. - **Returns** - The employment records and the income components on each, written to the loan record. - **Hands off** - Self-employment income — income from a business the borrower owns - Other income — income from any source that is not employment - **Evidence** - `bot-employment-collector` - `bot-employments-collector` - `bot-previous-employment-collector` - `bot-coborrower-employment-collector` - `bot-coborrower-previous_employment-collector` - `bots-employment-income-details` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # File sync # File sync Providers Builds the scheduled workflow that copies a configured storage location into an external partner's file share: the infrastructure, a planning and cost gate, per-file workers, an aggregate, and the credential and configuration handling around them. - **Used when** — When files have to leave internal storage for a partner's share on a schedule, and the run has to be safe to repeat. - **Loads first** - The batch-workflow skill, for the distributed shape. - The inbound-transfer skill, where the destination is a plain file-transfer endpoint, with the direction reversed. - The continuous-integration skill, for the per-environment deployment path. - **Returns** - The chosen destination provider and its authentication flow, confirmed with the requester. - The repository layout — infrastructure, handlers, provider adapters, tests. - The parameter and secret schema, with the exact commands per environment. - The runtime contract: the invocation event, the manifest, and the summary. - The permissions actually granted, least-privilege. - The deployment files added, and how the target environment is wired. - A verification log covering a dry run, a single-file transfer, an idempotent rerun, a change-detection rerun and the schedule. - The inputs still owed, and rollback notes for both code and configuration. ## Others in Providers - Marketing stack - Roster workflow - Send lifecycle --- # Frequently-asked questions # Frequently-asked questions Products Answers a borrower's questions from a curated knowledge base rather than from the model's general knowledge, with the source behind each answer. - **Used when** — At any point in the conversation, alongside whichever subject is open. - **Collects** - The question, and the subject it was asked from. - **Returns** - The answer, and the document it came from. - The question itself, recorded, so an unanswered one becomes a knowledge-base gap. - **Evidence** - `bot-faq-support` - `chatbot-knowledge-update` ## Operations ### FAQ bot service `GET` `/` #### Get Bot Knowledge `getKnowledge` Get knowledge of faq bot Get extra bot knowledge ##### Response 403500 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` `POST` `/` #### Update Bot Knowledge `updateBotKnowledge` Update knowledge Patch bot ##### Response 403500 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` `DELETE` `/{knowledge_id}` #### Delete Bot Knowledge `deleteKnowledge` Delete extra knowledge Delete extra bot knowdlege from faq-bot-service ##### Response 403500 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `knowledge_id` required | `string` path | `id_knowledge` | Knowledge id | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `204` `POST` `/slab` #### Update Bot Knowledge Slab `updateBotKnowledgeSlab` Update knowledge Slab webhook for updating bot knowledge ##### Request application/json Copy ``` { "type": "post_update", "post": { "id": "elaykynn", "title": "Neuromancer", "link_access": "internal", "state": "published", "version": 1, "bannerUrl": null }, "old_post": { "state": "archived", "link_access": "internal", "bannerUrl": null, "ownerId": "l7ibj9w0", "archiverId": "l7ibj9w0", "publisherId": "l7ibj9w0", "seriesId": null }, "archiver": null, "owner": { "id": "l7ibj9w0", "name": "William Gibson" }, "publisher": { "id": "l7ibj9w0", "name": "William Gibson" }, "series": null } ``` ##### Response 403500 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` `POST` `/sync` #### Sync Bot Knowledge `syncBotKnowledgeSlab` Sync knowledge Slab webhook for updating bot knowledge from Slab and knowledge database ##### Response 403500 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Gifts and grants # Gifts and grants Products Collects funds given to the borrower rather than held by them — the donor, the relationship, the amount, and whether the funds have arrived. - **Used when** — Where the assets conversation found a deposit the borrower's own accounts do not cover. - **Collects** - The donor, their relationship to the borrower, and the amount. - Whether the funds have been received, and where they sit. - Whether the source is a gift or a grant programme. - **Returns** - One record per gift or grant, typed so the deposit calculation can treat it correctly. - **Hands off** - Assets — funds the borrower already holds - **Evidence** - `bot-gift-or-grant-assets-collector` - `bot-gift-or-grants-interactive` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Interface triage # Interface triage Delivery Triages and fixes interface defects: confirms the delta against the design reference, audits recent commits for the override that caused it, applies the smallest correcting change, and strengthens the tests so it cannot return. - **Used when** — When something renders wrongly and the cause is not yet known. - **Loads first** - The bug-fix skill and the responsive-test skill. - The shared engineering guidelines. - **Returns** - The root cause, named as one of a design delta, an override, missing coverage or a logic regression. - The files changed and why. - The override or commit that caused the regression, with its identifier where one exists. - The test coverage added, and which lane it went in. - Test run results confirming both the fix and the absence of regressions. ## Others in Delivery - Analytics instrumentation - Application scaffolding - Design implementation - Design testing - Marketplace architecture - Sharing portals --- # Knowledge search # Knowledge search Data Builds reusable retrieval agents that answer from a curated document corpus — embeddings, a search index, a knowledge library, schema and header mapping, reuse of prior decisions, confidence thresholds and a human review loop. - **Used when** — When a question should be answered from a defined corpus rather than from a model's general knowledge, and the answer needs a confidence and a reviewer. - **Loads first** - The retrieval-system and agent-building skills. - The shared engineering guidelines. - **Returns** - Whether the use case is retrieval at all, and why. - The reusable agent boundary and its runtime contract. - The corpus and metadata contract. - The retrieval and confidence policy. - The production stack and the local emulation path that replays it. - The human review and learning loop for runtime decisions. - The evaluation and operations plan, and an implementation checklist. - **Hands off** - Search to production — taking a retrieval system from prototype to production ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Liabilities # Liabilities Products Reviews the debts the credit enquiry reported, corrects them, and collects the ones it did not — the obligations that do not appear on a credit file. - **Used when** — Directly after the credit enquiry, so the borrower confirms a list rather than recalling one. - **Collects** - Each reported debt, confirmed, corrected, or marked as belonging to someone else. - Obligations no credit file carries, entered by the borrower. - The verification state of each, so a disputed entry is visible as one. - **Returns** - The liability schedule on the loan record, with the source of each entry. - **Hands off** - Mortgage details — a mortgage secured on a property the borrower owns - **Evidence** - `bot-liabilities-collector` - `bot-liabilities-interactive` - `bot-liabilities-other-liabilities-collector` - `bot-liabilities-verification` - `bot-other-liabilities` - `bot-other-liabilities-collector` - `bot-other-liabilities-interactive` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Loan lookup # Loan lookup Products Finds an existing application from what the borrower can remember, so a returning conversation resumes rather than restarts. - **Used when** — Whenever someone returns and the application they started is not obvious from their session. - **Collects** - Whatever identifies the application — an electronic-mail address, a reference, a property. - **Returns** - The matched application, and the task set resumed at the point it stopped. - **Evidence** - `bot-lookup` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Mail campaign operations # Mail campaign operations Platform Operates the deployed mail-campaign workflow: validating the population for a run, launching it, watching it, and reconciling what came back against what was sent. - **Used when** — When a large physical-mail run needs launching or checking, or when the campaign workflow itself needs changing. - **Loads first** - The mail-campaign skill, for the launch, validation and monitoring workflow. - The persistence patterns, before reviewing membership writes or reading results back. - The batch-workflow and shared engineering guidance, before changing the workflow, its infrastructure, its alerting or its deployment path. - **Returns** - The target environment and account. - The campaign identifier, name and purpose. - The input location and the validated population count. - The cost estimate and its approval status. - The workflow execution identifier, the output prefix and the manifest written. - Failure counts, and how to retry or resume. ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Message assistant - Rule editor - Short links - Solver services - Template inventory --- # Marketing stack # Marketing stack Providers also Delivery Orchestrates the whole measurement stack across consoles and code — tag management, analytics, search visibility, advertising linkage, the access each of those needs, and the handoff to whoever verifies it. - **Used when** — When measurement is being set up end to end rather than one piece at a time. - **Loads first** - The console-side order of operations, which it owns. - **Returns** - The sequence, in order, across every console and the code. - For each access problem, who owns the permission in generic terms and a ready-to-send request naming the exact role. - The identity question resolved: which account must own new properties, so ownership matches policy. - The verification handoff. - **Hands off** - Analytics instrumentation — installing the tag in the application source ## Others in Providers - File sync - Roster workflow - Send lifecycle --- # Marketplace architecture # Marketplace architecture Delivery Architects the multi-tenant platform through which products are packaged, distributed and installed — a central account governing per-customer accounts, a registry of components and releases, and the four ecosystem products underneath it: domain routing, account management, the product deployer and the tenant-side reconciler. - **Used when** — When a product needs to be distributed to many isolated tenants, or when one of the four ecosystem products is being built or changed. - **Loads first** - The marketplace skill and the skill for each ecosystem product. - The shared engineering guidelines. - **Returns** - The tenancy model, with any deviation called out. - The control-plane and data-plane boundary — what lives centrally, what lives in each tenant. - The component artifact contract, its versioning scheme and its immutability rules. - The registry design and its access patterns. - The interface — its operations, their schemas, the authorisation model and the idempotency strategy. - The cross-account deployment mechanism, with the rationale for the choice. - The bootstrap plan and the fixed order the ecosystem products come up in. - A verification plan that registers, releases, subscribes, rolls back and unsubscribes against a throwaway tenant. ## Others in Delivery - Analytics instrumentation - Application scaffolding - Design implementation - Design testing - Interface triage - Sharing portals --- # Message assistant # Message assistant Platform Answers questions about what has been sent to a consumer, and lets a non-technical user propose, revise, or retire a message template through a plain-language review conversation that captures the approved wording. Outline A description of this agent has not been written yet. What would be here: - When it runs, and what triggers it - What it loads before it acts - What it returns - Which peer owns the adjacent work Source: its own specification — this agent is deployed and the network document records what it does, but neither kit carries its contract ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Rule editor - Short links - Solver services - Template inventory --- # Metric reconciliation # Metric reconciliation Data Reconciles the same metric across vendors and sources so the figures compare like with like, and records why they differed. - **Used when** — When two systems report the same measure differently, and the definition, the freshness, the window or the field mapping may be the reason. - **Loads first** - The metric-unification skill. - The atomic-data skill, for the normalised shape the comparison runs on. - **Returns** - The coverage status against the governed vocabulary. - The mappings and the normalisation decisions taken. - The assumptions made and the risks they carry. - The findings, and recommendations in priority order. - **Hands off** - Question answering — answering a counting question and turning it into a shareable report ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Military service # Military service Products Collects service history, which decides eligibility for the loan programmes that depend on it. - **Used when** — In the forms stage of the task set, alongside the other regulated questions. - **Collects** - Whether the borrower has served, in what capacity, and over what period. - Surviving-spouse status, where it applies. - The same for a co-borrower. - **Returns** - The service fields on the record, in the form the eligibility engines read. - **Evidence** - `bot-military` - `bot-military-service-collector` - `bot-coborrower-military-service-collector` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Model curator # Model curator Data Guards the shared graph schema, so that every entity type, relationship, property, index, enumeration and required field passes one review and ingestion and query behaviour stay consistent across services. - **Used when** — When a schema change is being designed, reviewed or applied — a new entity type, a new relationship, a property, an index, an enumeration value, or a deprecation. - **Loads first** - The schema-exploration skill, and the current schema file, downloaded before anything is proposed. - The update skill, for the workflow, the modelling principles and the review checklist. - The persistence product's patterns, to confirm the resulting payloads and queries still comply. - **Returns** - A domain summary of the entities and relationships being changed. - The explicit decision for each — a new entity, a new relationship, a new property, a derived index, or a deprecation. - Required-field and enumeration changes, justified from real source data. - Index additions, with their canonical source facts, change triggers and queries. - The immutability and revision-modelling decisions. - The exact schema difference applied, with validation and test results. - Downstream impact on ingestion and queries. ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Mortgage details # Mortgage details Products Collects the terms of the loan being applied for and of any mortgage already secured on a property the borrower owns — amount, purpose, occupancy and term. - **Used when** — After the collateral and the existing property are known. - **Collects** - The loan amount, its purpose, the intended occupancy and the term. - Existing mortgages, with their balances, payments and liens. - **Returns** - The loan terms on the record, complete enough for a price to be run against them. - **Hands off** - Pricing — running a price against the collected terms - **Evidence** - `bot-mortgage-details-collector` - `bot-mortgage-details-filter` - `bot-mortgage-details-interactive` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Operations agent builder # Operations agent builder Creating new agents Builds the operations agents that drive document and media pipelines: resolving the target environment from what the requester said or from their profile, discovering the deployed stack, starting and watching runs, handling replays and approval gates, and preparing configuration changes as reviewable proposals. - **Used when** — When a pipeline needs a conversational operator rather than a runbook, and the operator has to be safe against acting on the wrong environment. - **Loads first** - The agent-building skill, for the shared runtime pattern. - The pipeline's own replay and staging-configuration playbooks. - The change-history skill, so a configuration proposal is grounded in what changed before. - **Returns** - The agent architecture and its runtime boundary. - The environment and stack discovery plan, naming the fields discovery must return. - The request contract, separating fields resolved deterministically from fields the model owns, with environment gating. - The tool inventory, grouped by the system each group touches. - The clarification, approval, replay and proposal rules. - A verification checklist against real operational behaviour. - **Hands off** - Assistant builder — the general task-triggered agent shape ## Others in Creating new agents - Assistant builder - Audit analyser - Spend approval --- # Other income # Other income Products Collects income from every source that is neither employment nor a business the borrower owns — rental income, benefits, pensions, investments, support payments. - **Used when** — After employment and self-employment, and wherever the borrower states an amount those two conversations do not account for. - **Collects** - Each income source, its kind, its amount and its frequency. - Rental income, with the property it comes from. - The same for a co-borrower. - **Returns** - One record per income source, typed so underwriting can decide which of them qualify. - **Evidence** - `bot-additional-income-collector` - `bot-additional-income-inquiry` - `bot-additional-incomes-collector` - `bot-other-income-details` - `bot-coborrower-additional-income-collector` - `bot-rental-income-assistant` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Personal identity # Personal identity Products Opens the application and collects who the borrower is — legal name, date of birth, taxpayer identifier, citizenship and marital status. - **Used when** — First in the loan-application task set. Completing it is what turns an anonymous application into a named one. - **Collects** - Legal name, date of birth and taxpayer identifier. - Citizenship status and marital status. - The same set again for a co-borrower, through its own variant. - **Returns** - The identity fields written to the loan record, and the application named for the borrower. - **Hands off** - Credit — consent to pull credit, and the pull itself - **Evidence** - `bot-personal-identity` - `bot-personal-identity-interactive` - `bot-personal-identity-collector-old-` - `bot-coborrower-personal-identity-collector` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Pipeline control panel # Pipeline control panel Data Runs the document-processing pipeline on request: resolves which documents actually exist for a set of records, checks what has already been processed, dispatches only the remainder, replays failures, and confirms the results reached their destination. - **Used when** — When a batch of records needs its documents processed, when a previous run left failures behind, or when someone needs to know whether a given account's documents made it through. - **Loads first** - Its own dispatch workflow, followed step by step rather than improvised. - The integration guide for the source system holding the document rows. - The read patterns for the store that records what has already been processed. - **Returns** - The source environment, the processing target, and the run identifier. - Input row counts, unique record counts, and how many fall outside supported handling. - Document-metadata counts, storage verification counts, and any location that could not be read. - The already-processed count and the count remaining to dispatch. - Dry-run and live dispatch counts, the queues targeted, and the manifest written. - Verification of the processed results, and a summary of any follow-up requests raised. ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production --- # Preapproval letter # Preapproval letter Products Produces the preapproval letter from the priced application, and refreshes it when the price behind it moves. - **Used when** — After a price is selected, and again whenever the borrower needs a current letter. - **Collects** - Which property or amount the letter should be written for. - **Returns** - The letter, and the record of the price it was written against. - **Evidence** - `broker-bot` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Pricing # Pricing Products Runs an actual price against the collected loan terms and explains the result in the conversation. - **Used when** — Once the loan terms, the credit result and the income are on the record. - **Collects** - Which of the priced options the borrower is choosing. - **Returns** - The priced options, and the selected one written to the loan record. - **Hands off** - Correction — changing a term the price was run against - **Evidence** - `bot-pricing` - `bot-price-assistant` - `bot-market-index` - `price-bot-api_calls` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Property data exploration # Property data exploration Data Answers questions about public property and business data in plain language — appraisal and parcel records, permits, registered companies, contractor reputation, geographic filters and the schema behind them — by driving the published tool surface rather than writing queries by hand. - **Used when** — When someone wants to count, list or cross-reference properties and businesses in a jurisdiction, or to understand what a schema field means. - **Loads first** - The tool-surface usage skill. - The coverage record for the jurisdiction in question, so an answer can be qualified by what is actually held. - **Returns** - The question as it was understood, the jurisdiction, and the filters applied, including any default threshold it chose. - The tools called in order, with their key parameters. - The answer — counts, listings with their evidence, or schema excerpts. - The method and the coverage limits, stated as how much of the population was inspected. - Gaps, assumptions and blockers, each with the exact fix. - **Hands off** - Public record ingestion — ingesting, refreshing and indexing a jurisdiction's public records ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Public record ingestion - Question answering - Report catalog - Search to production --- # Public record ingestion # Public record ingestion Data Brings a jurisdiction's public data online: discovers the sources, collects and validates them, loads and reconciles them into the query store, then publishes the jurisdiction's query table and coverage record and wires both into the tool surface. - **Used when** — When a new jurisdiction is being onboarded, an existing one refreshed, or an ingestion run monitored. - **Loads first** - The onboarding skill and the per-stage skills it drives. - **Returns** - The jurisdiction and sources targeted, and whether this is a pilot or the full set. - Which skills were driven, and the per-stage outcome — artifact counts per source against row counts in the store. - Completeness and freshness validation, with every gap named rather than implied. - The indexing outcome: the validation gate result, the published table and coverage pointers, the tool wiring, per-source coverage gaps, and a smoke query proving the jurisdiction is served. - Blockers, with the exact fix. - **Hands off** - Property data exploration — querying the jurisdiction once it is loaded and indexed ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Question answering - Report catalog - Search to production --- # Question answering # Question answering Data Resolves which approved source actually holds a figure, queries it live, and turns the verified answer into a secure, shareable, refreshing report. - **Used when** — When someone asks how many, or wants a table, a chart or a dashboard built on current data. - **Loads first** - The usage skills for each approved source — the query contract for live activity tables, the schema-exploration skill, the persistence product, and the shared business logic. - The report-publishing path, only after the numbers are verified. - **Returns** - The resolved source and the query actually run. - The answer, with the coverage it is bounded by. - A local preview built from verified data, then, on approval, the published report, its refresh schedule and its access configuration. - **Hands off** - Capability map — changing or provisioning a platform product rather than consuming one - Report catalog — registering the finished report where it can be found ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Report catalog - Search to production --- # Rate estimate # Rate estimate Products Gives a borrower an indicative rate from a short conversation, before any application exists. - **Used when** — At the top of the funnel, where someone wants a number before they will give a full application. - **Collects** - Enough of the loan shape to price it — amount, property value, purpose and occupancy. - A credit range, self-reported rather than pulled. - **Returns** - The estimate, and the message that presents it to the borrower. - **Hands off** - Pricing — an actual price against the collected terms - **Evidence** - `bot-personalized-rate-estimate` - `bot-personalized-rate-estimate-calculator` - `bot-personalized-rate-estimate-collector` - `bot-personalized-rate-estimate-result-message` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Real estate owned - Residency - Self-employment income - Workspace assistant --- # Real estate owned # Real estate owned Products Collects the properties the borrower already owns — address, value, how it is used, and what it earns or costs. - **Used when** — Where residency or income established that the borrower holds property besides the one being financed. - **Collects** - Each property, its address, its estimated value and how it is occupied. - Rental income and holding costs, where it is let. - The agent representing the borrower, where one is involved. - **Returns** - One record per property, joined to the income and the mortgage each carries. - **Hands off** - Mortgage details — the loan secured on a property the borrower owns - **Evidence** - `bot-real-estate-collector` - `bot-real-estate-agent-interactive` - `real-estate-interactive` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Residency - Self-employment income - Workspace assistant --- # Report catalog # Report catalog Data Builds and maintains the single page where existing reports are registered and found, with a command-line path for registering a new one. - **Used when** — When reports exist in several places and there is nowhere to look them up. - **Loads first** - Its own catalogue scaffold and deployment path. - **Returns** - The catalogue application and its deployment. - The registration command and what a registered entry carries. ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Search to production --- # Residency # Residency Products Collects where the borrower lives now and where they lived before, with the dates, so the address history covers the required period without gaps. - **Used when** — Immediately after identity, and again wherever a gap in the address history has to be filled. - **Collects** - The current address, how long the borrower has been there, and whether they own or rent. - Previous addresses, with dates, until the required history is covered. - The same history for a co-borrower. - **Returns** - The address history written to the loan record, with the periods it covers. - **Hands off** - Real estate owned — properties the borrower owns - **Evidence** - `bot-residency` - `bot-residency-collector` - `bot-residency-interactive` - `bot-previous-residency-collector` - `bot-coborrower-residency-collector` - `bot-coborrower-previous-residency-collector` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Self-employment income - Workspace assistant --- # Roster workflow # Roster workflow Providers Takes each partner's uploaded client list, matches it against the records under management, and returns partner-branded settlement and authorisation paperwork the same day. Outline A description of this agent has not been written yet. What would be here: - When it runs, and what triggers it - What it loads before it acts - What it returns - Which peer owns the adjacent work Source: its own specification — this agent is deployed and the network document records what it does, but neither kit carries its contract ## Others in Providers - File sync - Marketing stack - Send lifecycle --- # Router # Router Routing Reads the current roster and names which specialist and which skills fit the task, with the reasoning behind the choice. - **Used when** — At the start of any task where the right specialist is not obvious, or when someone wants an overview of what the fleet can do. - **Loads first** - The kit's own index, re-read on every request rather than recalled, so a newly added agent is routable the day it lands. - The shared engineering guidelines, for the constraints every recommendation inherits. - **Returns** - The recommended agents and skills, with the rationale for each. - How to invoke them. --- # Rule editor # Rule editor Platform Turns a plain-language request into a concrete change to phone-interaction rules, runs it against sample records to show exactly which numbers would and would not be called, and packages that before-and-after evidence for the rule owner to approve. Outline A description of this agent has not been written yet. What would be here: - When it runs, and what triggers it - What it loads before it acts - What it returns - Which peer owns the adjacent work Source: its own specification — this agent is deployed and the network document records what it does, but neither kit carries its contract ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Short links - Solver services - Template inventory --- # Search to production # Search to production Data Takes a retrieval system from a local prototype through to production: the index model, the migration off the local store, historical backfill, live ingestion per source, and the instructions an agent needs to use it. - **Used when** — When a retrieval prototype works and the question is what it takes to run it for real. - **Loads first** - The local prototype skill first, then the production retrieval skill. - The batch-workflow skill, for the backfill. - **Returns** - The prototype's status, command surface and verification results. - The corpus, chunk, link, embedding, metadata and data-governance contract. - The readiness gate result and the questions still open. - The production index model and the migration plan off the local store. - The backfill design, with cost, idempotency, metrics and replay. - The ingestion design per source. - The rollout plan, the verification, and the remaining limitations. - **Hands off** - Knowledge search — designing the retrieval agent itself ## Others in Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog --- # Self-employment income # Self-employment income Products Collects income from a business the borrower owns, including contract income reported on its own tax form. - **Used when** — Where the employment conversation established that the borrower is self-employed, or that some of their income is contract income. - **Collects** - The business, the borrower's ownership share, and how long it has traded. - Income drawn from it, and the tax form it is reported on. - **Returns** - The self-employment income records on the loan record, separated from employed income. - **Evidence** - `bot-self-employment-details` ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Workspace assistant --- # Send lifecycle # Send lifecycle Providers Owns the whole dispatch and feedback loop as one lifecycle: provider setup, routing, the send handoff, delivery events, and ingestion of what comes back. - **Used when** — When a provider adapter, a send workflow, delivery-feedback processing or response ingestion is being built for a message channel. - **Loads first** - The communication-activity skill, for the lifecycle contract. - The shared engineering guidelines. - **Returns** - The provider and routing configuration. - The execution-artifact and send-payload schema. - The provider-correlation and status-persistence plan. - The event contract, where provider outcomes are consumed asynchronously. - The criteria that close an activity's lifecycle. - **Hands off** - Audience selection — audience selection - Template inventory — template management - Channel assembly — runtime scoring ## Others in Providers - File sync - Marketing stack - Roster workflow --- # Sharing portals # Sharing portals Delivery also Providers Builds secure external file-sharing portals: hosted sign-in, private folder browsing, per-user grants, administrator-managed accounts, a custom domain, runtime configuration and a design-matched interface. - **Used when** — When people outside the organisation need controlled access to files and a shared link is not an acceptable answer. - **Loads first** - The front-end and back-end skill, and the design-to-code skill. - The responsive-test skill, and the continuous-integration skill. - The shared engineering guidelines. - **Returns** - The architecture summary and the repository layout changes. - The authentication and administrator-access design. - The per-user file grant model. - The interface implementation notes, and the files changed with the reason. - Tests added or updated, with commands and results. - The deployment path, the required configuration, and the promotion route between environments. - A deployment runbook and rollback notes. - A security verification checklist and any residual risk. ## Others in Delivery - Analytics instrumentation - Application scaffolding - Design implementation - Design testing - Interface triage - Marketplace architecture --- # Short links # Short links Platform Builds the link-shortening and click-telemetry service behind outbound messages: issuing short tokens, storing the link as a graph record, resolving a token through a graph query, redirecting, and publishing a click fact onto the shared event bus. - **Used when** — When outbound messages need trackable links and the click has to become a fact other systems can consume. - **Loads first** - The short-URL skill, for the issuance and resolution patterns. - **Returns** - The architecture: a private issuance interface, a public resolver, graph storage, graph-query resolution, event publication, and replay of the dead-letter queue. - The data contract for the stored link and its optional schema-backed edges. - The resolver's order of operations. - The exact event contract for a published click. - The dead-letter and replay behaviour. - Infrastructure discovery and custom-domain routing decisions. - The patterns explicitly forbidden, and why. ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Solver services - Template inventory --- # Solver services # Solver services Platform Designs and scaffolds optimisation services: a distributed layer that prepares data at scale, a pure solver core, and the infrastructure that wires them together. - **Used when** — When assignment, scheduling or capacity has to be decided by an optimiser rather than by a sort. - **Loads first** - The solver-service skill, before any code is written. - The shared engineering guidelines. - **Returns** - The optimisation model — decision variables, constraints, objective, and the input and output contracts. - The service architecture. - An implementation plan by layer. - The verification strategy, covering both solver behaviour and an end-to-end run. ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Template inventory --- # Spend approval # Spend approval Creating new agents Builds the workflow that watches model spend against a threshold, opens an approval task when it is crossed, and raises the limit by a configured increment only after a human completes that task. - **Used when** — When a spend limit needs to move on evidence and approval rather than on someone noticing. - **Loads first** - The agent-building and batch-workflow skills. - The continuous-integration skill, for the per-environment deployment path. - **Returns** - The repository layout — the workflow's task handlers, the approval webhook handler, shared configuration modules and tests. - The state-machine shape, from plan through a per-user approval wait to the aggregate, and how the schedule starts it. - The parameter and secret list, with the exact commands an operator runs per environment. - The runtime contract: plan output, item schema, task body, webhook filter, ledger schema, and every named rejection reason. - The permissions actually granted, least-privilege, per component. - A verification log covering the approval path, a non-approver, a cap rejection, a drifted limit, a replayed webhook, a timeout, and a redrive. - Rollback notes for both the code and the configuration. ## Others in Creating new agents - Assistant builder - Audit analyser - Operations agent builder --- # Template inventory # Template inventory Platform Builds the systems that keep message templates versioned, reviewed and in step with whatever sends them — the repository layout, the metadata contract, discovery of the source tables, and one-time or recurring synchronisation from the operational store into a version-controlled inventory. - **Used when** — When templates live in an operational system and need to become reviewable artifacts, or when a template-management agent is being built. - **Loads first** - The channel-template skill, for the inventory and synchronisation patterns. - The shared engineering guidelines. - **Returns** - The template repository layout and its metadata contract. - The source-discovery result, or the minimal set of questions still unanswered. - The create, read, update and delete workflow, and the synchronisation design. - The active and inactive rules, and the family-to-variant rules. - Acceptance checks for the inventory and for the runtime workflow. - **Hands off** - Audience selection — audience selection - Send lifecycle — provider delivery - Channel assembly — runtime scoring ## Others in Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services --- # Workspace assistant # Workspace assistant Products The assistant inside the internal workspace: answers a reviewer's questions about an application in progress and drafts the message going back to the borrower. - **Used when** — While a person is working an application, rather than while a borrower is answering one. - **Collects** - The reviewer's question, and the application it is about. - **Returns** - The answer, and the draft reply for the reviewer to send or edit. - **Evidence** - `aira` - `aira-messaging` ## Operations ### Workspaces `POST` `/` #### Create a new workspace `createWorkspace` ##### Request application/json Copy ``` { "name": "Agent", "default_assistant": {"assistant_name": "leadsGeneric", "context_message": "Questions related to leads."}, "assistants": [ {"assistant_name": "SendEmail", "context_message": "Questions related to sending emails."}, {"assistant_name": "GeneratePostcard", "context_message": "Questions related to generating postcards."} ] } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Name of the workspace | | `default_assistant` | `object` | Assistant object | | `assistant_name` | `string` | Name of the assistant | | `context_message` | `string` | Context message for the assistant | | `assistants`required | `array` | List of assistants for the workspace | | `routing_model` | `string` | Routing model. Only GPT-4o and later models are supported. GPT4-4o mini is also supported. | ##### Response `200``application/json` 4 fields Ok. | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Name of the workspace | | `default_assistant` | `object` | Assistant object | | `assistant_name` | `string` | Name of the assistant | | `context_message` | `string` | Context message for the assistant | | `assistants`required | `array` | List of assistants for the workspace | | `routing_model` | `string` | Routing model. Only GPT-4o and later models are supported. GPT4-4o mini is also supported. | `GET` `/{workspace_name}` #### Get a workspace `getWorkspace` Get a workspace by name ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `workspace_name` required | `string` path | `my-workspace` | Name of the workspace | ##### Response `200``application/json` 4 fields Ok. | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Name of the workspace | | `default_assistant` | `object` | Assistant object | | `assistant_name` | `string` | Name of the assistant | | `context_message` | `string` | Context message for the assistant | | `assistants`required | `array` | List of assistants for the workspace | | `routing_model` | `string` | Routing model. Only GPT-4o and later models are supported. GPT4-4o mini is also supported. | ### AIRA Messaging `POST` `/messaging/{workspace_name}/messages` #### Send message `sendMessage` Send a message to the AIRA workspace ##### Request application/json Copy ``` { "connection_id": "123", "x-sc-trace-id": "123", "message": [ { "type": "text", "text": "Hello" } ], "payload": { "person_identifier": "123", "regenerate_response": true } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `workspace_name` required | `string` path | `workspace` | The name of the workspace | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `connection_id`required | `string` | The connection id | | `x-sc-trace-id` | `string` | The trace id | | `message`required | `object[]` | The message to send | | `type`required | `string` | The type of the message`text` | | `text`required | `string` | The content of the message | | `payload`required | `object` | The payload | | `person_identifier`required | `string` | The person identifier | | `regenerate_response` | `boolean` | Regenerate the response | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error message | ##### Other responses `200` `GET` `/messaging/{connection_id}/messages` #### List messages by connection ID `listMessages` List messages List messages by connection id ##### Response application/json Copy Messages history ``` { "messages": [ { "role": "user", "content": "Hello" }, { "role": "assistant", "content": "Hi" } ], "openai_thread_id": "123" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `connection_id` required | `string` path | `dfYn_eqooAMCFDA=` | The connection id | ##### Response `200``application/json` 2 fields Messages history | Field | Type | Description | | --- | --- | --- | | `messages` | `object[]` | The messages | | `role` | `string` | The role`user``assistant` | | `content` | `string` | The content | | `openai_thread_id` | `string` | The openai thread id | ### Route `POST` `/{workspace_name}/route` #### Process route request `processRouteRequest` Process a route request Process a route request for the specified workspace ##### Request application/json Copy ``` { "message_history": [{"role": "System", "content": ""}, {"role": "System", "content": ""}], "input_text": "" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `workspace_name` required | `string` path | `my-workspace` | Name of the workspace to route the request to | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `input_text` | `string` | Input text for the route | | `message_history` | `object[]` | Message history | | `role` | `string` | Role of the message`assistant``user` | | `content` | `string` | Text of the message | ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `openai_assistant_id` | `string` | OpenAI assistant ID | | `configuration_id` | `string` | Configuration ID | | `assistant_name` | `string` | Staircase assistant name | ## Others in Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income --- # Routing # Routing The way into the fleet: one agent reads a request and hands it to the specialist that owns the work. - Router Reads the current roster and names which specialist and which skills fit the task, with the reasoning behind the choice. --- # Runtimes # Runtimes The same registry served over a standard-input transport, a streaming HTTP transport, and an edge runtime. Three transports, one tool registry. The standard-input entry is the path a desktop client launches; the HTTP entry is stateless, constructing a fresh server and transport per request, which is the shape a serverless deployment requires; the web handler bridges the same registry into an edge runtime. Five separate agent clients have working install paths against the same surface. - The same registry is served over a standard-input transport, a streaming HTTP transport, and an edge runtime. - Documented, working install paths exist for five separate agent clients — this is a multi-client surface, not a single-vendor integration. - Configuration is environment-supplied, so pointing the surface at a different set of jurisdictions is a configuration change rather than a release. ## How it works Configuration is supplied by the environment, so pointing the surface at a different set of jurisdictions is a configuration change rather than a release. The server holds no database. Query tools read published per-jurisdiction tables directly over HTTP by content address, range-reading the columns a query needs rather than downloading a dataset, which is why a consumer can run their own copy against the same published data instead of depending on a shared backend. Every fetched range is hash-verified against its content address before it is returned, and a mismatch throws rather than being served. --- # Skills # Skills Packaged, versioned know-how any agent or engineer picks up: how to integrate a partner, how to model data, how to test an interface. A skill is a unit of instruction with a version, not prompt text pasted into an agent definition. An agent composes the skills a task needs, and a skill improved once improves every agent that composes it. Writing knowledge down once and reusing it is what stops it evaporating when a person leaves or a system changes. The county onboarding runbook documented under bringing a jurisdiction online is a worked example: ten stages, each its own skill, run in sequence with an intake at the start and interruption only on a genuine blocker. - Packaged, versioned know-how — how to integrate a partner, how to model data, how to test a design — that any agent or engineer picks up. Knowledge is written once and reused everywhere, so it compounds instead of evaporating when a person leaves or a system changes. Packaged, versioned know-how — how to integrate a partner, how to model data, how to test a design — that any agent or engineer picks up. Knowledge is written once and reused everywhere, so it compounds instead of evaporating when a person leaves or a system changes. --- # Tools # Tools The tool registry a client connects to: one definition set served over several transports, with a guarded query surface. One registry is the single source both the standard-input entry and the HTTP entry read, so the two transports cannot drift apart. Every tool carries a title, a description, and a per-parameter description written for a model rather than for a reader who already knows the domain. - One tool registry is the single source both transports read, so the stdio entry and the HTTP entry cannot drift apart. - Every tool carries a title, a description, and a per-parameter description written for a model rather than for a reader who already knows the domain. - Query tools are guarded in four layers: comment and literal stripping, multi-statement rejection, a read-only statement allowlist, and an unconditional row cap. ## How it works The query tools accept caller-written SQL, which is only safe because the guard is explicit. Four layers, in order: comments and string literals are stripped before any keyword matching, so a value like `'copy'` inside a string cannot trip the filter; multiple statements are rejected; the statement must begin `SELECT` or `WITH`; and the caller's query is wrapped in an outer select with a row cap the caller cannot override. Stripping literals before matching is what a plain keyword scan does not do. A scan over raw text rejects `owners_text ILIKE '%copy%'`, which is a legitimate query, and a guard that rejects legitimate queries is one callers route around. Tools that author their own SQL use a separate path with positional binding and skip the caller validator, because they are safe by construction rather than by inspection. ## The registry ### `listClassesByDataGroup` List classes by data group List classes for a property data group with names and descriptions - `groupName`stringrequired The data group name, case-insensitive ### `listPropertiesByClassName` List properties by class name Lists JSON Schema property names for a property class (excludes source_http_request) - `className`stringrequired The class name, case-insensitive ### `getPropertySchema` Get property schema by class and property Returns the full JSON Schema object for a class property - `className`stringrequired Class name, case-insensitive - `propertyName`stringrequired Property name, case-insensitive ### `getVerifiedScriptExamples` Get verified script examples Get most relevant working examples of the code, that maps data to the canonical property schema - `query`stringrequired Description of the example meaning. Wll be used to search for similar examples. - `topK`number Number of results (default 5) ### `listOracleProperties` List Oracle open-data properties Paginated discovery of properties for a county. Returns slim entries (propertyId, parcelIdentifier, cid, county, fileSizeBytes) plus summary fields (address, marketValue, ownerName) when served from the query table. Use getOracleProperty to fetch full consolidated data for a specific entry. - `county`string Filter by county name (case-insensitive) - `limit`number Number of results to return (default 50, max 500) - `offset`number Zero-based offset for pagination (default 0) ### `getOracleProperty` Get Oracle open-data property Fetch the full consolidated property JSON (appraisal, permits, Sunbiz, BBB) from content-addressed storage. Provide exactly one of parcelIdentifier, propertyId, or cid. - `parcelIdentifier`string The property parcel identifier (digits) — looked up in the manifest to resolve its content-addressed storage content address - `propertyId`string The property UUID — looked up in the manifest to resolve its content-addressed storage content address - `cid`string content-addressed storage content address for the consolidated property JSON - `county`string County to look up the parcel/property in (case-insensitive). Selects which county's open data to read when the deployment serves multiple counties. ### `getOracleDatasetInfo` Get Oracle open-data dataset info Returns dataset-level metadata for a county: county, propertyCount (live row count when served from the query table), state, and provenance/content address fields on the legacy path. When per-source coverage is configured, also returns datasets[] with, per source (appraisal, permits, sunbiz, bbb), ingestedCount, expectedCount, completionPercent, and first/last loaded timestamps — so callers can qualify partial answers by coverage. For a coverage-only county (no property dataset served) propertyCount is null and propertyDatasetAvailable is false, so callers can distinguish a missing property table from a county with zero properties. - `county`string County to report dataset info for (case-insensitive). Selects which county's open data to read when the deployment serves multiple counties. ### `getPropertyPermits` Get property permits (on-demand) Fetch permit records for a property by parcel ID. Returns cached permits immediately if available. If not cached, enqueues a harvest job (reuses the permit-harvest Lambda) and returns a status indicating the harvest is in progress — poll again after ~90 seconds. Permits are cached to content-addressed storage after harvest completes. - `parcelId`stringrequired The property parcel identifier (digits, e.g. '1234567890000') - `countyFips`string County FIPS code (default: 12071 = Lee County FL) ### `findPropertiesInArea` Find properties in an area Returns the set of properties whose centroid (latitude/longitude) falls inside a user-supplied bounding box or polygon. Provide exactly one of bbox or polygon. Reads the per-county property query table (falls back to the derived geo index); no NOAA/FEMA geometry is used. ### `sumPropertyValueInArea` Sum property value in an area Returns the exact sum of avm_value over the properties whose centroid falls inside a user-supplied bounding box or polygon, plus the in-area count. Null valuations are treated as 0. Provide exactly one of bbox or polygon. Reads the per-county property query table (falls back to the derived geo index). ### `queryProperties` Query properties (SQL) Run a read-only SQL SELECT against a county's flat property query table (view name 'properties', one row per property) backed by embedded DuckDB. Use getPropertyQuerySchema first to see available columns. SAFETY: a single SELECT statement only (a leading WITH/CTE is allowed); multiple statements and any mutating or file/extension keyword (INSERT/UPDATE/DELETE/COPY/ATTACH/INSTALL/LOAD/PRAGMA/CALL/SET …) are rejected; results are always capped at 1000 rows. - `county`stringrequired County to query (case-insensitive), e.g. 'Lee'. - `sql`stringrequired A single read-only SELECT statement over the 'properties' view. - `limit`number Max rows to return (default 100, max 1000). Always enforced. ### `getPropertyQuerySchema` Get property query schema Returns the column list, DuckDB types, and a one-line description of each column of the 'properties' query table for a county, so queryProperties can be written without guessing. Notes that some coverage-dependent fields may be NULL. - `county`stringrequired County to describe (case-insensitive), e.g. 'Lee'. ### `queryPermits` Query permits (SQL) Run a read-only SQL SELECT against a county's flat permit query table (view name 'permits', one row per building permit) backed by embedded DuckDB. Use getPermitQuerySchema first to see available columns and getPermitCoverage to qualify aggregate answers by source. SAFETY: a single SELECT statement only (a leading WITH/CTE is allowed); multiple statements and any mutating or file/extension keyword (INSERT/UPDATE/DELETE/COPY/ATTACH/INSTALL/LOAD/PRAGMA/CALL/SET …) are rejected; results are always capped at 1000 rows. - `county`stringrequired County to query (case-insensitive), e.g. 'Lee'. - `sql`stringrequired A single read-only SELECT statement over the 'permits' view. - `limit`number Max rows to return (default 100, max 1000). Always enforced. ### `getPermitQuerySchema` Get permit query schema Returns the column list, DuckDB types, and a one-line description of each column of the 'permits' query table for a county, so queryPermits can be written without guessing. Notes that date/value fields are frequently NULL depending on the permit source. - `county`stringrequired County to describe (case-insensitive), e.g. 'Lee'. ### `getPermitCoverage` Get permit coverage by source Returns per-source-system permit coverage for a county from the 'permits' query table: each source_system with its permit_count and completion_date range (earliest/latest), plus the overall total. The donphan agent uses this to QUALIFY aggregate permit answers (permit data lags appraisals and some sources may have NULL dates). - `county`stringrequired County to report permit coverage for (case-insensitive), e.g. 'Lee'. --- # The consumer application # The consumer application A borrower-facing application flow assembled from the mortgage products: conversational intake, verification calls, pricing, an automated decision, and a generated loan application with its standards export. The flow is a queue of tasks with one task in progress at a time. Three task types cover everything in it: a conversational agent, a third-party API call, and a form. A fourth type groups tasks under a named milestone. Each data domain is two agents rather than one. An inquiry agent gathers information conversationally and knows only which data points it needs; a schema agent takes the transcript and writes it into the canonical model. The inquiry agent never learns the storage shape, which is what keeps the conversation from being driven by the schema. Task dependencies carry two separate gates: one deciding when a task may start, another deciding when its output may be committed. Separating them is what lets a background extraction run while a different agent is still talking to the borrower, without a write race. ## The flow A borrower answers questions in conversation rather than filling a form. Each answer is written into the canonical model as it arrives, so the application is a live record from the first question rather than a form submitted at the end. ## The agents that conduct it The application is not one agent. It is a set of them, each responsible for one section of the loan application — identity, residency, employment and income, assets, liabilities, real estate, declarations — with a router dispatching between them and each one writing into the same canonical record. A section is a separately versioned unit, so a change to how employment is collected does not touch how assets are. Behavioural fixtures assert the exact tool calls each agent makes, and they run before a deploy. An agent that stops asking the right question fails the build rather than degrading quietly in front of a borrower. How that is gated ## What it produces - A completed loan application — the full standard form, populated from the conversation rather than transcribed from it. - A standards export — the same record emitted in the industry interchange format, so any downstream system can read it without a bespoke mapping. - A letter — the borrower-facing document, generated from the same record it was decided on. ## What it composes - POS - Identity - Credit - Employment - Income - Asset - Price - Government - Approval - Document - Lexicon --- # Data # Data Two domain models: the mortgage model covers the loan transaction end to end, and the property model covers the physical asset and the public record behind it. Both models are class dictionaries: a class, its properties, each property's type, and the classes it points at. Every product request and response is a subset of one of them, so a field name on a product page resolves to a definition here rather than to a per-endpoint glossary. The two are separate dictionaries with separate governance, and they overlap by name where both descend from the same standards work. The overlap below is computed from the two files rather than asserted. ## Mortgage model The transaction: the parties, the loan and the mortgage plan behind it, the documents, the fees and taxes, income and employment, credit, insurance, the payment schedule and the borrower's wider financial profile. Definitions are complete sentences by rule. The dictionary as written also models the platform that served it — its API objects, its ticketing, its tenancy and its own catalogue. Those classes are named and withheld rather than published, because a reader looking for the shape of a loan does not need the shape of the software that carried it. - `address` - `credit` - `document` - `employment` - `employment_income` - `fee` - `finance_relation` - `income` - `insurance` - `loan` - `mortgage_application` - `mortgage_plan` - `payment` - `person` - `person_credit` - `person_income` - `pricing_schema` - `property` - `property_tax` - `tax` ## Property model The asset: parcel, structure, layout, lot, deed, tax, sales history, permits and the surrounding jurisdiction records. Grouped below by the question each class answers about a property, which is the grouping the extraction pipeline itself uses. - `property_seed` - `unnormalized_address` - `address` - `parcel` - `person` - `property` - `tax` - `tax_jurisdiction` - `tax_exemption` - `lot` - `sales_history` - `file` - `layout` - `flood_storm_information` - `structure` - `property_improvement` - `utility` - `deed` - `geometry` - `appliance` - `homeowners_association` - `hoa_policy` - `loan` - `property_ranking_overall` - `inspection` - `environment_characteristics` - `safety_security` - `transportation_access` - `school` - `tax_authority` ## Shared lineage Both models descend from the same standards work, and the overlap is the evidence for that rather than a sentence claiming it. A row appears here because both dictionaries name the class; it disappears the moment either renames it. A shared name is not a shared definition. The two models were governed separately and a class on both sides may carry different properties, so the table links to each side rather than merging them. Shared classes are computed at build time by intersecting the class names in the two dictionaries: a class is listed because both models name it, and it drops out the moment either one renames it. A class with no property-model link exists in the property graph but is reached by no published data group, so it has no page. | Class | Mortgage model | Property model | | --- | --- | --- | | `address` | open | open | | `credit` | open | not published | | `document` | open | not published | | `employment` | open | not published | | `fee` | open | not published | | `finance relation` | open | not published | | `income` | open | not published | | `insurance` | open | not published | | `loan` | open | open | | `mortgage application` | open | not published | | `mortgage plan` | open | not published | | `payment` | open | not published | | `person` | open | open | | `pricing schema` | open | not published | | `property` | open | open | | `tax` | open | open | --- # Mortgage model # Mortgage model The mortgage class dictionary: the loan transaction, its parties, its collateral and the documents and money that move with it. The model derives from the industry standard for mortgage data and covers the whole life of a loan — origination, funding, secondary market and servicing — together with the document types the transaction produces. The dictionary as written covers a second subject as well: the platform that served it, in classes for its API objects, its ticketing, its tenancy and its own product catalogue. Those are withheld by name, each with its reason, so what remains here is the mortgage. It is a graph rather than a relational schema, and it is flat: no class nests another. A relationship between two classes is itself a class, whose properties join them. Every class is independently addressable and a relationship can carry its own attributes, which a foreign key cannot. ## How it is governed Naming is a written law rather than a convention. Types, properties and relationships are lower snake case; abbreviations are spelled out unless expansion is painful; and the property suffix carries the type — an indicator is boolean, an identifier is an identifier, an amount and a percent are decimal, and a type is an enumeration whose range is a named enumeration set backed by its own file. Definitions are required to be complete sentences that define the term rather than expand the acronym. The stated reason on record is future use by a conversational system: a definition reading as a glossary stub transfers nothing to a model reading it. Every proposed change ran a fixed sequence: a use case submitted on a form, a draft class diagram, alignment against the existing model, review by a named domain expert, revision, notice to the requester, then publication. ## How it works Identity is immutable. Every state of an entity is a new database-generated identifier, and a stable global identifier groups every state of the same real-world thing, named for its class. Reading history is a query over that group rather than an audit table, and a correction never destroys what it corrected. An attribute becomes its own class on six tests: whether it repeats, whether it is shared, whether it has internal structure, whether it changes over time, whether it relates to other attributes, and how it is used. The tests are what kept the model from either flattening into wide records or exploding into a class per field. There is a deprecation pipeline for the model itself: duplicate analysis, impact analysis across every consumer of a class, automatic upcasting of a caller's payload to the current model, and usage monitoring of classes on the way out. Several removals were executed through it, each with its own recorded runbook. Validation is two-layered — see Lexicon for the serving surface. Syntactic shapes constrain datatype, enumeration, pattern, length and range. Semantic shapes carry conditional rules: if a borrower's marital status is married, the spouse's name becomes required. ## Classes - `address` - `credit` - `document` - `employment` - `employment_income` - `fee` - `finance_relation` - `income` - `insurance` - `loan` - `mortgage_application` - `mortgage_plan` - `payment` - `person` - `person_credit` - `person_income` - `pricing_schema` - `property` - `property_tax` - `tax` ## The classes carrying the most | Class | Properties | Referenced by | | --- | --- | --- | | `address` | 36 | 0 | | `insurance` | 32 | 1 | | `loan` | 30 | 2 | | `person` | 23 | 4 | | `payment` | 16 | 1 | | `pricing_schema` | 14 | 1 | | `property` | 13 | 2 | | `finance_relation` | 12 | 0 | Derived from: mortgage class dictionary (repository source) --- # address # address A physical location, described down to the components a postal system and a legal description each need. An address describes a physical location described in terms of street address, city, state, region, province, country and other geo-location references. ## Why it matters The widest class in the model, because an address has to satisfy several consumers at once: postal delivery, legal description, geocoding, and the jurisdiction lookups that tax and title depend on. Components are separate properties rather than lines of text. A line is enough to print a letter and not enough to match two records, and matching is the operation that actually gets performed. ## Properties | Property | Type | Definition | | --- | --- | --- | | `address_format_type` | `string` | Address format type refers to the different conventions or standards used to structure and format addresses in various countries or regions. | | `address_line_1` | `string` | Address line 1 is the first line of the address where the primary information for locating a specific location or recipient is provided. | | `address_line_2` | `string` | Address line 2 is the second line of the address where the primary information for locating a specific location or recipient is provided. | | `address_line_3` | `string` | Address line 3 is the third line of the address where the primary information for locating a specific location or recipient is provided. | | `address_type` | `enumeration` | Address type is a classification or categorization of an address based on its purpose or characteristics. `as_shown_on_tax_return``corporate_headquarters``current``legal_entity_formation``mailing``other``primary``prior` | | `address_type_other_description` | `string` | If an address type is 'other,' address type other description provides more details on the address type. | | `address_unit_designator_type` | `enumeration` | Address unit designator type describes the category that a specific unit belongs to. `apartment``basement``building``condo``department``floor``front``hangar``key``lobby``lot``lower``office``penthouse``pier``rear``room``side``space``stop``suite``trailer``unit``upper` | | `attention_to_name` | `string` | An attention to name on an address is an optional line that can be included in an address to indicate the name of a specific person or department within an organization to whom the mail is intended. | | `carrier_route_code` | `string` | A carrier route code is a unique identifier assigned by the United States Postal Service (USPS) to a specific mail delivery route or group of addresses serviced by a single mail carrier. | | `cbsa_code` | `string` | A CBSA code is a Canada Border Services Agency (CBSA) code, which is a unique identifier assigned to specific ports, airports, or border crossing points in Canada. The CBSA code helps facilitate the import/export process and customs clearance activities at these designated locations. | | `city_name` | `string` | City name refers to the name of the city in which the address is located. | | `country_code` | `string` | Country code is a code that represents the country in which the address is located. | | `country_name` | `string` | Country name refers to the country where a person resides. | | `county_code` | `string` | County code is a code that represents the county in which the address is located. | | `county_name` | `string` | A property county name refers to the name of the county in which a property is located. In the United States, counties are geographic and political subdivisions of states, typically governed by a county government. Each county is identified by a unique name and is responsible for providing certain public services to residents, such as law enforcement, public schools, and infrastructure maintenance. | | `created_datetime` | `dateTime` | Created_datetime describes when an address was created in a system. | | `delivery_point_bar_code` | `dateTime` | A Delivery Point Barcode (DPBC) is a barcode used by the United States Postal Service (USPS) to facilitate the automated sorting and delivery of mail. It contains encoded information that helps identify the specific delivery point or address to which mail should be delivered. | | `delivery_point_bar_code_check` | `dateTime` | A Delivery Point Barcode (DPBC) check is a verification process used to ensure the accuracy and validity of a Delivery Point Barcode, which is a barcode used by the United States Postal Service (USPS) to automate the sorting and delivery of mail. | | `full_address` | `string` | A full address includes all the necessary information to identify and locate a specific location or recipient. | | `highway_contract_route_identifier` | `string` | A highway contract route (HCR) identifier is a unique code assigned to a specific highway contract route used for mail transportation by the United States Postal Service (USPS). | | `last_updated_datetime` | `dateTime` | Last_updated_datetime describes when an address was last updated in a system. | | `mail_stop_code` | `string` | A mail stop code, also known as a mail code or department code, is a unique identifier used within an organization to facilitate the sorting and delivery of internal mail or correspondence. It is primarily used in large organizations where there may be multiple departments or units located in the same physical location. | | `plus_four_postal_code` | `string` | A postal code plus four, also known as a ZIP code plus four (in the United States) is a numerical extension to a postal code. | | `post_office_box_identifier` | `string` | A post office box identifier refers to the unique number or alphanumeric code assigned to an individual or organization's post office box (PO Box) for receiving mail at a post office facility. | | `postal_code` | `string` | A postal code, also known as a ZIP code (in the United States) or postcode (in many other countries), is a numerical code used by postal services to identify specific geographic areas for efficient mail sorting and delivery. | | `rural_route_box_identifier` | `string` | A rural route box identifier, also known as an RR box identifier, is a number or alphanumeric code assigned to a mailbox or mail receptacle on a rural route. | | `rural_route_identifier` | `string` | A rural route identifier, also known as an RR identifier, is a number or alphanumeric code assigned to a specific rural route for mail delivery. In rural areas, where homes and businesses are often spread out over long distances, a rural route is a designated path followed by mail carriers to deliver mail to multiple addresses along that route. | | `sequence_number` | `string` | A license sequence number is a unique numerical identifier assigned to license within a specific sequence or order. It is used to indicate the position or sequence of a license within a given range or list. | | `state_code` | `string` | State code is a code that represents the state in which the address is located. | | `state_name` | `string` | State name refers to the name of the state in which the address is located. | | `street_name` | `string` | A street name is the name of a street on which an address is located. | | `street_post_directional_text` | `string` | Street post directional text refers to the directional indicator or suffix added to a street name to provide additional information about the direction or orientation of the street segment. It helps to clarify the position of a particular street in relation to other streets or landmarks in a given area. | | `street_pre_directional_text` | `string` | Street pre directional text refers to the directional indicator or prefix added to a street name to provide additional information about the direction or orientation of the street segment. It helps to clarify the position of a particular street in relation to other streets or landmarks in a given area. | | `street_primary_number` | `string` | Street primary number refers to the numerical part of a street address that indicates the specific location or position of a building or property along a street. | | `street_suffix` | `string` | A street suffix, also known as a street type or street name suffix, is a word or abbreviation that follows the street name in an address, indicating the type or category of the street (e.g., Drive, Circle, Boulevard). | | `unit_identifier` | `string` | A unit identifier is a reference to the specific unit, suite, apartment, or other secondary identifier associated with an address. It is used to differentiate individual units within a larger building or complex. | --- # credit # credit A credit record for a person: scores, their models, and the liabilities the report carries. Credit refers to information about an individual's or organization's creditworthiness: their ability to borrow money with the promise of repaying the debt later, the amount of money they've borrowed but haven't repaid, and their history of repaying debt according to credit agreements. ## Why it matters Bureaus disagree in shape, not only in value. Score model naming, liability classification and joint-borrower treatment all differ between them, and this class is the single form all of it lands in. A score is meaningless without its model, so the two travel together rather than a bare number being stored. That is the difference between a record that can be compared across bureaus and one that cannot. ## Properties | Property | Type | Definition | | --- | --- | --- | | `credit_identifier` | `string` | A credit identifier is a unique identifier for the credit record of an individual or organization. | | `credit_score` | `integer` | A credit score is a numerical representation of a person's creditworthiness based on their credit history. It's a three-digit number that ranges from 300 to 850, with higher scores indicating better creditworthiness. | ## Referenced by - `person` - `person_credit` --- # document # document A document in the transaction: its type, its contents once extracted, and what it evidences. A document is a written or printed record that contains information, data, or instructions in a fixed form that can be stored, transmitted, or communicated. ## Why it matters The model covers the document types the industry produces rather than a generic file record — the loan application and its coborrower variant, tax returns and their schedules, wage statements, the loan estimate, closing data and the preapproval letter each have a recorded mapping into this model. That is what makes an extracted document usable rather than merely stored: the fields land in the same classes a directly-supplied value would, so a downstream step cannot tell whether a figure was typed or read off a page — except by the source recorded against it. ## Properties | Property | Type | Definition | | --- | --- | --- | | `document_mime_type` | `enumeration` | A document MIME type, or Multipurpose Internet Mail Extension type, is a standard way of identifying the format of a document based on its content. It is used by web servers to communicate the file format to a web browser, allowing the browser to properly display or handle the document. `application_json``application_Id_json``application_xml` | | `document_name` | `string` | A document name is a title or label given to a document to identify it and distinguish it from other documents. | | `document_type` | `enumeration` | Document type refers to the classification or categorization of a document based on its purpose, content, or format. `abstract_notice_agreement``abstract_of_judgment``achdebit_authorization``acknowledgment_of_notice_of_right_to_cancel``affidavit_of_death``affidavit_of_lost_note``affiliated_business_arrangement_disclosure``airport_noise_pollution_agreement``alternative_request_for_agreement_of_short_sale``amendatory_clause``amortization_schedule``application_disclosure``application_disclosure_additional_credit_and_debt``appraisal_recertification``appraisal_report``appraisal_report_desktop``appraisal_report_exterior_only``appraisal_report_interior_exterior``appraisal_review``appraisal_review_exterior_only_inspection_with_value_opinion``appraisal_review_exterior_only_without_value_opinion``appraisal_review_interior_exterior_inspection_with_value_opinion``appraisal_review_interior_exterior_without_value_opinion``appraisal_review_no_inspection_with_value_opinion``appraisal_review_request``appraisal_review_without_value_opinion``approval_letter``arm_disclosure``articles_of_incorporation``assignment``assignment_assignment_of_deed_of_trust``assignment_assignment_of_mortgage``assignment_assignment_of_rents``assignment_assignment_of_trade``assignment_blanket_assignment``assignment_cooperative_assignment_of_proprietary_lease``assumption_agreement``assurance_of_completion``attestation_of_damage_to_property``attorney_in_fact_affidavit``attorneys_opinion_letter``automated_underwriting_feedback``automated_valuation_report``automated_valuation_report_with_inspection``avm_feedback``bailee_letter``balance_transfer_authorization_notice``balloon_refinance_disclosure``bank_deposit_slip``bank_statement``bank_statement_401_k``bank_statement_checking_account``bank_statement_mutual_fund_account``bank_statement_saving_account``bank_statement_stock_account``bankruptcy_discharge_notice``benefit_plan_distribution_statement``benefit_plan_distribution_statement_401_k``benefit_plan_distribution_statement_annuity``benefit_plan_distribution_statement_pension``benefit_plan_distribution_statement_trust``bid``birth_certificate``bond_certificate``borrower_acknowledgment_of_property_condition``borrower_authorization_to_release_information``borrower_correspondence , borrower_correspondence_gap_in_employment``borrower_correspondence_letter_of_explanation``borrower_correspondence_letter_of_intent``borrower_correspondence_qualified_written_request``borrower_correspondence_trailing_spouse``borrower_lien_affidavit``borrowers_certification``borrowers_contract_with_respect_to_hotel_and_transient_use_of_property``breach_notice``broker_disclosure_statement``broker_price_opinion``broker_price_opinion_desktop``broker_price_opinion_exterior_inspection``builders_certification``builders_certification_builder_certification_of_plans_and_specifications``builders_certification_builders_certificate``builders_certification_property_inspection``builders_certification_termite_treatment``building_permit``business_license``buydown_agreement``buying_your_home_settlement_costs_and_helpful_information``caivrs_authorization``cancellation_of_listing``check``checklist``child_support_verification``close_line_of_credit_request``closing_disclosure``closing_disclosure_alternate_form``closing_disclosure_borrower_only``closing_disclosure_model_form``closing_disclosure_seller_only``closing_instructions``collection_register``comparative_income_analysis``compliance_agreement``compliance_inspection_report``conditional_commitment``condominium_occupancy_certificate``conservator_and_guardianship_agreement``construction_cost_breakdown``consumer_handbook_on_arm``conversion_option_notice``conveyance_deed``conveyance_deed_bargain_and_sale_deed``conveyance_deed_quit_claim_deed``conveyance_deed_warranty_deed``conveyance_tax_form , cooperative_bylaws``cooperative_operating_budget``cooperative_proprietary_lease``cooperative_recognition_agreement``cooperative_stock_certificate``cooperative_stock_power``cosigner_notice``counseling_certification``counseling_certification_home_retention``counseling_certification_homeownership``counseling_checklist_for_military_homebuyers``credit_card_authorization``credit_insurance_agreement``credit_report``credit_reporting_adjustment``customer_identification_verification` | | `staircase_blob_identifier` | `string` | Blob identifier refers to a unique identifier assigned to a binary large object (BLOB), which is a large binary data structure that can be used to store documents and other types of data. BLOBs are often used in mortgage banking systems to store important loan documents such as loan applications, credit reports, income verification documents, and property appraisals. | | `staircase_document_category_type` | `enumeration` | A Staircase document category type indicates if the source of the document category is Staircase or a Staircase partner. `Staircase``Partner` | ## Referenced by - `employment_income` --- # employment_income # employment_income The link between an employment record, the income it produced, and the document that evidenced it. Employment_income describes properties related to income received from employment. ## Why it matters Three-way rather than two-way, and the third leg is the point. An income figure is attributable to an employment, and it was evidenced by something — a paystub, a tax form, a verification response — and the record of which document supported which figure is what an underwriter needs when a file is questioned. Holding the evidence on the relationship rather than on the income record keeps the same income figure usable when a second document corroborates it. Two documents supporting one figure is two of these, not a document field overwritten. ## In practice Employment writes these as it normalises a vendor response, which is why a returned income figure can always be traced back to the employer and the artifact it came from. ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_document` | `document` | An income document is a document that provides information about an individual's income. These documents are typically required for various financial and legal purposes, such as applying for a loan, filing taxes, or verifying employment. | | `has_employment` | `employment` | As part of employment, a person or organization will receive income. Income is money that a person or organization earns or receives on a regular basis from various sources. Employment refers to the state of being employed, meaning a person has a job or occupation and is receiving compensation for their work. | | `has_income` | `income` | A person has income. Income is money that a person or organization earns or receives on a regular basis from various sources. | --- # employment # employment An employment relationship for a person: employer, position, dates and status. Employment refers to the state of being employed, meaning a person has a job or occupation and is receiving compensation for their work. ## Why it matters Employment and income are separate classes because the questions are separate. An employer confirms a person works there; a payroll record says what they were paid; a guideline asks how long they have done so. The three come from different vendors with different coverage. Dates carry the weight. Continuity of employment across a period is what a guideline tests, so start and end dates are first-class rather than derived from a current-employer flag. ## Properties | Property | Type | Definition | | --- | --- | --- | | `current_employment_indicator` | `boolean` | A current_employment indicator identifies if a person is currentlly employed. Current employment refers to an individual's present or ongoing employment status. It indicates that the individual is currently working for an employer and is receiving compensation for their work. | | `employment_identifier` | `string` | An employment identifier is a unique identifier assigned to an individual by their employer for the purpose of tracking their employment information. It is typically a numerical or alphanumeric code that is used to identify the employee within the employer's human resources management system. | | `employment_job_description` | `string` | An employment job description outlines the duties, responsibilities, qualifications, and requirements of a specific job or role within an organization. | | `employment_monthly_income_amount` | `integer` | Employment monthly income amount refers to the amount of money earned by an individual through employment activities in a month. This income includes the gross salary or wages paid by an employer, as well as any bonuses, commissions, or other forms of compensation received by the employee during that period. | | `has_employer` | `company` | A person who holds a job has an employer. An employer is a person, company, organization, or entity that hires and employs workers to perform specific tasks or jobs in exchange for payment. | | `start_date` | `date` | An employment start date refers to the date on which an individual begins working for an employer in a new job or position. | ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_employee` | `person` | A person, company, organization or entity that hires and employs workers has employees. An employee is an individual who works for an employer in exchange for payment, usually in the form of wages or salary. Employees are hired to perform specific tasks or jobs and are under the supervision and direction of the employer. | ## Referenced by - `employment_income` --- # fee # fee A charge in the transaction: its kind, amount, payer, and the section of the disclosure it belongs to. Fee refers to a charge or cost associated with obtaining and servicing a mortgage loan. ## Why it matters Fees are modelled by their disclosure treatment rather than by who invoices them, because that treatment is what the regulation constrains. Which section a fee falls in determines whether it counts toward a tolerance and whether a change requires a redisclosure. The computation over this class is Fee, including the comparison between successive disclosures, which is a computation over a pair rather than a difference a reader is left to take. ## Properties | Property | Type | Definition | | --- | --- | --- | | `actual_payment_amount` | `decimal` | Fee actual payment amount refers to the monetary amount paid to satisfy a fee. | | `assessed_amount` | `decimal` | Fee assessed amount refers to the monetary amount assessed to satisfy a fee. | | `assessed_date` | `date` | Fee assessed date refers to the date a fee payment was assessed. | | `description` | `decimal` | A company description is a brief summary or overview of a business. It typically includes information such as the company's industry, size, products or services offered, target market, and mission statement. | | `payment_paid_date` | `date` | Fee payment paid date refers to the date a fee payment was made. | | `type` | `enumeration` | Fee type refers to the categorization or classification of a fee based on its nature or purpose. `homeowners_association_dues``homeowners_association_service_fee``homeowners_association_special_assessment` | --- # finance_relation # finance_relation A person's financial position: the assets and debts attached to them, each as its own reference. Finance_relation contains information about financial assets and debts related to a person. ## Why it matters One person, and references to a property, a mortgage, a loan, a lease, a rent, an automobile, an insurance policy and a tax record, plus a stage value, a feedback value and a main-applicant indicator. Every item is a reference rather than an embedded field, which is what keeps the class from becoming a wide record that has to be widened again for the next kind of asset. A new asset type is a new class and one more relationship, not a schema change on every consumer. ## In practice The stage value is what makes the record readable mid-application: a position gathered so far is a valid position, not an incomplete one. ## Properties | Property | Type | Definition | | --- | --- | --- | | `feedback_value` | `enumeration` | Feedback value refers to feedback received from the customer. `Rate Is Too High``Payment Is Too High``Taxes Surprised Me``I Want To Think On It` | | `has_automobile` | `automobile` | An automobile is a road vehicle, typically with four wheels, powered by an internal combustion engine or electric motor and able to carry a small number of people. A person can have an automobile. If the person owns the automobile outright, it is a financial asset. If the person has taken out a loan to purchase the automobile, it is a financial debt because it represents money that they have borrowed from the lender and must repay over time. | | `has_lease` | `lease` | A person can have a lease, which is considered financial debt. A lease is a legally binding agreement between two parties, typically a landlord (lessor) and a tenant (lessee), in which the lessor agrees to rent out a property or asset to the lessee for a specified period of time and under certain conditions. | | `has_main_applicant` | `boolean` | The main applicant on a loan application is the person who is financially responsible for repaying the loan. This person is also known as the borrower or the applicant. | | `has_rent` | `rent` | A person can owe rent, which is considered financial debt. Rent refers to payments made by a tenant to a landlord in exchange for the use and occupancy of a property or space. Rent can be paid for a variety of properties, including apartments, houses, offices, retail spaces, and more. | | `has_stage_value` | `enumeration` | The stage value refers to an applicant's stage in the home buying process. For example, a borrower might be 'just looking' or 'ready to buy.' `Learning``Browsing``Ready to Buy``Already PreApproved``In Contact``Rate Shopping` | ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_insurance` | `insurance` | A person who owns property, an automobile or another financial asset may also have insurance on that asset, which is considered financial debt. Insurance is a policy that provides financial protection for physical assets like homes, or financial assets like mortgages. | | `has_loan` | `loan` | A mortgage application has a loan. A loan in a mortgage application refers to the amount of money that a borrower is requesting from a lender to purchase a property. When a borrower submits a mortgage application, they specify the amount of money they need to borrow to purchase the property. | | `has_mortgage` | `loan` | A mortgage is a loan that is taken out to purchase a property, typically a home. A person can have a mortgage, which is considered financial debt. | | `has_person` | `person` | A member is also a person. | | `has_property` | `property` | Property is a piece of land and any structures or improvements that are permanently attached to it. In the context of property tax, a property can have a tax levied against it. The tax is usually assessed and collected by local governments, such as cities or counties, and is used to fund local services such as schools, police and fire departments, road maintenance, and other community services. | | `has_tax` | `tax` | A person who owns a financial asset may have to pay taxes on the asset. Taxes are fees levied by federal, state, and local governments on income, goods and services, and property, among other things. In the context of finance, tax is considered a financial debt. | --- # income # income Income attributed to a person: amount, frequency, the period it covers, and its kind. Income is money that a person or organization earns or receives on a regular basis from various sources. ## Why it matters Income is separated by kind because qualification treats the kinds differently. Base salary, bonus, overtime, commission, self-employment and rental income are averaged over different periods and discounted at different rates, and a single amount field would make those rules unexpressible. Verified income and qualifying income are also separate ideas — one is what a vendor reported, the other is what a guideline permits counting. See Income for the calculation layer. ## Properties | Property | Type | Definition | | --- | --- | --- | | `annual_income` | `decimal` | Annual income refers to the yearly financial earnings of an individual or organization. | | `bonus_income_amount` | `integer` | Bonus income refers to an additional amount of money that an individual receives on top of their regular salary or wages. This type of income is usually provided as a reward or incentive for achieving specific goals or milestones, such as meeting sales targets or completing a project ahead of schedule. | | `income_amount` | `integer` | Income amount refers to the total amount of money that an individual or entity receives during a specified period. | | `income_description` | `string` | A description of income is a statement or summary that provides details about an individual's or entity's sources of income. It typically includes information about the type of income, such as wages, salaries, commissions, bonuses, dividends, interest, or capital gains. | | `income_identifier` | `string` | An income identifier is a unique identifier for the income record of an individual or organization. | | `income_pay_frequency_type` | `enumeration` | Income pay frequency refers to the frequency at which an individual or entity receives payment for their work or services. `Weekly``Biweekly``Monthly``Yearly` | | `income_type` | `enumeration` | Income type refers to the specific category or source of income earned by an individual or entity, such as earned, investment or rental income. `Base``Bonuses``Commissions``Overtime``Military Base Pay``Military Rations Allowance``Military Flight Pay``Military Hazard Pay``Military Clothes Allowance``Military Quarters Allowance``Military Prop Pay``Military Overseas Pay``Military Combat Pay``Military Variable Housing Allowance``Contract Basis``Other` | | `income_year` | `string` | Income year refers to the year in which an individual or entity received income. | | `other_income_amount` | `integer` | Other income refers to any additional income that an individual receives beyond their regular salary or wages, but that is not categorized as bonus income or overtime income. | | `overtime_income_amount` | `integer` | Overtime income refers to the additional pay that an employee receives for working beyond their regular work hours or scheduled shift. Overtime pay is typically paid at a higher rate than regular pay in recognition of the additional time and effort required. | ## Referenced by - `employment_income` - `person` - `person_income` --- # insurance # insurance Insurance is a policy that provides financial protection for physical assets like homes, or financial assets like mortgages. ## Properties | Property | Type | Definition | | --- | --- | --- | | `base_loan_amount` | `decimal` | The base loan amount is the amount of money that a borrower is approved to borrow from a lender before any additional fees or charges are added to the loan. It is the principal amount of the loan and does not include any interest, closing costs, or other fees. | | `borrower_requested_interest_rate_percent` | `decimal` | A borrower-requested interest rate percent is the interest rate that the borrower has requested for the mortgage. Mortgage interest rate is the percentage of the loan amount that the borrower will pay to the lender as interest over the life of the loan. It is usually expressed as an annual percentage rate (APR) and can vary depending on a number of factors, such as the borrower's credit score, the size of the down payment, and the type of loan. | | `coverage_amount` | `decimal` | The coverage amount refers to the maximum amount of money that an insurance policy will pay out to cover damages or losses to a property. This amount is typically set by the policy holder when they purchase the insurance policy, and it represents the estimated cost to repair or replace the property in the event of damage or loss. | | `coverage_description` | `string` | A coverage description is a detailed explanation of what is covered under the policy and the circumstances under which a claim can be made. The coverage description will typically include information on the types of perils or events that are covered, as well as any exclusions or limitations that apply to the coverage. | | `deductible_amount` | `decimal` | A deductible amount refers to the portion of a claim that the policyholder is responsible for paying out of pocket before the insurance company will start to cover the costs of the claim. Deductibles are typically expressed as a specific dollar amount or as a percentage of the total insured value of the property. | | `deductible_description` | `string` | A deductible description is a detailed explanation of what the policyholder is responsible for paying out of pocket before the insurance company will start to cover the costs of the claim. | | `escrow_indicator` | `boolean` | The escrow_indicator identifies mortgages where the lender sets aside a portion of the monthly mortgage payment to cover the cost of insurance premiums. When a borrower takes out a mortgage loan to purchase a home, the lender may require the borrower to escrow, or set aside, funds to cover the cost of property insurance, such as homeowners insurance or hazard insurance. | | `five_year_cost_comparison_amount` | `decimal` | The five year cost comparison amount is the amount resulting from a calculation that compares the total cost of two different mortgages over a five-year period. It takes into account the interest rate, loan amount, and other costs associated with the mortgage, such as closing costs and fees. To calculate the five year cost comparison, you would take the total cost of each mortgage over a five-year period, including all principal, interest, and fees, and compare them to determine which option is more cost-effective. | | `force_placed_by_servicer_indicator` | `boolean` | A forced_place_by_servicer_indicator identifies mortgages where a mortgage servicer (lender) placed insurance on a property because the borrower (property owner) did not have sufficient insurance coverage in place. In a mortgage agreement, the lender may require the borrower to maintain adequate insurance coverage on the property to protect against damage or loss. If the borrower fails to maintain this insurance coverage, the lender may have the right to force place insurance to protect their interest in the property. | | `housing_cost_over_five_years_amount` | `decimal` | The housing cost over five years amount is the amount resulting from the calculation that adds up all of the costs associated with owning a home over a five-year period. This includes not only the mortgage payment, but also property taxes, insurance premiums, maintenance costs, and any other expenses related to home ownership. To calculate the housing cost over five years, you would first determine the total cost of the mortgage payment over that period of time, including principal and interest. Next, you would add in the cost of property taxes and insurance premiums, which are typically paid on an annual basis but can be divided by five to get an average annual cost. You would also factor in an estimate for maintenance and repair costs, which can vary depending on the age and condition of the home. | | `investor_program_name_type` | `enumeration` | An investor program name type refers to a type of loan that is designed for real estate investors. These programs are often offered by lenders and are designed to meet the specific needs of investors who are looking to purchase, renovate, or refinance investment properties. `calpers``other``payment_power``prime_rate_plus``settle_america` | | `investor_program_name_type_other_description` | `string` | An investor program name type (other) description refers to a description for a non-standard type of loan designed for real estate investors. Since this program type is non-standard, it is typically designated as an 'other' type. | | `loan_identifier_type` | `enumeration` | A loan identifier type is a unique identification code assigned to a mortgage loan by a lender or a loan servicer. The loan identifier is used to track the loan throughout its life cycle, from origination to servicing, and can be used to help identify the loan in various systems and databases. Some loan identifier types being used in the mortgage industry include a lender/servicer-assigned identifier, a universal loan identifier (ULI), Fannie Mae loan number and Freddie Mac loan number. `agency_case``investor_commitment``investor_contract``investor_loan``investor_workout_case``lender_case``lender_loan``loan_price_quote``mers_min``mi_rate_quote``new_servicer_loan``other``pool_issuer_loan``price_response``seller_loan``servicer_loan``servicer_workout_case``subservicer_loan``wholesale_lender_loan``universal_loan` | | `loan_identifier_type_other_description` | `string` | A loan identifier type (other) description refers to a description for a non-standard type of loan identifier. Since the identifier is non-standard, it is typically designated as an 'other' type. | | `policy_cancellation_date` | `date` | An insurance policy cancellation date refers to the date on which an insurance policy is terminated or cancelled by either the insurance company or the policyholder. | | `policy_effective_date` | `date` | An insurance policy effective date is the date on which the insurance coverage begins. It is the date on which the policyholder's coverage is considered to be in force and the insurance company is obligated to pay for any covered losses or damages that occur after that date. | | `policy_expiration_date` | `date` | An insurance policy expiration date is the date on which an insurance policy ends and coverage under the policy ceases. The expiration date is typically specified in the policy documentation and is often one year from the date the policy was originally purchased or renewed. | | `policy_identifier` | `string` | An insurance policy identifier is a unique code or number that is assigned to an insurance policy to identify it within an insurance company's system. This identifier is used to track policy information, premiums paid, claims filed, and other important details related to the policy. | | `policy_renewal_date` | `date` | An insurance policy renewal date is the date on which an insurance policy comes up for renewal. Insurance policies typically have a fixed term, such as one year, and must be renewed at the end of that term to remain in effect. | | `premium_amount` | `decimal` | An insurance policy premium amount refers to the amount of money that an individual or business must pay to an insurance company in exchange for insurance coverage. | | `rate_quote_all_product_indicator` | `boolean` | The rate_quote_all_product_indicator identifies loans where the mortgage lender has provided a quote that includes interest rates and other terms for all of their financial products that may be available to a borrower. A rate quote typically includes information such as the interest rate, any fees or charges associated with the product, the term of the loan and the monthly payment amount. | | `rate_quote_product_comparison_indicator` | `boolean` | The rate_quote_product_comparison_indicator identifies loans where the mortgage lender has provided a rate quote that allows borrowers to compare different mortgage products based on the interest rates and fees associated with each loan option. | | `rate_quote_type` | `enumeration` | A rate quote type is a type of estimate provided by a lender that outlines the potential interest rate and other costs associated with a mortgage loan. It is often given to borrowers who are in the process of shopping for a mortgage and are looking for information on the rates and fees that may apply to a loan. `detail``other``estimated` | | `rate_quote_type_other_description` | `string` | A rate quote type (other) description refers to a description for a non-standard type of rate quote. Since this rate quote type is non-standard, it is typically designated as an 'other' type. | | `required_indicator` | `boolean` | The required_indicator indicates that the lender requires the borrower to carry insurance for the property. | | `second_deductible_amount` | `decimal` | A second deductible amount is the highest amount a property owner will have to pay out of pocket if a specific kind of loss or damage occurs. Typically there is typically only one deductible amount that applies to each covered loss. However, in some cases, a policy may include multiple deductibles for different types of losses or damage. For example, a policy may have a separate deductible for wind damage, hail damage, and flood damage. In this case, the policyholder would be responsible for paying the applicable deductible for each type of damage that occurred. | | `second_deductible_description` | `string` | A second deductible description is a detailed explanation of the conditions under which a second deductible would apply. | | `service_payer_type` | `enumeration` | A servicer payer type refers to the type of entity that is responsible for making payments on a loan or other financial obligation on behalf of another party. In the context of a mortgage, the servicer payer type is typically the borrower, who is responsible for making monthly payments to the loan servicer. `borrower``lender` | | `subordinate_financing_is_new_indicator` | `boolean` | The subordinate_financing_is_new_indicator indicates that new secondary loan is secured by the same collateral as the primary loan. This means that if the borrower defaults on the primary loan, the subordinate lender has a secondary claim on the collateral after the primary lender. | | `the_best_quote_indicator` | `boolean` | The the_best_quote_indicator indicates that a borrower has received a best quote, or most favorable loan offer available, from a lender. When a borrower is shopping for a loan, they may receive multiple loan offers with different interest rates, terms, and fees. The best quote is the one that offers the lowest interest rate, the most favorable terms, and the lowest fees. | | `third_deductible_amount` | `decimal` | A third deductible amount is the highest amount a property owner will have to pay out of pocket if a specific kind of loss or damage occurs. Typically there is typically only one deductible amount that applies to each covered loss. However, in some cases, a policy may include multiple deductibles for different types of losses or damage. For example, a policy may have a separate deductible for wind damage, hail damage, and flood damage. In this case, the policyholder would be responsible for paying the applicable deductible for each type of damage that occurred. | | `third_deductible_description` | `string` | A third deductible description is a detailed explanation of the conditions under which a third deductible would apply. | ## Referenced by - `finance_relation` --- # loan # loan A financing agreement between a lender and a borrower, with its terms, amounts, rates and schedule. A loan is a financial agreement between a lender and a borrower, in which the lender provides the borrower with a certain amount of money or assets, and the borrower agrees to repay the loan over time with interest and/or fees. ## Why it matters The loan is the spine of the transaction. Parties reach it through relationship classes rather than through fields on it, which is what allows a loan to carry several borrowers, several properties and a changing set of participants without the class changing shape. Amounts and percentages are decimal by rule, and every property carrying money or a rate says so in its own name — the suffix law is what makes a property's type legible before its definition is read. ## In practice This class is the origination side. The `loan` in the property model is the recorded side: what a deed index shows filed against a parcel, which reflects what was recorded rather than a current balance. They are different classes in different models for that reason. ## Properties | Property | Type | Definition | | --- | --- | --- | | `amortization_type` | `enumeration` | Loan amortization type refers to the method used to calculate and pay off a loan over time. The two most common types of loan amortization are fully amortizing and partially amortizing. In a fully amortizing loan, the borrower makes regular payments (usually monthly) that include both principal and interest. Each payment reduces the principal balance of the loan, and over time the loan is gradually paid off in full. In a partially amortizing loan, the borrower makes regular payments that include both principal and interest, but the payments are not large enough to fully pay off the loan by the end of its term. As a result, at the end of the loan term, the borrower must either make a balloon payment to pay off the remaining balance, refinance the loan, or enter into another agreement with the lender. `adjustable_rate``fixed``gem``gpm``graduated_payment_arm``other``rate_improvement_mortgage``step` | | `appraisal_value` | `decimal` | Appraisal value indicates the estimated fair market value of a property determined by a professional appraiser. The appraisal process involves a comprehensive evaluation of the property, including its physical characteristics, location, and current market conditions. The appraiser will consider factors such as the size and layout of the property, the condition of the interior and exterior, any upgrades or renovations made to the property, and comparable sales in the area. | | `base_ltv_value` | `decimal` | Base LTV (Loan-to-Value) ratio is the ratio between the total amount of the loan and the appraised value of the asset that is being used as collateral for the loan. The Base LTV is the initial ratio established at the time of the loan origination, which determines the maximum loan amount that can be borrowed based on the value of the collateral. | | `borrower_paid_mi` | `boolean` | Borrower-paid mortgage insurance (BPMI) is a type of insurance that mortgage borrowers can purchase to protect their lender in the event that they default on their mortgage payments. BPMI is typically required for borrowers who make a down payment of less than 20% of the home's purchase price. BPMI is different from other types of mortgage insurance because the borrower is responsible for paying the premiums, rather than the lender. The premiums can be paid upfront as a lump sum, or they can be added to the monthly mortgage payment. | | `buydown_amount` | `decimal` | A mortgage buydown is a financing technique in which the borrower or a third party pays an upfront fee to lower the interest rate on a mortgage loan for a period of time, typically the first few years of the loan term. The amount of the buydown is typically calculated as a percentage of the loan amount. The mortgage buydown amount is the total amount of money that is paid upfront to lower the interest rate on the mortgage loan. | | `buydown_type` | `enumeration` | A mortgage buydown is a type of mortgage financing in which the borrower or a third party pays an additional fee, known as points, to the lender in exchange for a lower interest rate on the mortgage loan. The buydown can be a temporary or permanent reduction of the interest rate on the mortgage loan. There are two main types of buydowns: temporary and permanent. `None``OneOne``OneZero``ThreeTwoOne``TwoOne` | | `day_one_certainty_indicator` | `boolean` | Day 1 Certainty is a program offered by Fannie Mae, a government-sponsored enterprise (GSE), to help lenders streamline the mortgage loan origination process and reduce risk. The program aims to provide lenders with greater confidence in the underwriting process and reduce the need for additional documentation and manual processes. | | `downpayment_amount` | `integer` | Down payment amount refers to the amount of money that a borrower pays upfront to purchase a property, before obtaining a mortgage loan. The specific amount required can vary depending on factors such as the borrower's creditworthiness, the type of loan, and the lender's requirements. In general, a larger down payment can help to reduce the amount of the mortgage loan needed and can lead to lower monthly payments and interest charges over the life of the loan. | | `downpayment_percentage` | `decimal` | Down payment percent is the percentage of the purchase price of a property that a borrower pays upfront as a down payment towards the mortgage loan. The down payment percentage is an important factor in determining the loan-to-value (LTV) ratio, which is the ratio of the loan amount to the appraised value of the property. A higher down payment percentage means a lower loan amount and a lower LTV ratio, which may result in a lower interest rate and better loan terms. | | `dti_value` | `integer` | Debt-To-Income (DTI) ratio is a financial ratio that compares a borrower's total monthly debt payments to their gross monthly income. It is used by lenders to evaluate a borrower's ability to repay a loan, particularly a mortgage loan. To calculate the DTI ratio, the borrower's total monthly debt payments, including things like credit card payments, car payments, student loans, and other loan payments, are divided by their gross monthly income (pre-tax income). The resulting ratio is expressed as a decimal. A DTI ratio of .43 or lower is generally considered a good target for most borrowers. | | `end_date` | `date` | End date refers to the date on which a rental agreement or lease ends and the tenant is no longer obligated to pay rent for the property or space. This date is typically specified in the rental agreement or lease, and it marks the end of the tenant's legal right to occupy the property. | | `interest_only` | `boolean` | Interest-only in a loan is a type of loan where the borrower is required to pay only the interest on the loan during the initial period of the loan, which is typically for a fixed number of years. During the interest-only period, the borrower is not required to pay down the principal amount of the loan, which means that the loan balance remains the same. After the interest-only period ends, the borrower is required to make full payments that include both principal and interest until the loan is fully paid off. This means that the borrower will have to make higher payments compared to the interest-only period, as the principal amount must be paid down over the remaining loan term. | | `loan_amount` | `integer` | Loan amount refers to the total amount of money that a borrower borrows from a lender to purchase a property. This amount is typically based on the purchase price of the property, minus any down payment that the borrower is able to make. | | `loan_identifier` | `string` | A loan identifier, also known as an MLI or loan number, is a unique identification number that is assigned to a specific mortgage loan. It is typically used by lenders and servicers to track and manage mortgage loans throughout the life of the loan. | | `loan_purpose` | `enumeration` | Loan purpose refers to the reason or purpose for which a borrower is obtaining a loan. When applying for a loan, borrowers are typically required to specify the purpose of the loan to the lender. The loan purpose helps the lender assess the borrower's creditworthiness and determine whether the loan is a good fit for the borrower's needs. `mortgage_modification``other``purchase``refinance` | | `loan_role_type` | `enumeration` | Loan role type helps lenders understand a borrower's ability to repay a loan and determine loan terms and conditions. There are three types of loan roles: subject, related and historical. A subject loan is the loan that is being evaluated or underwritten by the lender. A related loan is a loan that is related to the subject loan in some way, such as a second mortgage or a home equity line of credit (HELOC) that is taken out on the same property. A historical loan is a loan that has already been repaid or closed. `historical``subject_loan``related_loan` | | `loan_status` | `enumeration` | Loan status refers to the current state or condition of a loan. It indicates whether the borrower is up-to-date with their payments, in default, or in some other stage of the loan process. `lead``processing``pre_qualify``registered``pre_approval``application_taken``broker_initial_submission``prospect``initial_submission``approved``suspended``pre_deny``broker_condition_submission``condition_submission``clear_to_close``denied``withdrawn``not_accepted``incomplete``rescinded``closed``funded``post_closing``in_shipping``purchased``servicing` | | `loan_status_date` | `date` | Loan status date indicates the date on which the status of a loan was last updated or changed. It is the date when the loan's status was evaluated and recorded by the lender or servicer, and can indicate whether the borrower is up-to-date on their payments, delinquent, or in default. | | `loan_term` | `integer` | Loan term refers to the length of time over which a borrower must repay a loan to the lender. It is typically expressed in months or years and is agreed upon at the time the loan is originated. | | `loan_type` | `enumeration` | Loan type refers to the specific type of loan that a borrower obtains from a lender, such as a personal loan, auto loan, or student loan. The loan type determines the terms and conditions of the loan, including the interest rate, repayment period, and the amount borrowed. `conventional``fha``va` | | `ltv_value` | `decimal` | Loan-To-Value (LTV) ratio is a financial ratio that compares the amount of the loan to the appraised value of the property being purchased or refinanced. To calculate the LTV ratio, the loan amount is divided by the appraised value of the property. The resulting ratio is expressed as a decimal. In general, a lower LTV ratio is considered better, as it indicates that the borrower has a larger equity stake in the property, and may be less likely to default on the loan. | | `monthly_payment` | `decimal` | A mortgage monthly payment is the amount of money that a borrower pays each month to repay the mortgage loan, which includes both the principal and interest on the loan. In addition to the principal and interest, the mortgage monthly payment may also include other expenses such as property taxes, homeowners insurance, and mortgage insurance, depending on the loan type and requirements. These additional expenses are often collected and held in an escrow account by the lender, who then pays them on behalf of the borrower. | | `mortgage_type` | `enumeration` | Mortgage type refers to the specific type of mortgage loan that a borrower obtains to finance the purchase or refinance of a property. There are several different types of mortgage loans, each with its own set of features, eligibility requirements, and interest rates. `conventional``fha``local_agency``other``public_and_indian_housing``state_agency``usda_rural_development``va` | | `mortgage_value` | `decimal` | Mortgage value refers to the amount of money that is borrowed by a borrower to purchase or refinance a property using a mortgage loan. It is the principal amount of the mortgage loan that is used to finance the purchase of the property. The mortgage value is typically determined by the purchase price of the property or its appraised value, whichever is lower. | | `note` | `string` | A note is a legal document that outlines the terms of the loan between the borrower and lender. It is also known as a promissory note. The note contains the borrower's promise to repay the loan, the interest rate, the repayment terms, and other details about the loan, such as the maturity date and any prepayment penalties. | | `note_rate_percentage` | `decimal` | Note rate percent refers to the interest rate specified in the promissory note or loan agreement between a lender and borrower. The note rate is the annual percentage rate (APR) that the borrower will pay on the loan amount. | | `occupancy` | `enumeration` | Occupancy type refers to the way in which a property is used or occupied by its owner or tenant. Occupancy type is used in determining the terms of a mortgage or loan and the level of risk associated with a property. `primary_residence``second_home``investment``other` | | `prepayment_penalty` | `integer` | A prepayment penalty is a fee charged by some lenders if you pay off your loan before the end of its term. Essentially, it's a penalty for paying off your debt early. Lenders use prepayment penalties to discourage borrowers from paying off their loans too quickly, which can reduce the lender's profits by reducing the amount of interest they can collect. The penalty is usually a percentage of the remaining loan balance or a certain number of months' worth of interest payments. | | `program_period_type` | `enumeration` | Loan program period type refers to the period of time associated with the loan program. `period_fixed_10_years``period_fixed_15_years``period_fixed_20_years``period_fixed_30_years``period_arm_5_years``period_arm_7_years``period_arm_10_years` | | `start_date` | `date` | An employment start date refers to the date on which an individual begins working for an employer in a new job or position. | ## Referenced by - `finance_relation` - `mortgage_application` --- # mortgage_application # mortgage_application A formal request for a loan: the loan itself, the plan chosen, and the pricing schema it was quoted under. Mortgage_application describes properties of a mortgage application. ## Why it matters Three references — the loan, the mortgage plan, and the pricing schema. The pricing schema reference is the one that repays explanation. A quote is only meaningful against the rules it was produced under, and those rules change. Holding the schema on the application means a quote can be reproduced later rather than recomputed under whatever rules are current, which is the difference between an audit trail and an estimate. ## In practice Price produces the quote and Approval reads the application when it issues a conditional approval without an underwriter. ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_loan` | `loan` | A mortgage application has a loan. A loan in a mortgage application refers to the amount of money that a borrower is requesting from a lender to purchase a property. When a borrower submits a mortgage application, they specify the amount of money they need to borrow to purchase the property. | | `has_mortgage_plan` | `mortgage_plan` | A mortgage application has a plan. A mortgage plan in a mortgage application typically refers to the proposed repayment plan for the loan. It outlines how the borrower plans to repay the loan over time, including the amount of each payment, the frequency of payments, and the length of the repayment period. | | `has_pricing_schema` | `pricing_schema` | A mortgage application has a pricing schema. A pricing schema, also known as a pricing model, is a method used by lenders to determine the interest rate and fees that will be charged to a borrower for a mortgage loan. Pricing schemas take into account a variety of factors that can impact the risk of lending to a particular borrower, including their credit score, income, employment history, debt-to-income ratio, and the size of the down payment. | --- # mortgage_plan # mortgage_plan The financing structure chosen for a loan: its name, its code and its amortisation term. A mortgage plan is a financial agreement between a borrower and a lender to finance the purchase of a property. ## Why it matters Four fields — an identifier, a name, a code and an amortisation term. A mortgage application points at one. The plan is separated from the loan because the same structure is offered to many borrowers, and pricing is quoted against the structure rather than against the file. Best execution runs an eligible-product search across amortisation terms, which is only expressible if the term belongs to a plan that can be compared with other plans. ## In practice Price selects across plans, and the plan the quote was produced under stays attached to the application afterwards. ## Properties | Property | Type | Definition | | --- | --- | --- | | `amortization_term` | `string` | Mortgage plan amortization term refers to the specific conditions and schedule for paying off a mortgage loan. The amortization term typically refers to the length of time over which the borrower agrees to repay the loan. | | `code` | `string` | Mortgage plans can be identified by various codes or identifiers used by lenders, such as loan numbers or mortgage identification numbers (MINs). Loan numbers are typically assigned by the lender and are used to track the specific mortgage loan within the lender's system. Mortgage identification numbers (MINs) are unique nine-digit numbers assigned by the Mortgage Electronic Registration System (MERS) to identify a mortgage loan throughout its life, even if the loan is sold or transferred to another lender. | | `name` | `string` | A company name is a word or set of words that is used to identify a business entity. It is the primary way in which a company is recognized and distinguished from other entities. | | `plan_identifier` | `string` | A mortgage plan identifier (MPI) is a unique identification number assigned to a mortgage plan or mortgage agreement. It is a way to track and identify individual mortgage plans, and is typically used by lenders, financial institutions, and government agencies. The MPI is usually a combination of numbers and letters, and is assigned by the lender at the time the mortgage plan is established. It serves as a reference for the lender to identify the specific mortgage plan and keep track of it throughout its life cycle. | ## Referenced by - `mortgage_application` --- # payment # payment A payment refers to the transfer of money, goods, or services from one party (the payer) to another party (the payee) in exchange for a product, service, or debt settlement. ## Properties | Property | Type | Definition | | --- | --- | --- | | `days_past_due_count` | `integer` | Payment days past due count is the number of days that a payment has not been received on a specific due date. | | `frequency_type` | `enumeration` | Payment frequency type indicates how frequently the payment is made. `annual``at_maturity``biweekly``monthly``other``quarterly``semiannual``semimonthly``weekly` | | `identifier` | `string` | A payment identifier is a unique code or reference number that is used to identify and track a specific payment transaction. It helps in distinguishing one payment from another, especially in situations where multiple payments are being processed simultaneously. | | `last_paid_amount` | `decimal` | A last paid amount refers to the most recent date on which a payment was made or processed for a particular account or transaction. It signifies the date when the payment was successfully received and recorded by the payee or the entity managing the payment. | | `last_paid_due_date` | `date` | A last payment paid due date refers to the deadline or the final date by which the most recent payment should have been made to fulfill an outstanding financial obligation. | | `last_paid_received_date` | `date` | A last payment paid received date refers to the date on which the most recent payment was received by the payee or the entity managing the payment. | | `late_charge_amount` | `decimal` | A late charge amount, also known as a late fee, is an additional charge imposed on a payer when a payment is not made by the specified due date or within the grace period provided. It is a penalty or fee for late payment. | | `late_charge_grace_period_days_count` | `integer` | Late charge grace period days count refers to a specified number of days during which a payment can be made after the original due date without incurring a late fee or penalty. It is an allowance granted by the creditor or service provider to give the payer some additional time to submit the payment without facing immediate consequences. | | `late_charge_maximum_amount` | `decimal` | A late charge maximum amount refers to the maximum fee or penalty imposed by a creditor or service provider when a payment is not made by the due date or within the specified grace period. It represents the maximum additional amount that the payer is required to pay on top of the original payment due in order to cover the cost of the late payment. | | `late_charge_minimum_amount` | `decimal` | A late charge minimum amount refers to the minimum fee or penalty imposed by a creditor or service provider when a payment is not made by the due date or within the specified grace period. It represents the minimum additional amount that the payer is required to pay on top of the original payment due in order to cover the cost of the late payment. | | `next_fourth_payment_amount` | `decimal` | Next fourth payment amount refers to the specific value or sum of money that must be transferred or exchanged after the next third payment amount, as part of a payment transaction. | | `next_payment_amount` | `decimal` | Next payment amount refers to the specific value or sum of money that must next be transferred or exchanged as part of a payment transaction. It represents the monetary value or quantity that the payer will provide next to the payee. | | `next_payment_due_date` | `date` | A next payment due date refers to the next date by which the next payment must be made to fulfill an outstanding financial obligation. | | `next_second_payment_amount` | `decimal` | Next second payment amount refers to the specific value or sum of money that must be transferred or exchanged after the next payment amount, as part of a payment transaction. | | `next_third_payment_amount` | `decimal` | Next third payment amount refers to the specific value or sum of money that must be transferred or exchanged after the next second payment amount, as part of a payment transaction. | | `payment_amount` | `decimal` | A payment amount is the specific value or sum of money that is being transferred or exchanged as part of a payment transaction. It represents the monetary value or quantity that the payer is providing to the payee. | ## Referenced by - `tax` --- # person_credit # person_credit The link between a person and a credit record, held as a class of its own. Person_credit describes properties related to a person's credit. ## Why it matters The model is flat: no class nests another, and a relationship between two classes is itself a class whose properties join them. This is one of those — it holds a person and a credit record, and nothing else. A foreign key on the credit record would have been shorter to write and would have cost the two things this shape buys. A person can carry more than one credit record without either side changing, and the relationship can acquire its own attributes later without a migration on either class it joins. ## In practice A joint application produces several of these against one credit pull, which is the case that makes the separate class earn itself. Credit writes them as it normalises a bureau response. ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_credit` | `credit` | A person can have credit. Credit is a person's ability to borrow money or obtain goods or services with the understanding that they will pay for them later. Credit is typically measured by a credit score, which is a numerical rating that reflects a person's creditworthiness based on their credit history, income, debt-to-income ratio, and other factors. | | `has_person` | `person` | A member is also a person. | --- # person_income # person_income The link between a person and one income record. Person_income describes properties related to a person's income. ## Why it matters A person has income of several kinds at once — base salary, bonus, commission, self-employment, rental — and each is a separate income record because qualification treats the kinds differently. This class is the join between the person and one of them. Making the relationship its own class is what allows the several-to-several case without a compound key: two applicants can be attributed a share of the same rental income, and one applicant can hold six income records, using the same shape in both directions. ## In practice Income writes one of these per record it returns, and the qualification layer under Income reads them to decide which figures may be counted. ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_income` | `income` | A person has income. Income is money that a person or organization earns or receives on a regular basis from various sources. | | `has_person` | `person` | A member is also a person. | --- # person # person An individual, and the class the largest number of others point at. A person is an individual member of the human race. ## Why it matters Everything in a transaction attaches to a person: the borrower and coborrower, the loan officer, the seller, the notary, the agent. The class carries only what is true of the individual — name, demographics, identification, citizenship — and everything role-shaped hangs off it as a relationship instead. That split is why the class is small relative to how much points at it. A person is not a borrower; a person has a finance relation whose role is borrower, and the same person can hold several such relations at once. ## In practice Identity across states is a stable global identifier named for the class, while every state of the record carries its own database-generated identifier. A correction to a name is a new record grouped with the old one rather than an overwrite, so the history of what was believed and when is a query rather than an audit log. ## Properties | Property | Type | Definition | | --- | --- | --- | | `birth_date` | `date` | A birth date is the date on which a person was born. It typically includes the day, month, and year of an individual's birth and is used to determine their age. | | `city_name` | `string` | City name refers to the name of the city in which the address is located. | | `country_name` | `string` | Country name refers to the country where a person resides. | | `email_address` | `string` | An email address is a unique identifier used to send and receive electronic messages over the internet. It typically consists of two parts: a username and a domain name, separated by the '@' symbol. | | `first_name` | `string` | A person's first name is the name that they are given at birth or during infancy, and it is typically used to identify them in a personal or informal context. | | `first_time_home_owner` | `boolean` | First time home owner refers a person who is purchasing a house and taking out a mortgage for the first time. | | `full_address_txt` | `string` | Full address text refers to the physical location where property is located. | | `has_saved_search` | `saved_search` | Links a person to a saved search instance, indicating that the person has saved this particular search. | | `home_phone_number` | `string` | A home phone number is a telephone number that is associated with a residential address, typically used for personal or family communication purposes. It is a phone number that is linked to a landline or a Voice over Internet Protocol (VoIP) service that is connected to a physical address. | | `last_name` | `string` | A person's last name, also known as surname or family name, is typically the name that is shared by all members of their immediate family. | | `mailing_address` | `string` | A mailing address is the physical location where mail is sent to a person or organization. It typically includes the recipient's name, street address, city, state or province, postal code and country. | | `owned_environments` | `environment` | Owned environment refers to a computing environment that is fully controlled by a particular person or organization. In an owned environment, the person or organization has complete control over the configuration, management, and security of the computing resources. This allows them to customize the environment to their specific needs and requirements, and to ensure that it is optimized for the application or service they are running. | | `person_identifier` | `string` | A person identifier is a unique code or number assigned to an individual for identification purposes. It is often used in various administrative and legal systems to ensure accuracy and consistency in record-keeping and data management. | | `phone_number` | `string` | A phone number is a unique sequence of digits assigned to a specific telephone line or mobile device that allows it to be reached by a caller. It is typically comprised of a country code, area code, and a specific number assigned to the device. | | `postal_code` | `string` | A postal code, also known as a ZIP code (in the United States) or postcode (in many other countries), is a numerical code used by postal services to identify specific geographic areas for efficient mail sorting and delivery. | | `ssn` | `string` | A Social Security number (SSN) is a unique nine-digit identification number assigned to individuals in the United States by the Social Security Administration (SSA). The SSN is used primarily for tracking individuals for Social Security and tax purposes, but it is also used for a variety of other purposes, such as credit reporting, employment verification, and financial transactions. | | `state_code` | `string` | State code is a code that represents the state in which the address is located. | | `state_name` | `string` | State name refers to the name of the state in which the address is located. | | `us_citizenship_status` | `enumeration` | Citizenship status refers to an individual's legal status as a citizen or non-citizen of a country. In the United States, citizenship status is determined by birthright, naturalization, or other legal means. `USCitizen``USCitizenAbroad``PermResidentAlien``NonPermResidentAlien``ForeignNational` | | `veteran_status` | `boolean` | Veteran status refers to an individual's status as a former member of the armed forces. In the United States, a person is considered a veteran if they have served in the active military, naval, or air service and were discharged or released from that service under conditions other than dishonorable. | | `work_phone_number` | `string` | A work phone number is a telephone number that is associated with an individual's place of employment. It is typically used for business purposes, such as to contact colleagues, clients, or customers. | ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `earns` | `income` | A person has income. Income is information about the money that a person or organization earns or receives on a regular basis from various sources. For a person, income typically comes from wages or salaries earned from employment, as well as from investments, rental properties, or other sources of passive income. Income for organizations can come from sales of products or services, investments, grants, donations, or other sources. | | `has_credit` | `credit` | A person can have credit. Credit is a person's ability to borrow money or obtain goods or services with the understanding that they will pay for them later. Credit is typically measured by a credit score, which is a numerical rating that reflects a person's creditworthiness based on their credit history, income, debt-to-income ratio, and other factors. | ## Referenced by - `employment` - `finance_relation` - `person_credit` - `person_income` --- # pricing_schema # pricing_schema Pricing schema refers to the method used by lenders to determine the interest rate and other fees associated with a mortgage loan. ## Properties | Property | Type | Definition | | --- | --- | --- | | `apr` | `decimal` | Annual Percentage Rate (APR) represents the total cost of borrowing money over the life of the loan and is expressed as a percentage. The APR includes not only the interest rate, but also any points, origination fees, closing costs, and other charges associated with the loan. In general, the APR will be higher than the interest rate, since it includes the additional fees and charges associated with the loan. | | `closing_cost` | `decimal` | Pricing schema closing costs define how much money a borrower will need to close on a mortgage. Closing costs refer to the fees and expenses that a borrower must pay at the closing of a mortgage loan. | | `discount` | `decimal` | A pricing schema discount is a reduction in the interest rate offered on a mortgage loan, typically in exchange for paying an upfront fee known as a discount point. Discount points are a form of prepaid interest that a borrower can pay at closing to reduce the interest rate on the mortgage loan. One discount point typically equals 1% of the loan amount and can reduce the interest rate by 0.125% to 0.25%, although the exact reduction may vary depending on the lender and loan program. | | `first_year_monthly_payment` | `decimal` | First year monthly payment refers to the amount of money that a borrower must pay each month during the first year of their mortgage loan. The first-year monthly payment will depend on several factors, including the loan amount, interest rate, term, and any upfront costs, such as closing costs or prepaid expenses for property taxes and insurance. In some cases, lenders may offer a lower introductory interest rate or other incentives during the first year of the loan, which can result in a lower first-year monthly payment. | | `monthly_insurance` | `decimal` | Monthly insurance refers to the cost of mortgage insurance, which is an insurance policy that protects the lender in case the borrower defaults on the loan. Mortgage insurance is typically required when the borrower has a down payment of less than 20% of the home's purchase price. The monthly mortgage insurance premium is typically added to the borrower's monthly mortgage payment. | | `piti` | `decimal` | PITI stands for Principal, Interest, Taxes, and Insurance. PITI is a commonly used pricing schema in the mortgage industry to calculate the total monthly payment that a borrower will need to make on a mortgage loan. | | `price` | `decimal` | Price refers to the total cost of borrowing money for a mortgage loan. The price includes not only the interest rate charged on the loan but also any fees and charges associated with the loan, such as points, origination fees, and closing costs. | | `pricing_schema_identifier` | `string` | A pricing schema identifier is a unique identification number assigned to a mortgage pricing schema. | | `principal_and_interest` | `decimal` | A mortgage pricing schema that separates the mortgage payment into principal and interest is a way of structuring the payment so that a portion of the payment goes toward paying off the principal balance of the loan, and another portion goes toward paying the interest charged on the outstanding balance. In this schema, the principal is the original amount borrowed, and the interest is the fee charged by the lender for the use of the borrowed money. The mortgage payment is typically structured to pay off both the principal and interest over the life of the loan, with a greater proportion of the payment going towards interest at the beginning of the loan term and a greater proportion going towards principal as the loan matures. | | `rate` | `decimal` | Rate refers to the interest rate at which the borrower will be charged interest on the outstanding balance of the loan. The interest rate does not take into account any fees or charges associated with the loan. In general, the interest rate will be lower than the annual percentage rate (APR) will be higher than the interest rate, since it does not include the additional fees and charges associated with the loan. | | `rebate` | `decimal` | Rebate refers to a discount or credit that a lender offers to a borrower as an incentive to select a particular mortgage pricing option. It allows lenders to offer borrowers lower interest rates or fees in exchange for selecting a particular mortgage pricing structure. | | `second_year_monthly_payment` | `decimal` | Second year monthly payment refers to the amount of money that a borrower must pay each month starting from the second year of the mortgage loan term. For fixed-rate mortgages, the monthly payment for a mortgage loan will remain the same throughout the entire term of the loan. However, some adjustable-rate mortgages (ARMs) have an initial fixed-rate period, after which the interest rate and monthly payment can change based on market conditions. Therefore, if a mortgage loan has an adjustable interest rate with an initial fixed-rate period of one year, the second-year monthly payment will depend on the current market interest rate at the end of the initial fixed period. The monthly payment may increase or decrease based on the interest rate at that time, which can result in a higher or lower payment amount for the borrower. | | `third_year_monthly_payment` | `decimal` | Third year monthly payment refers to the amount a money that a borrower must pay each month to repay a mortgage loan during the third year of the loan term. The third year monthly payment can be calculated based on the loan amount, interest rate, and amortization term of the mortgage loan. However, the interest rate and other terms of the loan may change over time, particularly if the loan has an adjustable-rate mortgage (ARM) feature. In this case, the third year monthly payment would depend on the interest rate at that time, which may be higher or lower than the initial rate. | | `total_monthly_payment` | `decimal` | Total monthly payment refers to the amount of money a borrower must pay each month to repay a mortgage loan, including principal and interest, as well as any escrow payments for property taxes and homeowners insurance. | ## Referenced by - `mortgage_application` --- # property_tax # property_tax The link between a property and a tax record. Property tax describes properties related to taxes levied on the value of real estate or other types of property, such as land, buildings, and homes. ## Why it matters Two references and nothing else. A property has tax assessed against it, the tax record carries the amounts and the periods, and this class joins them. Keeping the tax record separate from the property is what allows a history. A parcel has a new assessment every year and several tax records at once for different authorities, and either case would break a set of tax fields on the property itself. ## In practice Tax writes these against the parcel record, and the escrow calculation on a loan reads them. ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_property` | `property` | Property is a piece of land and any structures or improvements that are permanently attached to it. In the context of property tax, a property can have a tax levied against it. The tax is usually assessed and collected by local governments, such as cities or counties, and is used to fund local services such as schools, police and fire departments, road maintenance, and other community services. | | `has_tax` | `tax` | A person who owns a financial asset may have to pay taxes on the asset. Taxes are fees levied by federal, state, and local governments on income, goods and services, and property, among other things. In the context of finance, tax is considered a financial debt. | --- # property # property A parcel of land and what stands on it, as the mortgage model records it. Property is a piece of land and any structures or improvements that are permanently attached to it. ## Why it matters An identifier, a type, a purchase price, a lien type, the address as flat fields, and a reference to the tax levied against it. This is the loan file's view of a property, and it is deliberately thinner than the collateral model. The question it answers is which property secures this loan and on what terms — not what the property is made of. ## In practice The structural description lives in the property model under Data, which carries the parcel, the structure, the lot and the rest at assessor-record depth. The two are joined by address and parcel identity rather than merged, because one is a term of a loan and the other is a description of a place. ## Properties | Property | Type | Definition | | --- | --- | --- | | `city_name` | `string` | City name refers to the name of the city in which the address is located. | | `county_name` | `string` | A property county name refers to the name of the county in which a property is located. In the United States, counties are geographic and political subdivisions of states, typically governed by a county government. Each county is identified by a unique name and is responsible for providing certain public services to residents, such as law enforcement, public schools, and infrastructure maintenance. | | `full_address_txt` | `string` | Full address text refers to the physical location where property is located. | | `lien_type` | `enumeration` | A property lien is a legal claim against a property that gives a creditor the right to take possession of the property if the borrower fails to repay a debt. There are several lien types, such as mortgage, tax and judgment.Typically a lien gives its holder the right to seize property or money from the borrower if the borrower does not fulfill the terms of a contract. `Mortgage``Tax``Mechanics``Judgement``Other` | | `postal_code` | `string` | A postal code, also known as a ZIP code (in the United States) or postcode (in many other countries), is a numerical code used by postal services to identify specific geographic areas for efficient mail sorting and delivery. | | `property_identifier` | `string` | A property identifier is a unique code or number assigned to a specific real estate property by a government agency or other organization. Property identifiers are used to identify and track individual properties for various purposes, such as taxation, land use planning, and real estate transactions. | | `property_type` | `enumeration` | Property type refers to the classification of a real estate property based on its characteristics, usage, and zoning designation. Property types can include residential, commercial, industrial, agricultural, and mixed-use properties. `2_units``3_units``4_units``single_family``condo``duplex``manufactured_home``manufactured_double_wide``modular``pud``timeshare``manufactured_single_wide``coop``non_warrantable_condo``townhouse``detached_condo` | | `purchase_price_amount` | `decimal` | The purchase price is the amount of money that is paid to purchase a real estate property. This price includes the cost of the land and any buildings or other improvements on the property. The purchase price may also include other costs, such as closing costs, title insurance, and other fees associated with the transaction. | | `state_code` | `string` | State code is a code that represents the state in which the address is located. | | `state_name` | `string` | State name refers to the name of the state in which the address is located. | | `street_name` | `string` | A street name is the name of a street on which an address is located. | | `unit` | `enumeration` | A property unit is a self-contained and separately identifiable portion of a larger property or building that is designed to be used or occupied by a tenant or owner. Properties are typically single-unit and contain only a single homes or storefront, or multi-unit and contain multiple homes or storefronts. `1``2``3``4` | ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_tax` | `tax` | A person who owns a financial asset may have to pay taxes on the asset. Taxes are fees levied by federal, state, and local governments on income, goods and services, and property, among other things. In the context of finance, tax is considered a financial debt. | ## Referenced by - `finance_relation` - `property_tax` --- # tax # tax A tax levied by an authority, for a period, with the payment against it and whether it is escrowed. Taxes are fees levied by federal, state, and local governments on income, goods and services, and property, among other things. ## Why it matters A tax record names the authority, the account held with it, the period it covers, the service provider that sourced it, and the payment made against it, plus an indicator for whether it is escrowed. The period is what makes the record a history rather than a balance. A parcel carries a new assessment each cycle and can owe several authorities at once, so the class is deliberately one levy for one period rather than a current-tax field on the property. ## In practice The escrow indicator is the field a servicing calculation reads first: an escrowed tax is collected monthly and paid by the servicer, and an unescrowed one is the borrower's to pay directly. ## Properties | Property | Type | Definition | | --- | --- | --- | | `authority_account_identifier` | `string` | Authority account identifier is a tax identifier issued to individuals and organizations to track tax obligations and payments they make to a tax authority. | | `authority_name` | `string` | Authority name refers to the name of an organization authorized to collect taxes from individuals and other organizations. | | `description` | `decimal` | A company description is a brief summary or overview of a business. It typically includes information such as the company's industry, size, products or services offered, target market, and mission statement. | | `escrowed_indicator` | `boolean` | The escrowed indicator specifies whether a mortgage servicer takes a portion of the borrower's monthly mortgage payment and holds it in an escrow account until tax payments are due. | | `period_end_date` | `date` | Period end date is the last day in a time period during which tax liability is accruing. | | `period_start_date` | `date` | Period start date is the first day in a time period during which tax liability is accruing. | | `service_provider_identifier` | `string` | A service provider identifier is a unique identifier issued to a company or individual who offers professional tax-related services to individuals, businesses, and other organizations. | | `service_provider_name` | `string` | Service provider name is the name of a company or individual who offers professional tax-related services to individuals, businesses, and other organizations. | ## Relationships | Property | Points at | Definition | | --- | --- | --- | | `has_payment` | `payment` | A payment refers to the transfer of money, goods, or services from one party (the payer) to another party (the payee) in exchange for a product, service, or debt settlement. Payments can take various forms, including cash, checks, bank transfers, credit cards, electronic funds transfers, mobile payments, and digital currencies. | ## Referenced by - `finance_relation` - `property` - `property_tax` --- # Property model # Property model The property class dictionary: the physical asset, the parcel it sits on, and the public record behind both. One parcel, decomposed into the classes a valuation needs: the structure, its layout and utilities, the lot, the deed and sales history, the tax position, and the surrounding jurisdiction records. The published classes are the subgraph the declared data groups reach. The full graph carries more, and a class no data group reaches has no way to be requested. ## How it is governed Group membership is derived from the relationships the data groups declare rather than from a hand-maintained list, so a class enters or leaves the published set when the groups change and not when someone remembers. Enumerations are the failure surface, and the rule is that an unmapped source value is an error rather than a default. An extraction script that meets a value it cannot map throws, naming the class and property; it does not assign a plausible substitute. That is the single rule that keeps a wrong value out of the dataset at jurisdiction scale. ## How it works The decomposition is partitioned so a source can update part of a record without rewriting it. A permit filing changes the improvement history and nothing else; a deed recording changes ownership and sales history and nothing else. Grouping by what changes together is what makes partial update safe. Every value can name where it came from. A source class carries the contributor and the specific attribute it supplied, alongside the vendor's own identifier and the time of the call, so the graph answers which source produced a given fact rather than only what the fact is. Records are accepted on agreement rather than on arrival. Independent re-derivation of the same parcel must agree before a value is taken, and change is detected by content hash against the source rather than by re-reading on a schedule. ## Classes Grouped by the question each answers about a property. ### What is this house, physically? - `property` - `parcel` - `structure` - `lot` - `layout` - `appliance` - `utility` - `geometry` - `property_ranking_overall` - `environment_characteristics` - `flood_storm_information` - `safety_security` - `school` - `transportation_access` ### What changed since it was built? - `property_improvement` - `inspection` - `file` ### What are the comparables, really? - `sales_history` - `deed` ### Who owns it, and what does that imply? - `person` - `address` - `unnormalized_address` - `property_seed` ### Will this close cleanly? - `loan` - `tax` - `tax_authority` - `tax_exemption` - `tax_jurisdiction` - `homeowners_association` - `hoa_policy` ## The classes carrying the most | Class | Properties | Referenced by | | --- | --- | --- | | `structure` | 59 | 0 | | `layout` | 49 | 0 | | `utility` | 46 | 0 | | `tax` | 26 | 0 | | `address` | 24 | 0 | | `lot` | 21 | 0 | | `environment_characteristics` | 21 | 0 | | `property` | 19 | 0 | Derived from: property graph, restricted to the classes its data groups reach (repository source) --- # address # address A physical or mailing address, parsed into components with postal and geographic identifiers. Represents a physical or mailing address with comprehensive location details including street information, postal codes and geographic identifiers. The question it answers ## Who owns it, and what does that imply? A deed names its parties as strings. Resolving those strings to a person and a mailing address is what separates an owner-occupant from an investor, and what links one owner to the rest of a portfolio. Other classes answering this question ## Why it matters The parsed address is the join key of last resort. Where a parcel identifier cannot be matched across two sources, a normalised address is what connects them, so the parsing has to be consistent rather than merely correct. ## In practice The class holds components rather than a line of text: street number, name, suffix, directionals, unit, locality, state and postal code, each addressable. Directional prefixes and suffixes are separate fields because a county that writes them differently is otherwise an unmatched record. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `city_name` | `string | null` | City name refers to the name of the city in which the address is located. Must be in all capital letters. | | `country_code` | `string | null` | Country code is a code that represents the country in which the address is located. | | `county_name` | `string` | County name refers to the name of the county in which the address is located. `Dallas``Miami Dade``Broward``Palm Beach``Lee``Hillsborough``Orange``Pinellas``Polk``Duval``Brevard``Pasco``Volusia``Sarasota``Collier``Marion``Manatee``Charlotte``Lake``Osceola``St. Lucie``Seminole``Escambia``St. Johns``Citrus``Bay``Santa Rosa``Hernando``Okaloosa``Highlands``Leon``Alachua``Clay``Sumter``Putnam``Martin``Indian River``Walton``Monroe``Flagler``Nassau``Levy``Washington``Jackson``Suwannee``Columbia``Hendry``Okeechobee``Gadsden``Wakulla``DeSoto``Gulf``Taylor``Franklin``Dixie``Madison``Bradford``Hardee``Gilchrist``Holmes``Calhoun``Hamilton``Baker``Jefferson``Glades``Lafayette``Union``Liberty``Fort Bend``Collin``Allegheny``Hunt``Wood``Burnet``San Patricio``Wise``Nacogdoches``Waller``Cherokee``Navarro``Medina``Alameda``Alpine``Amador``Butte``Calaveras``Colusa``Contra Costa``Del Norte``El Dorado``Fresno``Glenn``Humboldt``Imperial``Inyo``Kern``Kings``Lake``Lassen``Los Angeles``Madera``Marin``Mariposa``Mendocino``Merced``Modoc``Mono``Monterey``Napa``Nevada``Orange``Placer``Plumas``Riverside``Sacramento``San Benito``San Bernardino``San Diego``San Francisco``San Joaquin``San Luis Obispo``San Mateo``Santa Barbara``Santa Clara``Santa Cruz``Shasta``Sierra``Siskiyou``Solano``Sonoma``Stanislaus``Sutter``Tehama``Trinity``Tulare``Tuolumne``Ventura``Yolo``Yuba``Ellis` | | `latitude` | `number | null` | Latitude is a coordinate that specifies the north-south position of a point on the Earth's surface. It is an angular measurement, usually expressed in degrees, with values ranging from -90° at the South Pole to +90° at the North Pole. | | `longitude` | `number | null` | Longitude is a coordinate that specifies the east-west position of a point on the Earth's surface. It is an angular measurement, usually expressed in degrees, with values ranging from -180° to +180°. | | `municipality_name` | `string | null` | he incorporated city, town, or village in which the property is located, responsible for providing local government services and regulations. | | `plus_four_postal_code` | `string | null` | A postal code plus four, also known as a ZIP code plus four (in the United States) is a numerical extension to a postal code. | | `postal_code` | `string | null` | A postal code, also known as a ZIP code (in the United States) or postcode (in many other countries), is a numerical code used by postal services to identify specific geographic areas for efficient mail sorting and delivery. | | `state_code` | `string | null` | State code is a code that represents the state in which the address is located. | | `street_name` | `string | null` | A street name that doesn't contain directional abbreviations | | `street_post_directional_text` | `string | null` | Street post directional text refers to the directional indicator or suffix added to a street name to provide additional information about the direction or orientation of the street segment. It helps to clarify the position of a particular street in relation to other streets or landmarks in a given area. `N``S``E``W``NE``NW``SE``SW` | | `street_pre_directional_text` | `string | null` | Street pre directional text refers to the directional indicator or prefix added to a street name to provide additional information about the direction or orientation of the street segment. It helps to clarify the position of a particular street in relation to other streets or landmarks in a given area. `N``S``E``W``NE``NW``SE``SW` | | `street_number` | `string | null` | Street number refers to the numerical part of a street address that indicates the specific location or position of a building or property along a street. | | `street_suffix_type` | `string | null` | `Rds``Blvd``Lk``Pike``Ky``Vw``Curv``Psge``Ldg``Mt``Un``Mdw``Via``Cor``Kys``Vl``Pr``Cv``Isle``Lgt``Hbr``Btm``Hl``Mews``Hls``Pnes``Lgts``Strm``Hwy``Trwy``Skwy``Is``Est``Vws``Ave``Exts``Cvs``Row``Rte``Fall``Gtwy``Wls``Clb``Frk``Cpe``Fwy``Knls``Rdg``Jct``Rst``Spgs``Cir``Crst``Expy``Smt``Trfy``Cors``Land``Uns``Jcts``Ways``Trl``Way``Trlr``Aly``Spg``Pkwy``Cmn``Dr``Grns``Oval``Cirs``Pt``Shls``Vly``Hts``Clf``Flt``Mall``Frds``Cyn``Lndg``Mdws``Rd``Xrds``Ter``Prt``Radl``Grvs``Rdgs``Inlt``Trak``Byu``Vlgs``Ctr``Ml``Cts``Arc``Bnd``Riv``Flds``Mtwy``Msn``Shrs``Rue``Crse``Cres``Anx``Drs``Sts``Holw``Vlg``Prts``Sta``Fld``Xrd``Wall``Tpke``Ft``Bg``Knl``Plz``St``Cswy``Bgs``Rnch``Frks``Ln``Mtn``Ctrs``Orch``Iss``Brks``Br``Fls``Trce``Park``Gdns``Rpds``Shl``Lf``Rpd``Lcks``Gln``Pl``Path``Vis``Lks``Run``Frg``Brg``Sqs``Xing``Pln``Glns``Blfs``Plns``Dl``Clfs``Ext``Pass``Gdn``Brk``Grn``Mnr``Cp``Pne``Spur``Opas``Upas``Tunl``Sq``Lck``Ests``Shr``Dm``Mls``Wl``Mnrs``Stra``Frgs``Frst``Flts``Ct``Mtns``Frd``Nck``Ramp``Vlys``Pts``Bch``Loop``Byp``Cmns``Fry``Walk``Hbrs``Dv``Hvn``Blf``Grv``Crk` | | `unit_identifier` | `string | null` | A unit identifier is a reference to the specific unit, suite, apartment, or other secondary identifier associated with an address. It is used to differentiate individual units within a larger building or complex. | | `route_number` | `string | null` | A route number is a unique identifier assigned to a specific transportation route, such as a road, highway, or public transit line. It is used to distinguish one route from another and is often displayed on signs or maps. | | `township` | `string | null` | A township is a 6-mile by 6-mile square of land, covering 36 square miles. Townships are numbered north or south from a designated baseline. In this case, Township 45 refers to the 45th tier of townships from the baseline. | | `range` | `string | null` | A range describes the east-west position of a township relative to a principal meridian. Range 24E means the township is located 24 tiers east of the principal meridian | | `section` | `string | null` | Each township is divided into 36 sections, with each section being 1 square mile (640 acres). Section 03 refers to the third section within its township | | `block` | `string | null` | A block is a further subdivision within a plat (a recorded land division), often used in urban or planned developments. Block 0000G refers to a specific block within that recorded subdivision | | `lot` | `string | null` | A specific parcel or unit of land within a subdivision or plat, identified by a unique lot number or code assigned during the subdivision platting process. | | `unnormalized_address` | `string | null` | The original, unprocessed address as it appears in source data, preserving the raw format and any inconsistencies. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # appliance # appliance Appliances present at the property, as recorded in the source. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Appliances are a minor line in a valuation and a real one in a condition assessment: a property recorded with no appliances is either a shell or a record gap, and the two need different handling. Two fields carry the content — the appliance type and its visible finish — and both are closed enumerations rather than free text, so an inventory aggregates across properties without a normalisation pass. The finish is what separates a recent kitchen from an original one where no permit exists to date it. The source dictionary carries no definition for this class. ## In practice Rows come from photograph metadata rather than from an assessor file, which is why an empty set means unobserved rather than absent. A property with no interior photographs on record carries no appliance rows at all. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `appliance_type` | `string | null` | The appliance type observed in the space. `Refrigerator``Freezer``Microwave``Oven``Stove``Dishwasher``Washing Machine``Dryer``Range Hood``Wine Cooler``Trash Compactor``Water Heater``Cooktop``Double Oven``Built-In Coffee Maker``Wall Oven``Mini Fridge``Ice Maker``Garbage Disposal``Smart Display``Toaster Oven` | | `finish` | `string | null` | The visible finish of the appliance. `Stainless Steel``Black``White``Glass``Matte Black``Matte White``Custom Panel``Chrome``Copper``Brushed Nickel` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # deed # deed A recorded instrument transferring ownership: its type, its recording data, the parties, and the consideration stated on it. Represents a legal deed document that transfers ownership of real property from one party to another. The question it answers ## What are the comparables, really? A recorded deed is the legal source of truth for a transfer: instrument type, consideration, parties, and date. That is what separates an arm's-length sale from a quitclaim between relatives, an estate transfer, a foreclosure, or an investor flip. A comp set that silently includes non-arm's-length transfers is biased before the model sees it. Other classes answering this question ## Why it matters The instrument type is the field that does the work, and it is the one an aggregated feed most often loses. Warranty deed, quitclaim, trustee's deed, personal representative's deed and certificate of title are different legal events with different implications for what the stated consideration means. Consideration on a quitclaim is frequently nominal and is not a price. ## In practice Recording data — the instrument number, book and page, and the clerk's file reference — is carried because it is how the document itself is retrieved. A transfer without its recording reference cannot be checked against the source, and this class is the one most worth being able to check. A single deed can convey several parcels, which is why the transfer record is `sales_history` and this class is the document. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `deed_type` | `string` | The type of deed document used to transfer property ownership. `Warranty Deed``Special Warranty Deed``Quitclaim Deed``Grant Deed``Bargain and Sale Deed``Lady Bird Deed``Transfer on Death Deed``Sheriff's Deed``Tax Deed``Trustee's Deed``Personal Representative Deed``Correction Deed``Deed in Lieu of Foreclosure``Life Estate Deed``Joint Tenancy Deed``Tenancy in Common Deed``Community Property Deed``Gift Deed``Interspousal Transfer Deed``Wild Deed``Special Master’s Deed``Court Order Deed``Contract for Deed``Quiet Title Deed``Administrator's Deed``Guardian's Deed``Receiver's Deed``Right of Way Deed``Vacation of Plat Deed``Assignment of Contract``Release of Contract``Miscellaneous` | | `book` | `string` | The book number where the deed is recorded in public records. | | `page` | `string` | The page number within the book where the deed is recorded. | | `volume` | `string` | The volume number associated with the deed recording. | | `instrument_number` | `string` | The unique instrument number assigned to the deed document upon recording. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # environment_characteristics # environment_characteristics Environmental factors and natural-disaster exposure around the property. Environmental factors, natural disaster risks, and surroundings that affect property desirability and safety. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Environmental exposure is priced by insurers before it is priced by buyers, so it reaches a valuation through carrying cost as much as through desirability. ## In practice The class covers surroundings as well as hazards, which is deliberate: proximity to industrial use, noise and air quality are recorded facts about a location in some jurisdictions and are otherwise only visible from a site visit. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `fire_zone` | `string | null` | Wildfire risk zone or fire district designation indicating wildfire hazard level and emergency response district. | | `wildfire_risk_level` | `string | null` | Standardized wildfire risk assessment based on vegetation, weather patterns, topography, and fire history. `VeryLow``Low``Moderate``High``VeryHigh``Extreme` | | `air_quality_index` | `string | null` | EPA Air Quality Index category indicating typical air pollution levels for the area. `Good``Moderate``UnhealthyForSensitiveGroups``Unhealthy``VeryUnhealthy``Hazardous` | | `air_quality_compliance` | `boolean` | Whether area is in attainment for all EPA ambient air quality standards. | | `noise_level` | `string | null` | Ambient noise level in the area affecting quality of life and property desirability. `Quiet``Moderate``Busy``Loud` | | `noise_sources` | `array` | Specific sources of noise in the area. | | `light_pollution_level` | `string | null` | Light pollution level affecting night sky visibility and natural darkness. `Dark``Rural``Suburban``Urban` | | `earthquake_zone` | `string | null` | Seismic zone designation or earthquake risk classification for the area. | | `soil_stability` | `string | null` | Soil stability assessment considering factors like erosion, subsidence, and landslide risk. `Stable``Moderate``Unstable``HighRisk` | | `environmental_hazards` | `array` | List of additional environmental hazards present in the area (e.g., 'Radon', 'Industrial Pollution', 'Mining Activity'). | | `flood_risk_level` | `string | null` | Flood risk assessment based on FEMA flood zone data. `Minimal``Low``Moderate``High``Extreme` | | `flood_zone_designation` | `string | null` | FEMA flood zone designation (e.g., 'Zone X', 'Zone AE'). | | `flood_insurance_required` | `boolean` | Whether flood insurance is required for the property. | | `wind_storm_risk` | `string | null` | Wind storm and hurricane risk assessment. `Minimal``Low``Moderate``High``Extreme` | | `hurricane_engineering_compliance` | `boolean` | Whether building is engineered for hurricane winds per current code. | | `radon_risk_level` | `string | null` | Radon gas exposure risk assessment. `Low``Moderate``High``Concern` | | `radon_building_type_assessment` | `string | null` | Radon risk specific to building type (e.g., 'rarely an issue in low-rise wood frame condos'). | | `environmental_surroundings` | `string | null` | Primary environmental setting surrounding the property. `CoastalBeach``Mountains``Desert``Forest``Urban``Suburban``Rural``Industrial` | | `beach_proximity` | `object` | Details about nearby beach access if applicable. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # file # file Media and documents associated with a property: images, recorded documents, and their source references. The file class is a comprehensive data structure that represents all media and documents associated with a specific property, including images, PDFs, and floor plans across multiple file formats (JPEG, PNG, PDF). The question it answers ## What changed since it was built? Two physically identical houses on the same street diverge by six figures if one had a gut renovation. Photographs show current condition but not cost basis, scope, or recency. A permit records all three, and a pulled but unfinalised permit is a leading indicator priced differently again. Permits are issued by municipalities rather than counties, which is an order of magnitude more integration surface than parcel data and the reason incumbent coverage is thin. Other classes answering this question ## Why it matters Documents are how a claim is verified. A deed record links to the recorded instrument; a permit links to the filing; a photograph is dated evidence of condition. The class carries the reference rather than the bytes, so the record stays small and the source stays authoritative. ## In practice Each entry carries the source reference it was retrieved by, which for county clerk documents is a document number resolvable against the clerk's own index. That is what allows a document cited here to be re-fetched independently rather than taken on trust. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object | null` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `file_format` | `string | null` | The format or MIME type of the file. `jpeg``png``txt` | | `name` | `string | null` | A human-friendly name for the media asset. | | `original_url` | `string | null` | HTTP/HTTPS source URL of the media asset. | | `document_type` | `string | null` | Semantic role or classification of the document. `Title``ConveyanceDeedQuitClaimDeed``ConveyanceDeedBargainAndSaleDeed``ConveyanceDeedWarrantyDeed``ConveyanceDeed``AssignmentAssignmentOfDeedOfTrust``AssignmentAssignmentOfMortgage``AssignmentAssignmentOfRents``Assignment``AssignmentAssignmentOfTrade``AssignmentBlanketAssignment``AssignmentCooperativeAssignmentOfProprietaryLease``AffidavitOfDeath``AbstractOfJudgment``AttorneyInFactAffidavit``ArticlesOfIncorporation``BuildingPermit``ComplianceInspectionReport``ConditionalCommitment``CounselingCertification``AirportNoisePollutionAgreement``BreachNotice``BrokerPriceOpinion``AmendatoryClause``AssuranceOfCompletion``Bid``BuildersCertificationBuilderCertificationOfPlansAndSpecifications``BuildersCertificationBuildersCertificate``BuildersCertificationPropertyInspection``BuildersCertificationTermiteTreatment``PropertyImage` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Santa Clara, California How a new jurisdiction is brought online --- # flood_storm_information # flood_storm_information Federal flood mapping for the property: zone classification, insurance requirement, community and panel identifiers, and evacuation designation. FEMA flood and storm information data containing flood zone classifications, insurance requirements, and evacuation zone designations for property locations. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Flood zone determines whether insurance is mandatory, which is a monthly cost and, in some markets, a financeability question rather than a preference. Evacuation designation is a separate and locally-defined overlay that does not follow the flood map. ## In practice The panel and version identifiers are carried alongside the zone because maps are revised, and a determination is only as good as the panel it was read from. A zone without the panel it came from cannot be re-checked. ## Properties | Property | Type | Definition | | --- | --- | --- | | `community_id` | `string | null` | The FEMA community identifier code for the jurisdiction where the property is located. | | `panel_number` | `string | null` | The FEMA flood insurance rate map (FIRM) panel number that contains the property location. | | `map_version` | `string | null` | The version identifier of the FEMA flood map panel. | | `effective_date` | `string | null` | The date when the current flood map version became effective. Format: MM/DD/YYYY or YYYY-MM-DD. | | `evacuation_zone` | `string | null` | The evacuation zone designation (e.g., A, B, C) assigned to the property location for emergency planning purposes. | | `flood_zone` | `string | null` | The FEMA flood zone designation indicating the level of flood risk (e.g., AE, X, VE). | | `flood_insurance_required` | `boolean` | Indicates whether flood insurance is required based on the flood zone designation and federal regulations. | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `fema_search_url` | `string | null` | The FEMA Map Service Center URL used to search and verify flood information for the specific property address. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # geometry # geometry Coordinate data for a property or parcel: point locations and polygon boundaries. Represents geographical coordinate data including single points and polygonal boundaries for properties and parcels. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters The boundary is what makes spatial questions answerable — whether a parcel touches a flood zone, backs onto a commercial use, or falls inside a school attendance boundary. A point alone answers none of those. ## In practice Both forms are carried because sources publish both, and a centroid derived from a polygon is not the same as a geocoded address point. Which one a record holds determines which spatial queries can be trusted against it. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `latitude` | `number | null` | Latitude coordinate of a single point location, ranging from -90° (South Pole) to +90° (North Pole). | | `longitude` | `number | null` | Longitude coordinate of a single point location, ranging from -180° to +180°. | | `polygon` | `array` | An array of coordinate points defining a closed polygon boundary. Requires at least 3 points to form a valid polygon. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # hoa_policy # hoa_policy The rules and restrictions an association applies to the properties it governs. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters Restrictions are what determine whether a property can be used the way a buyer intends — rental caps, occupancy limits, and architectural controls all bear on value and none of them is visible in the physical record. Four fields split the rules by what they restrict: leasing, pets, vehicles, and everything else the association governs. Leasing is the one that changes an investment case outright — a minimum stay of six months and an owner-occupied-only rule are different assets at the same price. The source dictionary carries no definition for this class. ## In practice Each field is a closed enumeration rather than the association's own prose, so a covenant document that says the same thing three different ways resolves to one value. The fees and amenities the same association declares sit in `homeowners_association`; this class is the rules only. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `leasing_policy` | `string | null` | Summary of leasing rules and duration limits (e.g., minimum stay, frequency, HOA approval). `NoRental``ShortTermRental``LongTermRental``MinimumStay30Days``MinimumStay6Months``MinimumStay1Year``HOAApprovalRequired``OwnerOccupiedOnly``UnlimitedRental``SeasonalRentalOnly` | | `pet_policy` | `string | null` | Information about pet allowances and restrictions (e.g., pet friendly, breed/size restrictions). `NoPets``PetFriendly``DogsOnly``CatsOnly``SmallPetsOnly``WeightRestriction25lbs``WeightRestriction50lbs``BreedRestrictions``MaxTwoPets``PetDeposit``PetFee``ServiceAnimalsOnly` | | `vehicle_policy` | `string | null` | Rules around parking and vehicle types (e.g., no RVs, reserved parking). `NoRestrictions``NoRVs``NoTrailers``NoCommercialVehicles``NoBoats``ReservedParkingOnly``GuestParkingRestricted``MaxTwoVehicles``CoveredParkingRequired``NoStreetParking``PermitRequired` | | `general_restrictions` | `string | null` | Other HOA or property-wide lifestyle rules (e.g., quiet hours, storage bans, dress code). `NoRestrictions``QuietHours``NoSmoking``NoStorage``DressCode``NoSatelliteDishes``NoExteriorModifications``NoPoolAccess``NoGym``AgeLimited55Plus``NoShortTermGuests``HOAApprovalRequired` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # homeowners_association # homeowners_association An association governing a property: its identity, its fees, and what those fees cover. The HomeownersAssociation class represents comprehensive information about homeowners associations (HOAs) governing residential properties, including community governance, financial obligations, and available amenities. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters Association dues are a monthly cost that a payment calculation has to include and a lending question in their own right — a project with inadequate reserves or high investor concentration can be unfinanceable regardless of the borrower. ## In practice The association is separate from its policy because one association governs many properties under one set of rules, and recording the rules against every parcel would multiply the same facts. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `homeowners_association_name` | `string | null` | Name of the homeowners association (e.g., Jupiter Shores HOA). | | `homeowners_association_type` | `string | null` | Refers to the type of Homeowners association (HOA). `Mandatory``Voluntary``Condominium``Hybrid` | | `homeowners_association_amount` | `decimal` | Amount of HOA fees | | `homeowners_association_year` | `integer | null` | year of for the HOA year | | `homeowners_association_fee_frequency` | `string | null` | How often the HOA fee is charged. `Monthly``Quarterly``Annually``Bi-Annually``One-Time` | | `amenities` | `string | null` | List of common amenities offered (e.g., pool, clubhouse, gym, golf course). `pool``clubhouse``gym``golf_course``tennis_court``playground``dog_park``spa``sauna``business_center``game_room``bbq_area``marina``bike_trails``walking_paths``rooftop_deck``community_kitchen``co_working_space``package_lockers` | | `security_features` | `string | null` | Standard security infrastructure or services (e.g., 24/7 guard, gated entry, surveillance cameras). `24_7_guard``gated_entry``surveillance_cameras``keycard_access``security_patrols``doorman``intercom_system``secure_parking``fenced_perimeter``alarm_system``smart_locks` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # inspection # inspection An inspection record: the scheduled and completed dates, the outcome, and the permit it belongs to. Represents a building or property inspection record, including scheduled dates, completion status, and associated permit information. The question it answers ## What changed since it was built? Two physically identical houses on the same street diverge by six figures if one had a gut renovation. Photographs show current condition but not cost basis, scope, or recency. A permit records all three, and a pulled but unfinalised permit is a leading indicator priced differently again. Permits are issued by municipalities rather than counties, which is an order of magnitude more integration surface than parcel data and the reason incumbent coverage is thin. Other classes answering this question ## Why it matters The inspection is what closes a permit. A permit with no final inspection is open work, which is a different valuation position from finished work — and the distinction is only visible if the inspection record is kept alongside the permit rather than folded into it. ## In practice Inspection records come from the same municipal sources as permits and arrive on the same schedule, which is why they are extracted together and why their coverage matches. ## Properties | Property | Type | Definition | | --- | --- | --- | | `inspection_number` | `string` | Unique identifier for the inspection. | | `inspection_status` | `string` | Current status of the inspection indicating whether it has been completed and the outcome. `Passed``Failed``Pending``Scheduled``Cancelled``In Progress` | | `scheduled_date` | `string` | The date when the inspection is scheduled to occur. | | `requested_date` | `string` | The date when the inspection was requested. | | `completed_date` | `string` | The date when the inspection was completed. | | `completed_time` | `string` | The time when the inspection was completed in ISO 8601 time format (HH:MM:SS or HH:MM:SS.sss). | | `permit_number` | `string` | The permit number associated with this inspection, identifying the construction or renovation permit being inspected. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Santa Clara, California How a new jurisdiction is brought online --- # layout # layout Rooms and spaces within a property, one record per space, with the physical characteristics of each. The Layout class provides comprehensive documentation of individual rooms and spaces within a property, capturing detailed physical characteristics, design elements, and condition assessments. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Bedroom and bathroom counts are the headline, but the reason to decompose by space is that the counts alone are ambiguous. A finished basement bedroom, a converted garage and an addition are all bedrooms in a count and are not the same thing in a price. ## In practice Each space carries its own dimensions, finish and condition, so a valuation can distinguish gross living area from total area under roof. The distinction matters because assessors and listings measure them differently, and a comparison that mixes the two is comparing different quantities. The extraction is multi-building aware: a parcel with a main house and a detached accessory unit produces spaces for both rather than merging them. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `building_number` | `integer | null` | The building number identifying which building the room or space is located in (useful for multi-building properties or complexes). | | `total_area_sq_ft` | `integer | null` | Total enclosed building area in square feet, including all finished and unfinished spaces. | | `built_year` | `integer | null` | The year in which the layout built. | | `adjustable_area_sq_ft` | `integer | null` | Adjustable area in square feet used for planning or reconfiguration (e.g., flex or convertible spaces). | | `livable_area_sq_ft` | `integer | null` | Heated living area in square feet (habitable space excluding garages, porches, and unfinished areas). | | `heated_area_sq_ft` | `integer | null` | Heated area (served by permanent heating) in square feet. Typically overlaps living area under air. | | `area_under_air_sq_ft` | `integer | null` | Air-conditioned area under air (A/C) in square feet. | | `story_type` | `string | null` | Structural story classification if applicable `Full``Half Story``Three-Quarter Story` | | `space_type` | `string | null` | The function or designation of the room. `Building``Living Room``Family Room``Great Room``Dining Room``Office Room``Conference Room``Class Room``Plant Floor``Kitchen``Breakfast Nook``Pantry``Primary Bedroom``Secondary Bedroom``Guest Bedroom``Children’s Bedroom``Nursery``Full Bathroom``Three-Quarter Bathroom``Half Bathroom / Powder Room``En-Suite Bathroom``Jack-and-Jill Bathroom``Primary Bathroom``Laundry Room``Mudroom``Closet``Bedroom``Walk-in Closet``Mechanical Room``Storage Room``Server/IT Closet``Home Office``Library``Den``Study``Media Room / Home Theater``Game Room``Home Gym``Music Room``Craft Room / Hobby Room``Prayer Room / Meditation Room``Safe Room / Panic Room``Wine Cellar``Bar Area``Greenhouse``Attached Garage``Detached Garage``Carport``Workshop``Storage Loft``Porch``Screened Porch``Sunroom``Deck``Patio``Pergola``Balcony``Terrace``Gazebo``Pool House``Outdoor Kitchen``Lobby / Entry Hall``Common Room``Utility Closet``Elevator Lobby``Mail Room``Janitor’s Closet``Pool Area``Indoor Pool``Outdoor Pool``Hot Tub / Spa Area``Shed``Lanai``Open Porch``Enclosed Porch``Attic``Enclosed Cabana``Carport``Attached Carport``Detached Carport``Detached Utility Closet``Jacuzzi``Courtyard``Open Courtyard``Screen Porch (1-Story)``Screen Enclosure (2-Story)``Screen Enclosure (3-Story)``Screen Enclosure (Custom)``Lower Garage``Lower Screened Porch``Screened Porch``Stoop``First Floor``Second Floor``Third Floor``Fourth Floor``Floor``Basement``Sub-Basement``Living Area``Barn` | | `space_index` | `integer` | An index number representing the order of each space type in the property layout. | | `space_type_index` | `string` | An index number representing the order of each space type and index in the property layout | | `flooring_material_type` | `string | null` | Refers to the type of material used for a floor. `Manufactured``EngineeredWood``Terazzo``Brick``Wood``CinderBlock``Concrete``Shingle``Composition``Linoleum``Stone``CeramicTile``Block``WoodSiding``ImpactGlass``Carpet``Marble``Vinyl``Tile``PouredConcrete``Metal``Glass``Laminate` | | `size_square_feet` | `number | null` | Room area in square feet. | | `floor_level` | `string | null` | The floor level the room is on, useful for multi-story properties. `1st Floor``2nd Floor``3rd Floor``4th Floor` | | `has_windows` | `boolean | null` | Whether the room has windows or not (relevant for egress and lighting). | | `window_design_type` | `string | null` | Refers to the window design. `Skylights``Transom``Egress``Garden``Awning``DoubleHung``Jalousie``SingleHung``Sliding``Bay``Bow``Greenhouse``Picture``Casement` | | `window_material_type` | `string | null` | Refers to the type of material a window is made from. `Manufactured``EngineeredWood``Terazzo``Brick``Wood``CinderBlock``Concrete``Shingle``Composition``Linoleum``Stone``CeramicTile``Block``WoodSiding``ImpactGlass``Carpet``Marble``Vinyl``Tile``PouredConcrete``Metal``Glass``Laminate` | | `window_treatment_type` | `string | null` | Refers to the type of window treatment that covers the windows. `Blinds``Drapes``VerticalBlinds``HorizontalBlinds``Shades``PlantationShutters``CafeShutters``RollerShades``RomanShades``CellularHoneycombShades``SolarShades``PleatedShades``Curtains``BlackoutCurtains``ThermalCurtains``Valances``Cornices``WindowFilm``StainedGlass``BambooShades``WoodShades``WovenShades` | | `is_finished` | `boolean` | Whether the room is finished (especially important for basements, attics, garages). | | `furnished` | `string | null` | Indicates whether the room is furnished and to what extent. `Furnished``Unfurnished``Partially Furnished` | | `paint_condition` | `string | null` | Visual state of paint within the room. `New``Good``Worn``Peeling` | | `flooring_wear` | `string | null` | Observed condition of the flooring. `Pristine``Good``Moderate``Worn``Damaged` | | `clutter_level` | `string | null` | Amount of visible clutter or personal items in the room. `Staged``Moderate``Heavy` | | `visible_damage` | `string | null` | List of visible damage types (e.g. mold, stains, cracks, broken fixtures). | | `countertop_material` | `string | null` | Material of visible countertops, if present. `Granite``Quartz``Marble``Laminate``Wood``Tile``Concrete` | | `cabinet_style` | `string | null` | Visual cabinet style present in the room, if any. `Modern``Shaker``Traditional``Flat Panel``Glass Front` | | `fixture_finish_quality` | `string | null` | `Basic``Mid-range``Luxury` | | `design_style` | `string | null` | Dominant design style observed in the room. `Modern``Traditional``Rustic``Eclectic``Minimalist``Transitional` | | `natural_light_quality` | `string | null` | Assessment of natural light availability. `Abundant``Moderate``Limited` | | `decor_elements` | `string | null` | List of prominent design elements. `Vaulted Ceiling``Coffered Ceiling``Beamed Ceiling``Tray Ceiling``Accent Wall``Exposed Brick``Crown Molding``Wainscoting``Built-In Shelving``Wall Paneling` | | `pool_type` | `string | null` | Specifies the structural or functional type of the pool if applicable to this room. `SaltWater``AboveGround``Concrete``Heated``BuiltIn``Plunge``Lap``Infinity``Fiberglass``Vinyl``Natural` | | `pool_equipment` | `string | null` | List of visible pool-related equipment such as pumps, heaters, or covers. | | `spa_type` | `string | null` | Specifies the type of spa or hot tub present, if applicable. `Jacuzzi``InGround``Rooftop``WoodFiredHotTub``JapaneseSoakingTub``Saltwater``Heated` | | `safety_features` | `string | null` | Visible safety features such as fencing, alarms, slip-resistant surfaces, or pool covers. `Fencing``PoolCover``Alarm``SelfClosingGate``SlipResistantSurface``Lifebuoy``WarningSignage``SurveillanceCamera``Lighting` | | `view_type` | `string | null` | The dominant view visible from this room. `Courtyard``Ocean``City``Garden``Bay``Marina``Mountain``Park``Waterfront``Street` | | `lighting_features` | `string | null` | Observed lighting fixtures and types in room. `Recessed``Track``Pendant``Chandelier``FlushMount``WallSconces``NaturalLight``Skylight` | | `condition_issues` | `string | null` | AI-observed visual condition issues in the room. `PeelingPaint``VisibleMold``WaterStains``DamagedDrywall``Clutter``Unfinished``Unclean``PersonalItemsVisible` | | `is_exterior` | `boolean` | Indicates whether the space is exterior or interior. | | `pool_condition` | `string | null` | Overall visible condition of the pool structure (tiles, lining, coping, etc.). `New``Good``Worn``Needs Repair``Damaged``Unknown` | | `pool_surface_type` | `string | null` | The visible material or finish used for the pool’s interior surface. `Concrete``Tile``Vinyl Liner``Fiberglass``Painted``Natural Stone``Unknown` | | `pool_water_quality` | `string | null` | The observed quality or clarity of the pool water in the image. `Clear``Slightly Cloudy``Cloudy``Green``Debris Present``Drained``Covered``Unknown` | | `kitchen_renovation_date` | `string | null` | Date this kitchen was last remodeled (BLD/RES/COM). | | `bathroom_renovation_date` | `string | null` | Date this bathroom was last remodeled (BLD/RES/COM/PLU/ELE). | | `installation_date` | `string | null` | Date this layout/space was installed (BLD/RES/COM). | | `flooring_installation_date` | `string | null` | Date flooring in this space was installed (BLD/RES/COM). | | `pool_installation_date` | `string | null` | Date pool was installed (POL). | | `spa_installation_date` | `string | null` | Date spa/hot tub was installed (POL/BLD). | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # loan # loan An existing mortgage against the property: amounts, terms, rates, payment schedule and status. Represents a mortgage loan with comprehensive financial terms, conditions, and status information. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters Encumbrances determine whether a transaction closes and on what timeline. An open lien is a payoff; a chain of assignments with a gap is a title problem; a loan in default is a different transaction entirely. The class carries the loan as recorded against the property, which is a different thing from the loan being originated — that is the mortgage model's `loan`. ## In practice Recorded loan data comes from the deed index rather than from a servicer, so it reflects what was filed rather than the current balance. Treating a recorded original amount as an outstanding balance is the common error, and the class keeps the recording data alongside so the distinction stays visible. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `borrower_count` | `integer | null` | The number of borrowers obligated on the note. | | `end_date` | `string | null` | The end date is the date when the borrower is expected to have fully repaid the mortgage loan and the mortgage is considered to be fully paid off. This date is typically specified in the mortgage agreement and is calculated based on the term of the mortgage, which is the length of time the borrower has to repay the loan. | | `lien_priority_type` | `string | null` | Defines the priority of claims against the property in the event of default or foreclosure. The priority determines the sequence of debt repayment if the property is sold or foreclosed on `FirstLien``ThirdLien``FourthLien``SecondLien` | | `loan_amount` | `decimal` | Loan amount refers to the total amount of money that a borrower borrows from a lender to purchase a property. This amount is typically based on the purchase price of the property, minus any down payment that the borrower is able to make. | | `loan_closing_date` | `string | null` | The date on which the mortgage loan is officially closed and the loan funds are disbursed to the borrower. | | `loan_purpose_type` | `string | null` | Specifies the primary reason or purpose for which the loan was taken. `Refinance``Purchase``MortgageModification``Unknown` | | `lender_name` | `string | null` | The name of the institution or company that originated or currently owns the loan. | | `mortgage_type` | `string | null` | Mortgage type refers to the specific type of mortgage loan that a borrower obtains to finance the purchase or refinance of a property. There are several different types of mortgage loans, each with its own set of features, eligibility requirements, and interest rates. `Conventional``Va``UsdaRuralDevelopment``LocalAgency``Fha``PublicAndIndianHousing``StateAgency` | | `note_amount` | `decimal` | The amount to be repaid as disclosed on the note. | | `note_date` | `string | null` | The date on the note. | | `note_rate_percent` | `decimal` | The actual interest rate as disclosed on the note. | | `occupancy` | `string | null` | Occupancy type refers to the way in which a property is used or occupied by its owner or tenant. Occupancy type is used in determining the terms of a mortgage or loan and the level of risk associated with a property. `SecondHome``PrimaryResidence``Investment` | | `prepayment_penalty_indicator` | `boolean` | Indicates whether the loan includes a penalty charged to the borrower in the event of prepayment. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # lot # lot The land around the structure: dimensions, topography, landscaping, and the exterior characteristics recorded against the parcel. The Lot class captures comprehensive information about the land parcel and exterior property characteristics surrounding a structure, including physical dimensions, surface features, and condition assessments. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Lot size and shape set what can be built and what a buyer is actually acquiring. Two identical houses on a quarter-acre and a two-acre lot are different transactions, and the difference is not proportional to the extra land. ## In practice The class carries recorded dimensions rather than a computed area where the source gives them, because the two disagree often enough to matter — an irregular parcel's stated acreage and its recorded frontage and depth are frequently inconsistent in the source, and collapsing them to one number hides that. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `lot_type` | `string | null` | Refers to characteristics associated with a lot and structure. `GreaterThanOneQuarterAcre``PavedRoad``LessThanOrEqualToOneQuarterAcre` | | `lot_size_acre` | `number | null` | The size of the lot in acre. | | `lot_length_feet` | `integer | null` | The length of the lot in feet (typically the side parallel to the street). | | `lot_width_feet` | `integer | null` | The width of the lot in feet (typically the depth of the property from front to back). | | `lot_area_sqft` | `integer | null` | Total land size in square feet for a property | | `landscaping_features` | `string | null` | Features associated with the landscaping on the lot. `MatureTrees``ManicuredGarden``OvergrownVegetation``FlowerBeds``Planters``Lawn` | | `view` | `string | null` | Descriptive tag of the view from the lot. `OceanView``Waterfront``MountainView``CitySkylineView``ParkView` | | `fencing_type` | `string | null` | `Wood``ChainLink``Vinyl``Aluminum``WroughtIron``Bamboo``Composite``Privacy``Picket``SplitRail``Stockade``Board``PostAndRail``Lattice` | | `fence_height` | `string | null` | `3ft``4ft``5ft``6ft``8ft``10ft``12ft` | | `fence_length` | `string | null` | `25ft``50ft``75ft``100ft``150ft``200ft``300ft``500ft``1000ft` | | `driveway_material` | `string | null` | The material of the driveway on the lot. `Concrete``Asphalt``Pavers``Gravel` | | `driveway_condition` | `string | null` | `Good``Cracked``Stained``Worn` | | `lot_condition_issues` | `string | null` | AI-observed lot-level maintenance or neglect issues. `OvergrownWeeds``Clutter``TrashPiles``BrokenFence``CrackedDriveway` | | `site_lighting_type` | `string | null` | Type and height of outdoor lighting fixtures on the lot `LightStandard10to30ft``LightStandardUnder10ft``LightStandardOver30ft``FloodLight``SecurityLight``PathLight``None` | | `site_lighting_fixture_count` | `number | null` | Total number of light fixtures installed on the property | | `site_lighting_installation_date` | `string | null` | Installation date of site lighting (YYYY-MM-DD or YYYY) | | `paving_type` | `string | null` | Primary paving material used on the lot `Asphalt``Concrete``Gravel``Pavers``Brick``Composite``None` | | `paving_area_sqft` | `number | null` | Total paved area in square feet | | `paving_installation_date` | `string | null` | Installation date of paving (YYYY-MM-DD or YYYY) | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # parcel # parcel The land parcel as the jurisdiction records it: its identifier, and the formatted variants of that identifier the source publishes. Represents a parcel of land with unique identifiers and formatted representations for property management and legal documentation purposes. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters The parcel identifier is how a jurisdiction refers to a property in every record it keeps — the tax roll, the deed index, the permit file. Resolving one across those sources is what turns four unrelated documents into one property history. ## In practice Jurisdictions format the same identifier several ways. A county will publish a punctuated form on the assessor page, an unpunctuated form in a bulk file, and a third form in the clerk's index, so the class carries the formatted variants rather than picking one and losing the ability to match the others. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `parcel_identifier` | `string` | Each parcel of land has a unique Parcel ID that distinguishes it from all other parcels within the jurisdiction. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # person # person An individual: name, demographics, identification, citizenship and the biographical detail the source records. Represents an individual person with comprehensive personal information including name, demographics, identification, citizenship status, and biographical details. The question it answers ## Who owns it, and what does that imply? A deed names its parties as strings. Resolving those strings to a person and a mailing address is what separates an owner-occupant from an investor, and what links one owner to the rest of a portfolio. Other classes answering this question ## Why it matters Ownership is the question this class exists to answer. A deed names parties as strings, and turning those strings into people is what separates an owner-occupant from an investor and links one owner to the rest of a portfolio. ## In practice Name parsing is the work. County records are upper case, comma-ordered, inconsistently suffixed, and carry markers that are not part of a name — trustee abbreviations, estate markers, and a deceased marker among them. The normaliser carries checked-in vocabularies for suffixes, surname prefixes and company keywords, and the presence of a deceased marker and a trustee abbreviation in those lists is the sign they were written against real deed data rather than invented. The first decision is whether a party string is a person at all, because the same field carries both individuals and entities. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `birth_date` | `string | null` | A birth date is the date on which a person was born. It typically includes the day, month, and year of an individual's birth and is used to determine their age. | | `first_name` | `string` | A person's first name is the name that they are given at birth or during infancy, and it is typically used to identify them in a personal or informal context. | | `last_name` | `string` | A person's last name, also known as surname or family name, is typically the name that is shared by all members of their immediate family. | | `middle_name` | `string | null` | The middle name of the individual represented by the parent object | | `prefix_name` | `string | null` | Common honorifics or titles preceding names. Adjust this list based on cultural or domain-specific requirements. `Mr.``Mrs.``Ms.``Miss``Mx.``Dr.``Prof.``Rev.``Fr.``Sr.``Br.``Capt.``Col.``Maj.``Lt.``Sgt.``Hon.``Judge``Rabbi``Imam``Sheikh``Sir``Dame` | | `suffix_name` | `string | null` | Suffixes typically denote generational titles, academic degrees, or professional certifications. `Jr.``Sr.``II``III``IV``PhD``MD``Esq.``JD``LLM``MBA``RN``DDS``DVM``CFA``CPA``PE``PMP``Esq.``Emeritus``Ret.` | | `us_citizenship_status` | `string | null` | Citizenship status refers to an individual's legal status as a citizen or non-citizen of a country. In the United States, citizenship status is determined by birthright, naturalization, or other legal means. `NonPermanentResidentAlien``NonPermResidentAlien``PermResidentAlien``PermanentResidentAlien``USCitizenAbroad``USCitizen``ForeignNational` | | `veteran_status` | `boolean | null` | Veteran status refers to an individual's status as a former member of the armed forces. In the United States, a person is considered a veteran if they have served in the active military, naval, or air service and were discharged or released from that service under conditions other than dishonorable. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # property_improvement # property_improvement Permitted work on a property: the scope, the date, the declared valuation, the contractor, and whether it reached final inspection. The question it answers ## What changed since it was built? Two physically identical houses on the same street diverge by six figures if one had a gut renovation. Photographs show current condition but not cost basis, scope, or recency. A permit records all three, and a pulled but unfinalised permit is a leading indicator priced differently again. Permits are issued by municipalities rather than counties, which is an order of magnitude more integration surface than parcel data and the reason incumbent coverage is thin. Other classes answering this question ## Why it matters The permit record is what makes a renovation datable and costable. The declared valuation on the permit is the contractor's own figure at the time of filing, which is a lower bound on spend rather than an appraisal, and the scope text is the description the jurisdiction accepted. Recency comes from the filing and completion dates, which is why the class holds both rather than a single date. The source dictionary carries no definition for this class. ## In practice Acquisition is the hard part, and it is a sourcing problem rather than a technical one. Permits are issued by municipalities, and the recorded estimate puts the number of permit-issuing bodies in the tens of thousands against roughly 3,300 counties. Coverage therefore reports permits as a separate surface: a jurisdiction served for property records is not automatically served for permits. An unfinalised permit is a distinct state rather than missing data, which is why the inspection record is its own class — see `inspection`. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `improvement_type` | `string | null` | `GeneralBuilding``ResidentialConstruction``CommercialConstruction``BuildingAddition``StructureMove``Demolition``PoolSpaInstallation``Electrical``MechanicalHVAC``GasInstallation``Roofing``Fencing``DockAndShore``FireProtectionSystem``Plumbing``ExteriorOpeningsAndFinishes``MobileHomeRV``LandscapeIrrigation``ScreenEnclosure``ShutterAwning``SiteDevelopment``CodeViolation``Complaint``ContractorLicense``Sponsorship``StateLicenseRegistration``AdministrativeApproval``AdministrativeAppeal``BlueSheetHearing``PlannedDevelopment``DevelopmentOfRegionalImpact``Rezoning``SpecialExceptionZoning``Variance``ZoningExtension``ZoningVerificationLetter``RequestForRelief``WaiverRequest``InformalMeeting``EnvironmentalMonitoring``Vacation``VegetationRemoval``ComprehensivePlanAmendment``MinimumUseDetermination``TransferDevelopmentRightsDetermination``MapBoundaryDetermination``TransferDevelopmentRightsCertificate``UniformCommunityDevelopment``SpecialCertificateOfAppropriateness``CertificateToDig``HistoricDesignation``PlanningAdministrativeAppeal``WellPermit``Solar``TestBoring``ExistingWellInspection``NaturalResourcesComplaint``NaturalResourcesViolation``LetterWaterSewer``UtilitiesConnection``DrivewayPermit``RightOfWayPermit` | | `improvement_status` | `string | null` | Current status of the improvement project. `Completed``InProgress``Planned``Permitted``OnHold``Cancelled` | | `completion_date` | `string | null` | Date when the improvement work was completed. | | `contractor_type` | `string | null` | Type of contractor or method used for the work. `GeneralContractor``Specialist``DIY``PropertyManager``Builder``HandymanService``Unknown` | | `permit_required` | `boolean` | Whether the improvement required building permits. | | `permit_number` | `string | null` | Jurisdiction record/permit number (e.g., MEC2025-05360). | | `application_received_date` | `string | null` | Date the application was received. | | `permit_issue_date` | `string | null` | Date the permit was issued. | | `final_inspection_date` | `string | null` | Date of final inspection approval. | | `permit_close_date` | `string | null` | Date the permit record was closed/complete. | | `improvement_action` | `string | null` | Nature of the work. `New``Replacement``Repair``Alteration``Addition``Remove``Other` | | `is_owner_builder` | `boolean | null` | Whether improvement is done by owner versus hiring a contractor | | `is_disaster_recovery` | `boolean | null` | Whether the work is associated with disaster recovery. | | `private_provider_plan_review` | `boolean | null` | Private provider used for plan review. | | `private_provider_inspections` | `boolean | null` | Private provider used for inspections. | | `fee` | `decimal` | Cost associated with acquiring the property improvement/permits. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Santa Clara, California How a new jurisdiction is brought online --- # property_ranking_overall # property_ranking_overall Composite scores for a property across climate, safety, wellness, ambience and location quality. Overall property ranking and assessment scores based on multiple factors including climate, safety, wellness, ambience, and location quality. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters A composite score is a convenience over the classes that produce it, and it is recorded as its own class so a consumer can see the components rather than only the roll-up. ## In practice The components are the environmental, safety, transport and school classes. Where one of those is thin for a jurisdiction the composite inherits the gap, which is why the components stay addressable rather than being collapsed. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | CRLF-formatted and JSON-stringified HTTPS request from which this data can be retrieved. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `overall_ranking_score` | `number` | Overall property ranking score out of 100. | | `ranking_percentile` | `string | null` | Percentile ranking description (e.g., 'top 5% of similar listings'). | | `climate_score` | `number` | Climate assessment score. | | `safety_grade` | `string | null` | Safety grade assessment. `A+``A``A-``B+``B``B-``C+``C``C-``D+``D``D-``F` | | `wellness_score` | `number` | Wellness and health factors score. | | `ambience_score` | `number` | Ambience and livability score. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # property_seed # property_seed The minimum identifying set for a property: enough to address it in a source system before anything else is known. A minimum set of house property seed data containing essential identifying information for property records. The question it answers ## Who owns it, and what does that imply? A deed names its parties as strings. Resolving those strings to a person and a mailing address is what separates an owner-occupant from an investor, and what links one owner to the rest of a portfolio. Other classes answering this question ## Why it matters This is where a jurisdiction run starts. The seed carries the parcel identifier and the source location, which is everything needed to fetch the record and nothing more. Separating the seed from the record is what allows acquisition to be planned before extraction is written: a jurisdiction's parcel list can be assembled and counted while the mapping scripts for it are still being generated. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `entry_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `parcel_id` | `string` | A unique identifier for the property parcel as assigned by the local assessor or jurisdiction. | | `prior_parcel_id` | `string` | The parcel identification number (parcel ID or folio) that was previously assigned to the property before it was changed due to a split, combination, renumbering, or administrative update by the property appraiser. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # property # property The root record for a parcel of real estate: its identifiers, its legal description, and the characteristics every other class hangs off. The Property class serves as the foundational data structure for capturing essential characteristics and legal identifiers of real estate properties, providing comprehensive documentation for financing, legal, and classification purposes. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Everything else in the model attaches here. A structure, a lot, a tax position and a sales history are all statements about one property, and the identifiers on this class are what make them the same property rather than four records that happen to share an address. ## In practice Identity is the hard part, not the attributes. A parcel is identified by the jurisdiction's own parcel number, which is formatted differently in every county and is not unique across them; the address is a second identifier that is frequently wrong or absent. Both are carried, and neither is trusted alone. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `historic_designation` | `boolean` | True if the property has been granted official historic designation by a local, state, or national authority; false otherwise. | | `livable_floor_area` | `string | null` | The total square footage of attached, livable area excluding balconies, porches, garages, car ports, elevators, and utility rooms. | | `area_under_air` | `string | null` | Also called “Living Area Under Air” or “Heated Living Area,” this refers to the total finished square footage of a building that is served by a permanent heating and/or cooling system (HVAC). | | `total_area` | `string | null` | The total square footage of the property, including all areas, such as the living area, garage, and basement. | | `number_of_units_type` | `string | null` | number of units type in mortgage banking refers to the classification of a property based on the number of units it contains. This classification is important for determining the type of loan that can be used to finance the property, as well as the underwriting requirements and guidelines that must be followed. Typically, properties are classified into one of three categories: single-family homes, multi-family homes (e.g. duplexes, triplexes, fourplexes), and larger multi-unit properties (e.g. apartment buildings). The number of units type is used to determine the loan-to-value (LTV) ratio, debt-to-income (DTI) ratio, and other loan requirements, as well as the risk associated with the property. For example, rdf:type single-family home may have more favorable lending terms than rdf:type multi-unit property, as the latter may be seen as rdf:type higher risk due to the potential for multiple tenants and increased maintenance costs. `One``Two``OneToFour``Three``Four``TwoToFour` | | `number_of_units` | `integer | null` | The number of units for a property refers to how many separate, self-contained dwelling or rental spaces exist within that property. | | `parcel_identifier` | `string` | Each parcel of land has a unique Parcel ID that distinguishes it from all other parcels within the jurisdiction. | | `ownership_estate_type` | `string | null` | A value from a MISMO prescribed list that specifies the ownership interest in the property. `Condominium``Cooperative``LifeEstate``Timeshare``OtherEstate``FeeSimple``Leasehold``RightOfWay``NonWarrantableCondo``SubsurfaceRights` | | `property_legal_description_text` | `string | null` | A detailed legal description of the property, often used in legal documents and contracts. This typically outlines the exact boundaries, dimensions, and location of the property as recognized by local or state governments. | | `property_structure_built_year` | `integer | null` | The year in which the dwelling on the property was completed. | | `property_effective_built_year` | `integer | null` | The year assigned by the property appraiser that reflects the building’s overall condition, age, and the impact of major renovations or additions, rather than the actual calendar year of original construction. | | `build_status` | `string | null` | Indicates the current construction and improvement status of the property. VacantLand indicates undeveloped land with no structures, Improved indicates land with completed structures or improvements, and UnderConstruction indicates active construction or development in progress. `VacantLand``Improved``UnderConstruction` | | `property_type` | `string` | Property type refers to the classification of a real estate property based on its characteristics, usage, and zoning designation. Property types can include residential, commercial, industrial, agricultural, and mixed-use properties. `Cooperative``Condominium``Modular``ManufacturedHousingMultiWide``Pud``Timeshare``2Units``DetachedCondominium``Duplex``SingleFamily``MultipleFamily``3Units``ManufacturedHousing``ManufacturedHousingSingleWide``4Units``Townhouse``NonWarrantableCondo``VacantLand``Retirement``MiscellaneousResidential``ResidentialCommonElementsAreas``MobileHome``Apartment``MultiFamilyMoreThan10``MultiFamilyLessThan10``LandParcel``Building``Unit``ManufacturedHome` | | `structure_form` | `string | null` | Describes the physical form or architectural configuration of the dwelling structure. This classification identifies the attachment style and unit type, such as single-family detached homes, townhouses, multi-unit buildings, or manufactured homes, which impacts property valuation, lending guidelines, and zoning considerations. `SingleFamilyDetached``SingleFamilySemiDetached``TownhouseRowhouse``Duplex``Triplex``Quadplex``MultiFamily5Plus``ApartmentUnit``Loft``ManufacturedHomeOnLand``ManufacturedHomeInPark``MultiFamilyMoreThan10``MultiFamilyLessThan10``MobileHome``ManufacturedHousingMultiWide``ManufacturedHousing``ManufacturedHousingSingleWide``Modular` | | `property_usage_type` | `string | null` | A value from a MISMO prescribed list that specifies the intended usage of the property by the borrower. `Residential``Commercial``Industrial``Agricultural``Recreational``Conservation``Retirement``ResidentialCommonElementsAreas``DrylandCropland``HayMeadow``CroplandClass2``CroplandClass3``TimberLand``GrazingLand``OrchardGroves``Poultry``Ornamentals``Church``PrivateSchool``PrivateHospital``HomesForAged``NonProfitCharity``MortuaryCemetery``ClubsLodges``SanitariumConvalescentHome``CulturalOrganization``Military``ForestParkRecreation``PublicSchool``PublicHospital``GovernmentProperty``RetailStore``DepartmentStore``Supermarket``ShoppingCenterRegional``ShoppingCenterCommunity``OfficeBuilding``MedicalOffice``TransportationTerminal``Restaurant``FinancialInstitution``ServiceStation``AutoSalesRepair``MobileHomePark``WholesaleOutlet``Theater``Entertainment``Hotel``RaceTrack``GolfCourse``LightManufacturing``HeavyManufacturing``LumberYard``PackingPlant``Cannery``MineralProcessing``Warehouse``OpenStorage``Utility``RiversLakes``SewageDisposal``Railroad``TransitionalProperty``ReferenceParcel``NurseryGreenhouse``AgriculturalPackingFacility``LivestockFacility``Aquaculture``VineyardWinery``DataCenter``TelecommunicationsFacility``SolarFarm``WindFarm``NativePasture``ImprovedPasture``Rangeland``PastureWithTimber``Unknown` | | `subdivision` | `string | null` | Subdivision is the term used to describe a defined area within a city or community that has been divided into individual plots or lots, usually intended for residential or commercial development. It is often formally designated by the township or municipality. | | `zoning` | `string | null` | Zoning is a system of land-use regulation created by local governments to control how property and land within a community can be used. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # safety_security # safety_security Safety metrics for the property's location: crime rates, emergency-services response, and an overall assessment. Safety and security metrics including crime rates, emergency services response times, and overall safety assessments. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Safety at location level is one of the inputs buyers weight most heavily and one of the least consistently available, because the reporting geography rarely matches the parcel geography. ## In practice The figures come from published sources at whatever geography those sources use, which is usually a reporting district rather than a parcel. The class records what was published rather than interpolating to the parcel, so a consumer can decide how to treat the mismatch. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `crime_rate` | `string | null` | Overall crime rate assessment for the area. `VeryLow``Low``Moderate``High``VeryHigh` | | `crime_rate_comparison` | `string | null` | Comparison to national average (e.g., '70% below national avg'). | | `emergency_services_response` | `string | null` | Emergency services response time quality. `FastResponse``GoodResponse``AverageResponse``SlowResponse` | | `emergency_response_time` | `string | null` | Specific response time range (e.g., '5-7 min response time'). | | `overall_safety_grade` | `string | null` | Overall safety grade for the area. `A+``A``A-``B+``B``B-``C+``C``C-``D+``D``D-``F` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # sales_history # sales_history The recorded transfer history for a property: amount, date, and the type of each transfer. The question it answers ## What are the comparables, really? A recorded deed is the legal source of truth for a transfer: instrument type, consideration, parties, and date. That is what separates an arm's-length sale from a quitclaim between relatives, an estate transfer, a foreclosure, or an investor flip. A comp set that silently includes non-arm's-length transfers is biased before the model sees it. Other classes answering this question ## Why it matters One row per transfer, linked to the deed that recorded it. Holding the full history rather than the last sale is what allows a consumer to filter to arm's-length transactions before computing anything, and to see a flip pattern that a single most-recent-sale field hides. The source dictionary carries no definition for this class. ## In practice The transfer and the document are separate classes because the cardinality differs: one deed can convey several parcels, and one parcel accumulates many deeds. Linking them rather than embedding is what keeps both directions navigable. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `ownership_transfer_date` | `string | null` | The date of the transfer of ownership of real property as recognized in the jurisdiction in which it is located. | | `purchase_price_amount` | `decimal` | The total dollar amount paid by the borrower for the property. The purchase price is presented on the offer to purchase. | | `sale_type` | `—` | `ProbateSale``ShortSale``CourtOrderedNonForeclosureSale``ReoPostForeclosureSale``TrusteeNonJudicialForeclosureSale``RelocationSale``TrusteeJudicialForeclosureSale``TypicallyMotivated` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # school # school The schools serving the property: name, type, ranking, and the attendance relationship. Represents an educational institution such as an elementary, middle, or high school. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters School assignment is one of the largest location premiums in residential pricing, and it is a boundary question rather than a distance question — the nearest school is frequently not the assigned one. ## In practice The class holds the institution; the attendance relationship holds the link to a property. Keeping them separate is what allows a boundary change to be recorded once rather than against every parcel it affects. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `school_name` | `string | null` | The name of the school. | | `school_type` | `string | null` | The type of school. `Elementary``Middle``High` | | `school_ranking` | `string | null` | Ranking of the school. | | `rating_score` | `number` | Numerical rating score out of 10. | | `grade_rating` | `string | null` | Letter grade rating for the school. `A+``A``A-``B+``B``B-``C+``C``C-``D+``D``D-``F` | | `distance_miles` | `number` | Distance from the property to the school in miles. | | `description` | `string | null` | Additional description about the school's programs, reputation, or special features. | | `overall_district_rating` | `number` | Overall school district rating out of 10. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # structure # structure The building itself: construction materials, condition, architectural style, and the structural elements the assessor recorded. Represents the physical building structure with detailed architectural and construction information including materials, conditions, styles, and structural elements. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Everything about the building that is not its shape or its rooms. Those are `lot` and `layout`; this class is what the building is made of and what condition it is in. The distinction matters because the three come from different parts of an assessor's record and are updated on different cycles. Merging them into one property record loses the ability to update the one that changed. ## In practice The class is wide because assessors record at that granularity: exterior wall material and its condition, primary and secondary, then roof, foundation, framing and finish, each carrying its own condition. Attachment type carries more than it appears to. Detached, semi-detached and attached distinguish a house from a duplex half from a townhouse, which is a different comparable set rather than a different adjustment on the same one. Sub-areas are the other field worth knowing. An assessor records areas separately — living area, garage, porch, unfinished space — each flagged for whether it is heated, which is what allows gross living area to be computed rather than taken on trust. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `architectural_style_type` | `string | null` | Refers to the style, structure, and aesthetics of a building. `MidCenturyModern``Contemporary``Victorian``Ranch``Craftsman``Tudor``Minimalist``Colonial``Farmhouse` | | `attachment_type` | `string | null` | Indicates the structural relationship of the dwelling to other units. 'Attached' means the unit shares walls on both sides with adjacent dwellings (e.g., rowhouse or townhouse); 'SemiDetached' means it shares a wall with one other unit (e.g., duplex); 'Detached' means the unit stands alone with no shared walls. `Attached``SemiDetached``Detached` | | `exterior_wall_material_primary` | `string | null` | Primary material used for exterior wall cladding and structure. `Brick``Natural Stone``Manufactured Stone``Stucco``Vinyl Siding``Wood Siding``Fiber Cement Siding``Metal Siding``Concrete Block``EIFS``Log``Adobe``Precast Concrete``Curtain Wall` | | `exterior_wall_material_secondary` | `string | null` | Secondary material used for exterior wall accents or trim. `Brick Accent``Stone Accent``Wood Trim``Metal Trim``Stucco Accent``Vinyl Accent``Decorative Block` | | `exterior_wall_condition_primary` | `string | null` | Observed condition of the exterior wall materials. `New``Excellent``Good``Fair``Poor``Damaged` | | `exterior_wall_condition` | `string | null` | Observed condition of the exterior wall materials. `New``Excellent``Good``Fair``Poor``Damaged` | | `exterior_wall_insulation_type` | `string | null` | Type of insulation used in exterior wall cavities. `Fiberglass Batt``Blown Cellulose``Spray Foam``Rigid Foam Board``Reflective Barrier``Rock Wool``Natural Fiber``Unknown` | | `exterior_wall_insulation_type_primary` | `string | null` | Type of insulation used in exterior wall cavities. `Fiberglass Batt``Blown Cellulose``Spray Foam``Rigid Foam Board``Reflective Barrier``Rock Wool``Natural Fiber``Unknown` | | `exterior_wall_condition_secondary` | `string | null` | Observed condition of the exterior wall materials. `New``Excellent``Good``Fair``Poor``Damaged` | | `exterior_wall_insulation_type_secondary` | `string | null` | Type of insulation used in exterior wall cavities. `Fiberglass Batt``Blown Cellulose``Spray Foam``Rigid Foam Board``Reflective Barrier``Rock Wool``Natural Fiber``Unknown` | | `flooring_material_primary` | `string | null` | Primary flooring material covering floor surface. `Solid Hardwood``Engineered Hardwood``Laminate``Luxury Vinyl Plank``Sheet Vinyl``Ceramic Tile``Porcelain Tile``Natural Stone Tile``Carpet``Area Rugs``Polished Concrete``Bamboo``Cork``Linoleum``Terrazzo``Epoxy Coating` | | `flooring_material_secondary` | `string | null` | Secondary flooring material if multiple types are used in different areas. `Solid Hardwood``Engineered Hardwood``Laminate``Luxury Vinyl Plank``Ceramic Tile``Carpet``Area Rugs``Transition Strips` | | `subfloor_material` | `string | null` | Material used for subfloor structure beneath finish flooring. `Plywood``OSB``Concrete Slab``Engineered Wood``Particle Board``Unknown` | | `flooring_condition` | `string | null` | Overall condition of flooring materials and installation. `New``Excellent``Good``Fair``Poor``Damaged` | | `interior_wall_structure_material` | `string | null` | Structural material used for interior wall framing. `Wood Frame``Steel Frame``Concrete Block``Brick``Load Bearing``Non-Load Bearing` | | `interior_wall_structure_material_primary` | `string | null` | Structural material used for interior wall framing. `Wood Frame``Steel Frame``Concrete Block``Brick``Load Bearing``Non-Load Bearing` | | `interior_wall_structure_material_secondary` | `string | null` | Structural material used for interior wall framing. `Wood Frame``Steel Frame``Concrete Block``Brick``Load Bearing``Non-Load Bearing` | | `interior_wall_surface_material_primary` | `string | null` | Primary surface material covering interior walls throughout most of the structure. `Drywall``Plaster``Wood Paneling``Exposed Brick``Exposed Block``Wainscoting``Shiplap``Board and Batten``Tile``Stone Veneer``Metal Panels``Glass Panels``Concrete` | | `interior_wall_surface_material_secondary` | `string | null` | Secondary material used for interior wall accents, trim, or feature walls. `Wainscoting``Chair Rail``Crown Molding``Baseboards``Wood Trim``Stone Accent``Tile Accent``Metal Accent``Glass Insert``Decorative Panels``Feature Wall Material` | | `interior_wall_finish_primary` | `string | null` | Primary finish treatment applied over interior wall surfaces. `Paint``Primer and Paint``Textured Paint``Natural Finish``Stain``Clear Coat``Exposed Natural` | | `interior_wall_finish_secondary` | `string | null` | Secondary finish treatment for accent areas or decorative elements. `Wallpaper``Wall Decals``Decorative Plaster``Faux Finish``Fabric Wall Covering``Murals``Decorative Paint Technique` | | `interior_wall_condition` | `string | null` | Overall condition of interior wall surfaces and finishes. `New``Excellent``Good``Fair``Poor``Damaged` | | `roof_covering_material` | `string | null` | Material used for the primary roof covering. `3-Tab Asphalt Shingle``Architectural Asphalt Shingle``Metal Standing Seam``Metal Corrugated``Clay Tile``Concrete Tile``Natural Slate``Synthetic Slate``Wood Shake``Wood Shingle``TPO Membrane``EPDM Membrane``Modified Bitumen``Built-Up Roof``Green Roof System``Solar Integrated Tiles` | | `roof_underlayment_type` | `string | null` | Type of underlayment beneath roof covering. `Felt Paper``Synthetic Underlayment``Rubberized Asphalt``Unknown` | | `roof_structure_material` | `string | null` | Material used for roof structural support. `Wood Truss``Wood Rafter``Steel Truss``Concrete Beam``Engineered Lumber` | | `roof_design_type` | `string | null` | Architectural design of the roof structure. `Gable``Hip``Flat``Mansard``Gambrel``Shed``Saltbox``Butterfly``Bonnet``Clerestory``Dome``Barrel``Combination` | | `roof_condition` | `string | null` | Visible condition of the roof covering and structure. `New``Excellent``Good``Fair``Poor``Damaged``Leaking` | | `roof_age_years` | `integer | null` | Estimated age of the roof covering in years. | | `roof_date` | `string | null` | Date when the roof was built (format: YYYY, YYYY-MM, or YYYY-MM-DD) | | `gutters_material` | `string | null` | Material used for gutter system. `Aluminum``Vinyl``Steel``Copper``Galvanized Steel` | | `gutters_condition` | `string | null` | Condition of gutters and downspout system. `New``Good``Fair``Poor``Missing``Damaged` | | `number_of_stories` | `number | null` | Indicates the total number of above-ground stories (floors) in the structure. | | `roof_material_type` | `string | null` | Refers to the material a roof is made of. `Manufactured``EngineeredWood``Terazzo``Brick``Wood``CinderBlock``Concrete``Shingle``Composition``Linoleum``Stone``CeramicTile``Block``WoodSiding``ImpactGlass``Carpet``Marble``Vinyl``Tile``PouredConcrete``Metal``Glass``Laminate` | | `foundation_type` | `string | null` | Type of foundation system supporting the structure. `Slab on Grade``Crawl Space``Full Basement``Partial Basement``Pier and Beam``Basement with Walkout``Stem Wall` | | `foundation_material` | `string | null` | Primary material used in foundation construction. `Poured Concrete``Concrete Block``Stone``Brick``Treated Wood Posts``Steel Piers``Precast Concrete``Insulated Concrete Forms` | | `foundation_waterproofing` | `string | null` | Type of waterproofing system used on foundation. `Membrane``Coating``Drainage System``Unknown` | | `foundation_condition` | `string | null` | Visible condition of the foundation system. `Excellent``Good``Fair``Minor Cracks``Major Cracks``Settling``Water Damage``Unknown` | | `ceiling_structure_material` | `string | null` | Structural material supporting the ceiling. `Wood Joists``Steel Joists``Concrete``Exposed Beams``Truss System` | | `ceiling_surface_material` | `string | null` | Material used for ceiling surface finish. `Drywall``Plaster``Wood Planks``Acoustic Tile``Metal Panels``Suspended Grid``Coffered``Tray``Exposed Structure` | | `ceiling_insulation_type` | `string | null` | Type of insulation above ceiling. `Fiberglass Batt``Blown Insulation``Spray Foam``Rigid Board``Unknown` | | `ceiling_height_average` | `number | null` | Average ceiling height in feet. | | `ceiling_condition` | `string | null` | Overall condition of ceiling materials and structure. `New``Excellent``Good``Fair``Poor``Damaged` | | `exterior_door_material` | `string | null` | Material used for exterior door construction. `Solid Wood``Wood Composite``Steel``Fiberglass``Aluminum``Glass``Vinyl``Wrought Iron``Security Door` | | `interior_door_material` | `string | null` | Material and construction of interior doors. `Solid Wood``Hollow Core``Solid Core``Glass Panel``Metal``Composite``Molded``Bifold``Pocket Door``Barn Door` | | `window_frame_material` | `string | null` | Material used for window frame construction. `Vinyl``Wood``Aluminum``Fiberglass``Steel``Composite``Aluminum Clad Wood``Vinyl Clad Wood` | | `window_glazing_type` | `string | null` | Type and features of window glazing system. `Single Pane``Double Pane``Triple Pane``Low-E Coated``Tempered``Laminated``Impact Resistant``Argon Filled``Tinted``Smart Glass` | | `window_operation_type` | `string | null` | Operational mechanism and style of windows. `Double Hung``Single Hung``Casement``Sliding``Awning``Picture``Bay``Bow``Garden``Skylights``Jalousie``Fixed` | | `window_screen_material` | `string | null` | Material used for window screens. `Aluminum``Fiberglass``Pet Screen``Solar Screen` | | `primary_framing_material` | `string | null` | Primary material used for structural framing system. `Wood Frame``Steel Frame``Concrete Block``Poured Concrete``Masonry``Engineered Lumber``Post and Beam``Log Construction` | | `secondary_framing_material` | `string | null` | Secondary structural materials for support beams and lintels. `Steel Beams``Engineered Lumber``Concrete Lintels``Wood Beams` | | `structural_damage_indicators` | `string | null` | Observable indicators of structural damage or issues. `Foundation Cracks``Wall Cracks``Ceiling Cracks``Sagging Floors``Sagging Roof``Door/Window Misalignment``Water Damage``Termite Damage``Settlement Issues``None Observed` | | `finished_base_area` | `integer | null` | Finished ground-level base area (first-floor footprint) in square feet. | | `unfinished_base_area` | `integer | null` | Unfinished ground-level base area in square feet. | | `finished_basement_area` | `integer | null` | Finished basement area in square feet. | | `unfinished_basement_area` | `integer | null` | Unfinished basement area in square feet. | | `finished_upper_story_area` | `integer | null` | Finished upper story area (above the ground floor) in square feet. | | `unfinished_upper_story_area` | `integer | null` | Unfinished upper story or attic/loft space in square feet. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # tax_authority # tax_authority A body with the legal right to levy against a property: county, municipal, school district, and special districts. Represents tax collecting authorities including county, municipal, school district, and other special district entities that have the legal right to levy and collect property taxes. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters A property is taxed by several authorities at once, and the total obligation is the sum of their separate levies. Modelling them separately is what makes the total explainable and what allows a change in one district's rate to be applied without recomputing the rest. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `authority_name` | `string | null` | The name of the government agency or organization that has the legal right to collect taxes (e.g., 'Miami-Dade County', 'City of Miami', 'Miami-Dade School Board'). | | `authority_account_identifier` | `string | null` | A unique identifier assigned to the tax authority itself, used to distinguish this authority from other tax collecting entities in the system. | | `authority_category` | `string | null` | The category or type of tax authority that determines its jurisdiction and tax collection scope. `County``Municipal``School Board``School District``Independent School District``Independent``Special District``Water District``Fire District``Library District``Hospital District``Community College District``Transit Authority``Port Authority``Utility District``Improvement District``State``Federal` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # tax_exemption # tax_exemption Exemptions applied against a property's assessed value: type, eligibility, amount and status. Represents property tax exemptions including homestead, senior, portability, and other exemption types. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters Exemptions are the difference between assessed and taxable value, and several of them do not survive a sale. A homestead exemption held by an elderly owner-occupant can be a large share of the current bill and nothing at all to the next owner, so a carrying-cost estimate that reads the current tax figure is wrong by that amount. ## In practice Portability is recorded because in some states an exemption benefit follows the owner to a new property, which affects the seller's position rather than the property's. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `tax_year` | `integer | null` | The tax year for which the data applies. | | `tax_rate` | `decimal` | The tax rate associated with the exemption. | | `exemption_type` | `string | null` | The type of exemption applied to the property. Must be one of the predefined exemption types. `Portability``Homestead``Add. Homestead``Wid/Vet/Dis``Senior``Affordable Housing` | | `exemption_value` | `decimal` | The value associated with the exemption. | | `taxable_value_amount` | `decimal` | The taxable value amount of the property. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # tax_jurisdiction # tax_jurisdiction The jurisdictions that govern a property for tax purposes, and the identifier each of them uses for it. The Tax Jurisdiction class captures detailed information about the various tax authorities that govern a property. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters The same parcel carries a different identifier in each authority's records — one in the county assessment roll, another in the municipal levy, a third in the school district's file. Holding those identifiers together is what allows three independently published records to be reconciled to one property. ## In practice Jurisdiction boundaries do not follow county lines and do not always follow municipal ones. A parcel can sit inside a fire district and a water management district that each publish separately, which is why the class holds a set rather than a single governing body. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `jurisdiction_name` | `string | null` | The name of the tax jurisdiction (e.g., county or city name). | | `jurisdiction_type` | `string | null` | The type of tax jurisdiction. `County``Municipal``School Board``School District``Independent School District``Independent``Special District``Water District``Fire District``Library District``Hospital District``Community College District``Transit Authority``Port Authority``Utility District``Improvement District``State``Federal` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # tax # tax The property's tax position: assessed values, exemptions, amounts due, and payment history. Represents property tax information including assessed values, exemptions, tax amounts, and payment details. The question it answers ## Will this close cleanly? Liens, encumbrances, tax position, and association obligations determine whether a transaction completes and on what timeline. Other classes answering this question ## Why it matters Tax is a carrying cost and a valuation signal at once. The assessed value is an independent opinion of value on a published schedule, and the gap between assessed and market value is itself informative in jurisdictions where reassessment is capped. Delinquency is the closing question: unpaid tax is a lien ahead of a mortgage. ## In practice The class holds a history rather than a current figure. A single year's assessed value says little; the sequence shows whether the jurisdiction reassesses on sale, on a cycle, or under a cap, which changes what the next year's obligation will be for a buyer. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `tax_year` | `integer | null` | The tax year for which this property tax assessment applies. | | `property_assessed_value_amount` | `decimal` | The assessed or SOH value of the property used as the basis for property tax calculations for a given tax year. | | `property_market_value_amount` | `decimal` | The just or market value of the property used as the basis for property tax calculations for a given tax year. | | `property_building_amount` | `number | null` | The building or improvement value of the property used as the basis for property tax calculations for a given tax year. | | `property_land_amount` | `number | null` | The land value of the property used as the basis for property tax calculations for a given tax year. | | `property_exemption_amount` | `number | null` | The total exemption amount applied to the property for a given tax year, reducing the assessed value for tax calculation purposes. | | `property_taxable_value_amount` | `decimal` | The final property value on which tax is calculated, derived by subtracting the exemption amount from the assessed value. | | `city_taxable_value_amount` | `decimal` | The taxable value of the property as assessed by the city for property tax calculations for a given tax year. | | `county_taxable_value_amount` | `decimal` | The taxable value of the property as assessed by the county for property tax calculations for a given tax year. | | `college_taxable_value_amount` | `decimal` | The taxable value of the property as assessed by the college district for property tax calculations for a given tax year. | | `hospital_taxable_value_amount` | `decimal` | The taxable value of the property as assessed by the hospital district for property tax calculations for a given tax year. | | `school_taxable_value_amount` | `decimal` | The taxable value of the property as assessed by the school district for property tax calculations for a given tax year. | | `special_district_taxable_value_amount` | `decimal` | The taxable value of the property as assessed by any special districts for property tax calculations for a given tax year. | | `agricultural_valuation_amount` | `decimal` | The agricultural valuation of the property used as the basis for property tax calculations for a given tax year. | | `homestead_cap_loss_amount` | `decimal` | The homestead cap loss of the property used as the basis for property tax calculations for a given tax year. | | `building_replacement_cost_amount` | `decimal` | The total replacement cost of the building used as the basis for property tax calculations for a given tax year. | | `building_depreciated_value_amount` | `decimal` | The total depreciated value of the building used as the basis for property tax calculations for a given tax year. | | `millage_rate` | `number | null` | The millage rate (also called mill rate) used to calculate property taxes, expressed as the tax amount per $1,000 of assessed value. For example, a millage rate of 3.0107 means $3.0107 in taxes per $1,000 of assessed property value. | | `monthly_tax_amount` | `number | null` | The calculated property tax amount due for the specific month (if applicable). | | `yearly_tax_amount` | `number | null` | The calculated property tax amount due for the specific month (if applicable). | | `period_end_date` | `string | null` | period end date in mortgage banking expenses refers to the date that marks the end of a specific time period for which expenses are being reported. This date is used to determine the duration of the time period for which expenses are being calculated and reported. The period end date can be used to calculate the total expenses for rdf:type specific time period, such as rdf:type month or rdf:type quarter, and can help mortgage companies to track and analyze their expenses over time. The period end date is an important factor in determining the accuracy and completeness of expense reporting in mortgage banking. | | `period_start_date` | `string | null` | period start date in mortgage banking expenses refers to the date that marks the beginning of a specific time period for which expenses are being reported. This date is used in conjunction with the period end date to determine the duration of the time period for which expenses are being calculated and reported. The period start date can be used to calculate the total expenses for rdf:type specific time period, such as rdf:type month or rdf:type quarter, and can help mortgage companies to track and analyze their expenses over time. The period start date is an important factor in determining the accuracy and completeness of expense reporting in mortgage banking. | | `first_year_on_tax_roll` | `integer | null` | The first year the parcel (land) was placed on the county’s property tax assessment roll. | | `first_year_building_on_tax_roll` | `integer | null` | The first year a building (improvement) on the parcel was added to the tax assessment roll. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # transportation_access # transportation_access Commute and access quality around the property: walkability, highway access, and transit availability. Transportation and commute quality including walkability, highway access, and overall commute assessment. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters Access is a location premium whose sign varies by market. A highway interchange nearby is a premium in one metro and a discount in another, so the class records the measurements rather than a single score with the weighting already applied. ## In practice Walkability, highway proximity and transit availability are held separately because they are separately available. A jurisdiction with no transit has a genuine absence rather than a low score, and collapsing the three into one number makes the two indistinguishable. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `commute_quality` | `string | null` | Overall commute quality assessment. `Excellent``Great``Good``Fair``Poor` | | `walkability_score` | `number` | Walk Score rating for walkability to amenities. | | `walkability_description` | `string | null` | Description of walkable amenities and access. | | `highway_access` | `string | null` | Quality of highway access. `Excellent``Great``Good``Fair``Poor` | | `major_highways` | `array` | List of major highways and their accessibility. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # unnormalized_address # unnormalized_address The raw address exactly as the source system published it, before parsing. An unnormalized address schema containing raw address data as typically found in source systems before standardization or parsing into individual components. The question it answers ## Who owns it, and what does that imply? A deed names its parties as strings. Resolving those strings to a person and a mailing address is what separates an owner-occupant from an investor, and what links one owner to the rest of a portfolio. Other classes answering this question ## Why it matters Keeping the original is what makes a parsing failure recoverable. When a parse is wrong, the correction runs against the source string; if only the parsed form were kept, the evidence for the correction would be gone. ## In practice It is also the input to the extraction pipeline. A jurisdiction run starts from a seed address record in this shape, and the parsed form is produced by the mapping scripts rather than assumed. ## Properties | Property | Type | Definition | | --- | --- | --- | | `full_address` | `string` | The street address of the property including street number, street name, city, and state and postal code. Format: '123 Main, Springfield, IL' or '456 Oak Ave, Chicago, IL 1003'. | | `latitude` | `number | null` | Latitude is a coordinate that specifies the north-south position of a point on the Earth's surface. It is an angular measurement, usually expressed in degrees, with values ranging from -90° at the South Pole to +90° at the North Pole. | | `longitude` | `number | null` | Longitude is a coordinate that specifies the east-west position of a point on the Earth's surface. It is an angular measurement, usually expressed in degrees, with values ranging from -180° to +180°. | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `entry_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `county_jurisdiction` | `string` | The name of the county or local jurisdiction that has authority over the property for tax assessment and administrative purposes. Should not include the word 'County' in the value. `Dallas``Miami Dade``Broward``Palm Beach``Lee``Hillsborough``Orange``Pinellas``Polk``Duval``Brevard``Pasco``Volusia``Sarasota``Collier``Marion``Manatee``Charlotte``Lake``Osceola``St. Lucie``Seminole``Escambia``St. Johns``Citrus``Bay``Santa Rosa``Hernando``Okaloosa``Highlands``Leon``Alachua``Clay``Sumter``Putnam``Martin``Indian River``Walton``Monroe``Flagler``Nassau``Levy``Washington``Jackson``Suwannee``Columbia``Hendry``Okeechobee``Gadsden``Wakulla``DeSoto``Gulf``Taylor``Franklin``Dixie``Madison``Bradford``Hardee``Gilchrist``Holmes``Calhoun``Hamilton``Baker``Jefferson``Glades``Lafayette``Union``Liberty``Fort Bend``Collin``Allegheny``Hunt``Wood``Burnet``San Patricio``Wise``Nacogdoches``Waller``Cherokee``Navarro``Medina``Alameda``Alpine``Amador``Butte``Calaveras``Colusa``Contra Costa``Del Norte``El Dorado``Fresno``Glenn``Humboldt``Imperial``Inyo``Kern``Kings``Lake``Lassen``Los Angeles``Madera``Marin``Mariposa``Mendocino``Merced``Modoc``Mono``Monterey``Napa``Nevada``Orange``Placer``Plumas``Riverside``Sacramento``San Benito``San Bernardino``San Diego``San Francisco``San Joaquin``San Luis Obispo``San Mateo``Santa Barbara``Santa Clara``Santa Cruz``Shasta``Sierra``Siskiyou``Solano``Sonoma``Stanislaus``Sutter``Tehama``Trinity``Tulare``Tuolumne``Ventura``Yolo``Yuba``Ellis` | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # utility # utility The systems serving the property: heating, cooling, water, sewer, electrical, and the energy features recorded against them. The question it answers ## What is this house, physically? The feature vector, taken from the source of record rather than from a listing agent. Assessor and parcel records are authoritative; listing fields are agent-entered, inconsistent between markets, and absent entirely for a property that was never listed. Other classes answering this question ## Why it matters The utility set is a cost and a risk. Well and septic rather than municipal water and sewer changes the carrying cost, the inspection requirements and the financeability; an ageing heating system is a near-term capital call. The source dictionary carries no definition for this class. ## In practice The extraction is one of the five scripts written per jurisdiction, because utility recording is where county formats diverge most — the same heating configuration appears as a code in one county, a free-text description in the next, and a set of separate indicator fields in a third. ## Properties | Property | Type | Definition | | --- | --- | --- | | `source_http_request` | `object` | HTTP request configuration for retrieving this data. | | `request_identifier` | `string | null` | Identifier value that should be substituted into the source HTTP request to retrieve this specific data. | | `cooling_system_type` | `string | null` | Refers to the type of cooling system used in the structure. `CeilingFans``Electric``Ductless``Hybrid``CentralAir``WindowAirConditioner``WholeHouseFan``CeilingFan``GeothermalCooling``Zoned` | | `heating_system_type` | `string | null` | Refers to the type of heating system used in the structure. `ElectricFurnace``Electric``GasFurnace``Ductless``Radiant``Solar``HeatPump``Central``Baseboard``Gas` | | `heating_fuel_type` | `string | null` | Primary energy source used by the heating system. `Electric``NaturalGas``Propane``Oil``Kerosene``WoodPellet``Wood``Geothermal``Solar``DistrictSteam``Other` | | `public_utility_type` | `string | null` | Refers to the type of public utility available to a structure. `WaterAvailable``ElectricityAvailable``SewerAvailable``NaturalGasAvailable``CableAvailable``UndergroundUtilities` | | `sewer_type` | `string | null` | Refers to the type of sewer used in the structure. `Sanitary``Public``Combined``Septic` | | `water_source_type` | `string | null` | Refers to the type of water source used in the structure. `Well``Aquifer``Public` | | `plumbing_system_type` | `string | null` | Refers to the type of plumbing system used in the structure. `Copper``PEX``PVC``GalvanizedSteel``CastIron` | | `plumbing_system_type_other_description` | `string | null` | A free-form field to capture detail when Other is selected for the plumbing system type. | | `plumbing_fixture_count` | `integer | null` | Total number of plumbing fixtures installed in the property (e.g., toilets, sinks, urinals, floor drains) | | `plumbing_fixture_type_primary` | `string | null` | Primary type of plumbing fixture. Use 'Mixed' for properties with multiple fixture types. `Toilet``Sink``Urinal``FloorDrain``ServiceSink``UtilitySink``WaterFountain``HoseBib``ShowerHead``Bathtub``Dishwasher``WashingMachine``Mixed``Other` | | `plumbing_fixture_quality` | `string | null` | Overall quality level of plumbing fixtures `Economy``Standard``Fair``Good``Excellent``Luxury` | | `electrical_panel_capacity` | `string | null` | Describes the amperage or capacity of the electrical panel, e.g. '100 Amp', '200 Amp'. | | `electrical_wiring_type` | `string | null` | Specifies the type of electrical wiring used in the structure. `Copper``Aluminum``KnobAndTube` | | `hvac_condensing_unit_present` | `string | null` | Indicates if an HVAC condensing unit is present, as visible externally. | | `electrical_wiring_type_other_description` | `string | null` | A free-form field for describing the electrical wiring type if Other is selected. | | `solar_panel_present` | `boolean` | Indicates whether solar panels are installed on the structure. | | `solar_panel_type` | `string | null` | Specifies the type of solar panel system. `Photovoltaic``SolarThermal``Hybrid` | | `solar_panel_type_other_description` | `string | null` | A free-form field to describe the solar panel system when Other is selected. | | `smart_home_features` | `array | null` | List of smart home features installed in the property. | | `smart_home_features_other_description` | `string | null` | Free-form description if any smart home features are not covered by the predefined list. | | `hvac_unit_condition` | `string | null` | Visible exterior condition of the HVAC condensing unit, if present. `New``Good``Rusty``Leaking``Damaged` | | `solar_inverter_visible` | `boolean` | Whether a solar inverter box is visible on exterior or utility closet. | | `hvac_unit_issues` | `string | null` | Visual indicators of HVAC or external unit deterioration. `RustyUnit``LeakingPipes``MissingGrilles``ObstructedVent``WornFanHousing` | | `hvac_installation_date` | `string | null` | Date HVAC equipment was installed/replaced (MEC). | | `electrical_panel_installation_date` | `string | null` | Date main service panel was installed/upgraded (ELE). | | `electrical_rewire_date` | `string | null` | Date of significant rewire (ELE). | | `plumbing_system_installation_date` | `string | null` | Date supply/drain system was installed/replaced (PLU). | | `water_heater_installation_date` | `string | null` | Date water heater was installed/replaced (PLU/BLD). | | `solar_installation_date` | `string | null` | Date solar system was installed (SOL). | | `solar_inverter_installation_date` | `string | null` | Date solar inverter was installed/replaced (SOL). | | `well_installation_date` | `string | null` | Date well was installed (WEL/NRP). | | `sewer_connection_date` | `string | null` | Date property connected to public sewer (LCU/LWS/PLU). | | `water_connection_date` | `string | null` | Date property connected to public water (LCU/LWS/PLU). | | `hvac_system_configuration` | `string | null` | HVAC configuration type. `SplitSystem``PackagedUnit``MiniSplit``HeatPumpSplit``VRF``Other` | | `hvac_equipment_component` | `string | null` | HVAC component this record describes. `Condenser``AirHandler``CondenserAndAirHandler``PackageUnit``HeatPump``Other` | | `hvac_capacity_kw` | `number | null` | Nameplate electrical capacity (kW) of the HVAC equipment. | | `hvac_capacity_tons` | `number | null` | Cooling capacity in tons. | | `hvac_seer_rating` | `number | null` | Seasonal Energy Efficiency Ratio (SEER). | | `hvac_equipment_manufacturer` | `string | null` | Manufacturer of HVAC equipment. | | `hvac_equipment_model` | `string | null` | Model number of HVAC equipment. | | `water_heater_manufacturer` | `string | null` | Manufacturer of water heater. | | `water_heater_model` | `string | null` | Model number of water heater. | | `solar_inverter_manufacturer` | `string | null` | Manufacturer of solar inverter. | | `solar_inverter_model` | `string | null` | Model number of solar inverter. | ## Provenance and coverage A record of this class is validated against the same definition whatever jurisdiction it came from, which is what makes two counties comparable without a per-county adapter. A jurisdiction appears below only where a committed configuration serves this class's surface. - Lee, Florida - Palm Beach, Florida - Miami-Dade, Florida - Orange, Florida - Santa Clara, California How a new jurisdiction is brought online --- # Delivery # Delivery The delivery platform: how software is built, assessed, deployed, published and kept compliant. Two categories. Shipping is the pipeline — repository operations, the rule engine over infrastructure definitions, the build, the deployment, the compliance stage, and the orchestration that runs them in order. Distribution is what happens to the result: catalogues, environments, identity, metering and hosting. Every stage has an API rather than a script, so a configuration bundle generated by a machine can be committed, assessed, built, deployed and published by the same calls a person would use. - Access - Assess - Build - Code - Comply - Console - Deploy - Environment - Finance - Health - Host - Marketplace - Pipeline - Setup --- # Distribution # Distribution What happens to a build: catalogues, environments, identity, metering, hosting and self-service setup. What happens to a build before somebody can call it? Distribution covers everything between a built bundle and a running product in somebody's account. The catalogue publishes bundles and resolves what they depend on; environments are whole cloud accounts created, budgeted and destroyed over HTTP; identity issues the keys every call is authorised by; metering counts what was called, against the same identifier the endpoint definition already carries. Two products here exist for cases the others do not cover. Hosting installs a vendor's own engine inside a customer's account for data that cannot leave it, and setup carries the fixed sequence that creates an account and its first environment as one step. ## Products In the order the value chain runs. 1. Access has a recorded specification 1. Console has a recorded specification 1. Environment has a recorded specification 1. Finance has a recorded specification 1. Host has a recorded specification 1. Marketplace has a recorded specification 1. Setup has a recorded specification --- # Access # Access Identity, single sign-on, API-key issuance and credential storage, with a stated boundary on who can reach a customer environment. All product access control is by API key, and every environment has one. Access creates and manages the root identity that owns a company, the user identities belonging to its organisations, organisation parameters and credentials, the credentials a lender supplies for its own vendor accounts, and key rotation. Rotating a key takes two factors: the organisation owner's identity and the current key. ## How it works Storage is split by what is being stored. API keys are held encrypted; user identities and their credentials sit in the managed identity service rather than in any product's own database. User identity is two-factor. No API access is held into a customer's environment, with Health as the single exception, and nobody reaches an environment through the console. The boundary is stated in the design notes rather than implied. Temporary maintenance access is possible and costs four independent factors: the environment's API key, a user identity, an approval from the security officer, and an approval from the organisation's own owner. The route runs through Comply, which issues the credential after the environment owner approves the request by email. Product dependencies are expected to sit in the same environment, so a call does not cross an environment boundary to authenticate. Four products are the stated exceptions, because they are the ones that operate on environments rather than inside one. ## Operations ### Account Partner Schema `DELETE` `/` #### Delete Partner Schema `delete_partner_schema` This service manages the deletion of a partner schema. ##### Request application/json Copy . ``` { "partner": "foopartner", "product": "barproduct", "schema": { "price": 32, "product_name": "apple" } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `partner`required | `string` | The name of the partner.Example `foopartner` | | `product`required | `string` | The name of the product.Example `barproduct` | ##### Response `200``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ##### Response `404``application/json` 1 fields 409 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | `POST` `/` #### Create Partner Schema `create_partner_schema` This service manages the creation of a partner schema. ##### Request application/json Copy . ``` { "partner": "foopartner", "product": "barproduct", "schema": { "price": 32, "product_name": "apple" } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `partner`required | `string` | The name of the partner.Example `foopartner` | | `product`required | `string` | The name of the product.Example `barproduct` | | `schema`required | `object` | The JSON schema. | ##### Response `201``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ##### Response `409``application/json` 1 fields 409 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | `PUT` `/` #### Update Partner Schema `update_partner_schema` This service manages the update of a partner schema. ##### Request application/json Copy . ``` { "partner": "foopartner", "product": "barproduct", "schema": { "price": 32, "product_name": "apple" } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `partner`required | `string` | The name of the partner.Example `foopartner` | | `product`required | `string` | The name of the product.Example `barproduct` | | `schema`required | `object` | The JSON schema. | ##### Response `200``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ##### Response `404``application/json` 1 fields 409 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message with details. | ### Company Organization `GET` `/` #### Retrieve Company Organization List `retrieve-company-organization-list` This service retrieves company organization list. ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `company_name` | `string` query | `Amazon` | Company name | | `organization_name` | `string` query | `Amazon Web Services` | Organization name | ##### Response `200``application/json` 1 fields Successful Company Organization List Retrieve. | Field | Type | Description | | --- | --- | --- | | `company_organization_list` | `object[]` | Company organization list | | `organization_id` | `string` | Organization ID | | `company_name` | `string` | Company name | | `organization_name` | `string` | Organization name | ##### Other responses `400``403` `GET` `/{organization_id}` #### Retrieve Company Organization `retrieve-company-organization` This service retrieves company organization. ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `organization_id` required | `string` path | `fxfxfxfx-fxfx-fxfx-fxfx-fxfxfxfxfxfx` | Organization ID | ##### Response `200``application/json` 1 fields Successful Company Organization Retrieve. | Field | Type | Description | | --- | --- | --- | | `company_organization` | `object` | Company organization object | | `organization_id` | `string` | Organization ID | | `company_name` | `string` | Company name | | `organization_name` | `string` | Organization name | ##### Other responses `400``403``404` ### Access Invitations `POST` `/{application_name}/invitations` #### Invite User `inviteUser` Invites a new user. Invitation will redirect user to the provided URL on acceptance. Upon acceptance, the user will be redirected to the provided URL with a fragment parameters: `staircase_product=Access` `action=ACCEPT_INVITATION` and `result` containing on of the following values: - `ACCEPTED`,- User accepted the invitation - `BAD_REQUEST`,- Bad request, one of the required parameters is missing - `UNKNOWN_ERROR`,- Unknown error occurred - `INVITATION_NOT_FOUND`,- Invitation not found. Could be expired or invalid code - `INVITATION_NOT_VALID`,- Invitation not valid. Could be already accepted or expired - `INTERNAL_SERVER_ERROR`,- Internal server error occurred The invitation URL will be valid for 1 month. ##### Request application/json Copy ``` { "email": "johndoe@email.com", "redirect_url": "https://webhook.site/d9b8f770-38c2-4584-8944-0b7194d203e8?guid=123" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK Response ``` [ { "email": "johndoe@email.com", "invitation_url": "https://cerf-dev.staircaseapi.com/access/invitation-accept?code=c6d0b273-5dd1-4819-9dd0-00e109a31723&redirect_url=https%3A//webhook.site/d9b8f770-38c2-4584-8944-0b7194d203e8%3Fguid%3D123" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `redirect_url` | `string` | URL to redirect user on invitation acceptance.Example `https://webhook.site/d9b8f770-38c2-4584-8944-0b7194d203e8?guid=123` | ##### Response `201``application/json` 2 fields OK Response | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `invitation_url` | `string` | URL to confirm the invitation.Example `https://cerf-dev.staircaseapi.com/access/invitation-accept?code=c6d0b273-5dd1-4819-9dd0-00e109a31723&redirect_url=https%3A//webhook.site/d9b8f770-38c2-4584-8944-0b7194d203e8%3Fguid%3D123` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `409``application/json` 1 fields Email already registered | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `404` ### Access Authorization `POST` `/{application_name}/login` #### Access login `getUserToken` Access login enables you to use your credentials to retrieve a valid access_token, id_token, token_type, refresh_token. X-API-KEY is not required for this endpoint. ##### Request application/json Copy ``` { "email": "johndoe@email.com", "password": "" } ``` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "refresh_token": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "id_token": "", "access_token": "", "token_type": "Bearer", "expires_in": "86400" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `password` | `string (password)` | User password.Example `` | ##### Response `200``application/json` 5 fields OK response | Field | Type | Description | | --- | --- | --- | | `refresh_token` | `string` | The refresh token.Example `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | | `id_token` | `string` | Temporary id token obtained.Example `` | | `access_token` | `string` | Temporary access token obtained.Example `` | | `token_type` | `string` | The token type.Example `Bearer` | | `expires_in` | `string` | The expiration period of the authentication result in seconds.Example `Bearer ` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `POST` `/{application_name}/resend-activation` #### Resend activation email `resendActivation` This endpoint enables you to resend email to activate your account in case you didn't receive it from the first time. X-API-KEY is not required for this endpoint. ##### Request application/json Copy ``` { "email": "johndoe@email.com" } ``` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "message": "Activation email is resented" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Resented successfully.Example `Activation email is resented` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User already confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `POST` `/{application_name}/change-password` #### Change password `changePassword` Change user password using access token. Access token can be received by this endpoint Access Login. Important Note, this endpoint does not work with SSO users. X-API-KEY is not required for this endpoint. ##### Request application/json Copy ``` { "old_password": "164f8UY=oj!", "new_password": "154fFV0=091" } ``` ##### Response 201400 application/json400 text/html application/json Copy Password changed ``` [ { "message": "Password has been successfully changed" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `Authorization` required | `string` header | `` | Authorization token, obtained login service. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `old_password` | `string` | Current user password.Example `164f8UY=oj!` | | `new_password` | `string` | New user password.Example `164f8UY=oj!` | ##### Response `201``application/json` 1 fields Password changed | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Password changedExample `Password has been successfully changed` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `POST` `/{application_name}/sign-out` #### Sign out `signOut` Proceed user sign out using access token. Access token can be received by this endpoint Access Login. X-API-KEY is not required for this endpoint. ##### Response 201400 application/json400 text/html application/json Copy Sign out ``` [ { "message": "Sign out succeeded" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `Authorization` required | `string` header | `` | Authorization token, obtained login service. | ##### Response `201``application/json` 1 fields Sign out | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Password changedExample `Sign out succeeded` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `GET` `/{application_name}/sign-out-by-cookie` #### Sign out by cookie `signOutByCookie` This endpoint is meant to be visited by the user directly and should not be used with XHR requests. When accessed properly, the user will be correctly redirected, and all their tokens will be invalidated. This endpoint allows users to sign out using their access token stored in cookies. Access Token Cookie: __sc.acact ID Token Cookie: __sc.acidt Important Notes Do Not Use with XHR Requests: This endpoint is designed for direct user interaction and should not be accessed through XHR requests. Token Invalidation: Upon successful logout, all user tokens will be invalidated. Redirection: If the logout is successful, the user will be redirected to the specified logout_uri. If the logout fails, the user will be redirected to the redirected_uri. Usage Ensure Cookies Are Set: The following cookies must be present: __sc.acact (Access Token) __sc.acidt (ID Token) Access Token: Can be received from the Access Login endpoint. No X-API-KEY Required: This endpoint does not require the X-API-KEY header. ##### Response 302400 application/json400 text/html application/json Copy Sign out ``` [ { "message": "Sign out succeeded" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | ##### Response `302``application/json` 1 fields Sign out | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Password changedExample `Sign out succeeded` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `POST` `/{application_name}/forgot-password` #### Forgot password `forgotPassword` Forgot password endpoint sends link on user's email address to reset password. Important Note, this endpoint does not work with SSO users. X-API-KEY is not required for this endpoint. ##### Request application/json Copy ``` { "email": "johndoe@email.com" } ``` ##### Response 202400 application/json400 text/html application/json Copy Forgot password ``` [ { "message": "Email sent" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | ##### Response `202``application/json` 1 fields Forgot password | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Password changedExample `Email sent` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `404` `POST` `/{application_name}/confirm-code` #### Confirm forgot password `confirmForgotPassword` Confirm forgot password endpoint change user password using confirmation code retrieved by Forgot password. Important Note, this endpoint does not work with SSO users. X-API-KEY is not required for this endpoint. ##### Request application/json Copy ``` { "email": "johndoe@email.com", "confirmation_code": "255252", "new_password": "P@ssword" } ``` ##### Response 200400 application/json400 text/html application/json Copy Confirm forgot password ``` [ { "message": "Password changed" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `confirmation_code` | `string` | Code retrieved by email.Example `255252` | | `new_password` | `string` | New user password.Example `P@ssword` | ##### Response `200``application/json` 1 fields Confirm forgot password | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Password changedExample `Password changed` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `404` `POST` `/{application_name}/refresh-token` #### Refresh Token `refreshToken` Refresh Token allows you to refresh access token. X-API-KEY is not required for this endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "id_token": "", "access_token": "", "token_type": "Bearer", "expires_in": "86400" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `Authorization` required | `string` header | `` | Refresh token, obtained by login service. | ##### Response `200``application/json` 4 fields OK response | Field | Type | Description | | --- | --- | --- | | `id_token` | `string` | Temporary id token obtained.Example `` | | `access_token` | `string` | Temporary access token obtained.Example `` | | `token_type` | `string` | The token type.Example `Bearer` | | `expires_in` | `string` | The expiration period of the authentication result in seconds.Example `Bearer ` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `POST` `/{application_name}/validate-token` #### Validate Access Token `validateAccessToken` Validate Access Token endpoint. X-API-KEY is not required for this endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK response ``` { "message": "Token is valid" } ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `Authorization` required | `string` header | `` | Access token, obtained by login service. | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message.Example `Token is valid` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` ### Access User `POST` `/{application_name}/users` #### Create User `createUser` Creates a new user. X-API-KEY is not required for this endpoint. This endpoint will create a new user and send a confirmation email to the user. Before creating a new user, user can be invited using the invitation endpoint. If invitation was accepted, the user will be created and confirmed automatically. ##### Request application/json Copy ``` { "email": "johndoe@email.com", "password": "" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK Response ``` [ { "id": "978412689485", "email": "johndoe@email.com", "status": "CONFIRMED" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `password` | `string (password)` | Password for the new user.Example `` | ##### Response `201``application/json` 3 fields OK Response | Field | Type | Description | | --- | --- | --- | | `id` | `string` | User id.Example `64564689894561` | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `status` | `string` | Status of the user CONFIRMED or UNCONFIRMED.`CONFIRMED``UNCONFIRMED`Example `CONFIRMED` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields Email already registered | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/users` #### List users `listUserInfo` List Users Info List users information by email. In case query parameter has some special characters such '+' or '/' it must be encoded. X-API-KEY is not required for this endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK Response ``` [ { "users": [ { "id": "f5fa64a9-51b6-41c3-b22e-fd8d7b1dadb2", "email": "example@email.com", "user_creation_date": "2023-10-13T11:32:06.637000+00:00", "user_last_modified_date": "2023-10-13T11:57:36.835000+00:00", "person_identifier": "01H84EDXPD3PBH21DGDQFZP06Y", "company_identifier": "01HCHKS73ME9A9W7XGDTX9Z9PC", "status": "CONFIRMED" } ], "next_token": null } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `email` | `string (email)` query | `example@email.com` | User email to query. | | `next_token` | `string` query | `CAISqQIIARKCAggDEv0BAAzZDJsxrI3ydVKVDZyI4WtUDKZt1d0R6fu+3POnqFCKeyJAbiI6IlBhZ2luYXRpb25Db250aW51YXRpb25EVE8iLCJuZXh0S2V5IjoiQUFBQUFBQUFBcnhoQVFFQmNFZEVNcVZrUzFDV1ZtWTlyYjM4NEsxM0VnY2psRW5VdXhNL3hqbFR0dHRsYm1ZN05qSm1aV1ZoWm1ZdE0yUXdNUzAwTTJOa0xXSTBabVV0WlRoa04yRTFPRFF3TXpkbE93PT0iLCJwYWdpbmF0aW9uRGVwdGgiOjI1LCJwcmV2aW91c1JlcXVlc3RUaW1lIjoxNjk4MjE5OTIxNDE2fRogIRzi3AAH44NsO9VRPe6wxirYfEjiup4H6OAJ2P6ULL8=` | next_token. | ##### Response `200``application/json` 2 fields OK Response | Field | Type | Description | | --- | --- | --- | | `users` | `object[]` | Users data. | | `id` | `string` | User id.Example `64564689894561` | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `user_creation_date` | `string` | User creation date.Example `2023-10-13T11:32:06.637000+00:00` | | `user_last_modified_date` | `string` | User last modified date.Example `2023-10-13T11:32:06.637000+00:00` | | `person_identifier` | `string` | Staircase global person ID.Example `01GYCBKPSMTJYJR1PG9JS37FTE` | | `company_identifier` | `string` | Staircase global company ID.Example `01GYCBKPSMTJYJR1PG9JS37FTE` | | `status` | `string` | Status of the user.Example `CONFIRMED` | | `next_token` | `string` | next_token. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/{application_name}/users/{user_id}` #### Get User `getUser` Get user endpoint. X-API-KEY is not required for this endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK Response ``` [ { "id": "978412689485", "email": "johndoe@email.com", "person_identifier": "01GYCBKPSMTJYJR1PG9JS37FTE", "company_identifier": null, "status": "CONFIRMED" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name. | | `user_id` required | `string` path | `856451298456123` | User id to query. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Response `200``application/json` 5 fields OK Response | Field | Type | Description | | --- | --- | --- | | `id` | `string` | User id.Example `64564689894561` | | `email` | `string (email)` | Email of the user.Example `johndoe@email.com` | | `person_identifier` | `string` | Staircase global person ID.Example `01GYCBKPSMTJYJR1PG9JS37FTE` | | `company_identifier` | `string` | Staircase global company ID.Example `01GYCBKPSMTJYJR1PG9JS37FTE` | | `status` | `string` | Status of the user.Example `CONFIRMED` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `GET` `/user-info` #### Get User Info `getUserInfo` Get user information using access token. Access token can be received by this endpoint Access Login. X-API-KEY is not required for this endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK Response ``` [ { "communications": [ { "@id": "01GZP2AQ2JKPZXSXMJ1CA4TD3N", "@type": "person", "domain_name": "email.co", "website": "staircase.co" }, { "@id": "01GZP2AQ2JKPZXSXMJ1CA4TD3N", "@type": "person", "email_address": "email@example.com" } ], "companies": [ { "@id": "01H1XQHK0WWMX23XDX1GX3MCKR", "@type": "company", "company_identifier": "27374737", "has_communication_method": "01GZP2AQ2JKPZXSXMJ1CA4TD3N", "name": "Staircase Company" } ], "people": [ { "@id": "01GZP2AQ2JKPZXSXMJ1CA4TD3N", "@type": "person", "has_communication_method": "01GZP2AQ2JKPZXSXMJ1CA4TD3N", "person_identifier": "112557303379029896330" } ] } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Authorization token, obtained by login service. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``204``401``404` ### Access Applications `GET` `/applications` #### List applications `listApplications` List Applications List applications endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK Response ``` { "result": [ { "application_name": "test-user-pool-client-comply", "redirect_uri": "https://test.test.com/access/callback", "logout_uri": "https://test.test.com/access/callback" } ] } ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Response `200``application/json` 1 fields OK Response | Field | Type | Description | | --- | --- | --- | | `result` | `object[]` | Array of applications | | `application_name` | `string` | Application name.Example `access` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `404``application/json` 1 fields Application not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `POST` `/applications` #### Create application `createApplication` Create Application Creates a new application. ##### Request application/json Copy ``` { "application_name": "access", "redirect_uri": "https://test.test.com/access/callback" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK Response ``` [ { "message": "Application access created successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `application_name`required | `string` | Application name.Example `access` | | `redirect_uri`required | `string` | Redirect_uri.Example `https://test.test.com/access/callback` | | `logout_uri` | `string` | Logout_uri.Example `https://test.test.com/access/callback` | ##### Response `201``application/json` 1 fields OK Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message.Example `Application access created successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `PUT` `/applications/{application_name}` #### Update application `updateApplication` Update Application Updates existing application. ##### Request application/json Copy ``` { "application_name": "access", "redirect_uri": "https://test.test.com/access/callback" } ``` ##### Response 201400 application/json400 text/html404 application/json Copy OK Response ``` [ { "message": "Application access updated successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy App not found ``` [ { "error": "Application access not found" } ] ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name to delete. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `redirect_uri`required | `string` | Redirect_uri.Example `https://test.test.com/access/callback` | | `logout_uri` | `string` | Logout_uri.Example `https://test.test.com/access/callback` | ##### Response `201``application/json` 1 fields OK Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message.Example `Application access created successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields App not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/applications/{application_name}` #### Get Application `getApplication` Get application endpoint. ##### Response 200400 application/json400 text/html application/json Copy OK Response ``` [ { "application_name": "access", "redirect_uri": "https://test.test.com/access/callback", "logout_uri": "https://test.test.com/access/callback" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name to get. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Response `200``application/json` 3 fields OK Response | Field | Type | Description | | --- | --- | --- | | `application_name` | `string` | Application name.Example `access` | | `redirect_uri` | `string` | Redirect_uri.Example `https://test.test.com/access/callback` | | `logout_uri` | `string` | Logout_uri.Example `https://test.test.com/access/callback` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Application not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `DELETE` `/applications/{application_name}` #### Delete Application `deleteApplication` Delete application endpoint. ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `application_name` required | `string` path | `access` | Application name to delete. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Application not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204` ### Authorization `POST` `/authorize` #### Authorization `authorization` Makes an authorization decision about a service request described in the parameters. The decision is based on the policies stored in the policy store. ##### Request application/json Copy ``` { "policy_store_id": "DxK7hSQRzYWoCGSeumNvm", "principal": { "entityType": "ExampleCo::Loan::Borrower", "entityId": "Steve" }, "action": { "actionType": "ExampleCo::Loan::Action", "actionId": "GetListingInfo" }, "resource": { "entityType": "ExampleCo::Loan::Listing", "entityId": "12345" } } ``` ##### Response 200400404 application/json Copy Successfully authorized. ``` { "decision": "ALLOW", "determining_policies": [ { "policyId": "WVKdXE7dNDJNRXYVAdCJmd" } ], "errors": [] } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `policy_store_id`required | `string` | ID of the policy store.Example `Dc3v9eLa2UbfCrw6wrkcmK` | | `principal` | `object` | Principal of the policy. | | `entityType`required | `string` | Entity type of the principal.Example `loan::borrower` | | `entityId`required | `string` | Entity ID of the principal.Example `john` | | `action` | `object` | Action of the policy. | | `actionType`required | `string` | Type of the action.Example `loan::Action` | | `actionId`required | `string` | ID of the action.Example `GetListingInfo` | | `resource` | `object` | Resource of the policy. | | `entityType`required | `string` | Entity type of the resource.Example `loan::preapprovallist` | | `entityId`required | `string` | Entity ID of the resource.Example `johnlist` | ##### Response `200``application/json` 3 fields Successfully authorized. | Field | Type | Description | | --- | --- | --- | | `decision`required | `string` | Decision of the authorization.`ALLOW``DENY` | | `determining_policies`required | `object[]` | The list of determining policies used to make the authorization decision. | | `errors`required | `string[]` | Errors that occurred while making an authorization decision. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Site Logs Configurations `POST` `/configurations` #### Save Configuration `saveConfiguration` ##### Request application/json Copy ``` { "configuration_id": "8237fc96-0d4a-484c-b2e3-ffd0f800eae1" } ``` ##### Response 200400404 application/json Copy Success response ``` { "foo": "bar" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `configuration_id`required | `string` | Simple Site Configuration IDExample `8237fc96-0d4a-484c-b2e3-ffd0f800eae1` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200` `GET` `/configurations` #### List Configurations `listConfigurations` ##### Response 200400404 application/json Copy List Configurations ``` { "domain_name": "abc.cloudfront.net", "configuration_id": "8237fc96-0d4a-484c-xx-xxx", "distribution_id": "E23M6IP4FJ0xxxx" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Response `200``application/json` 3 fields List Configurations | Field | Type | Description | | --- | --- | --- | | `domain_name` | `string` | Domain NameExample `foo` | | `configuration_id` | `string` | Configuration IDExample `configuration-id` | | `distribution_id` | `string` | Distribution IDExample `distribution-id` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Account configurations `POST` `/create-configurations` #### Create Configurations `store_new_environment_configurations` Configurations are used to change a product behavior for one or multiple customers' accounts, this will enable Staircase default configurations, and the customer can change as needed in his account. The account data bundle enables the customer environment with Staircase default configurations for products like Suite. Example of configurations: - Allow multiple registration = true|false - Borrower flow enabled = true|false - Data manager flow enabled = true|false ##### Request Example configurationExample without environment application/json Copy . ``` { "environment": "account.staircaseapi.com", "product": "myProduct", "configurations": [ { "key": "server_domain", "value": "myserver.com" }, { "key": "server_key", "value": "fxfxfxfxfxfx" } ] } ``` application/json Copy . ``` { "product": "myProduct", "configurations": [ { "key": "server_domain", "value": "myserver.com" }, { "key": "server_key", "value": "fxfxfxfxfxfx" } ] } ``` ##### Response 201400409500 application/json Copy 201 response. ``` { "message": "Configurations were created successfully." } ``` application/json Copy 400 response. ``` { "message": "Invalid body JSON." } ``` application/json Copy 409 response. ``` { "message": "This resource was already previously created. Please, use the update endpoint." } ``` application/json Copy 500 response. ``` { "message": "Internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `environment` | `string` | The environment hosts.Example `account.staircaseapi.com` | | `product`required | `string` | The product to be configured.Example `newProduct` | | `configurations` | `object[]` | The product configurations. | | `key` | `string` | Key | | `value` | `string` | Key | ##### Response `201``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configurations were created successfully. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Invalid body JSON. | ##### Response `409``application/json` 1 fields 409 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The resource was already previously created. | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | `GET` `/retrieve-configurations` #### Retrieve Configurations `retrieve_configurations` This service retrieves configurations from a product and/or environment. If no query string parameters are passed then the response should contain configurations that have been registered. Configurations from master environment registered will be retrieved as well, all global and local credentials for the given inputs. ##### Response 200400404500 application/json Copy 200 response. ``` [ { "environment": "account.staircaseapi.com", "product": "myProduct", "is_local": true, "created_at": "2011-10-05T14:48:00.000", "updated_at": "2011-10-05T14:48:00.000", "created_by_environment": "account.staircaseapi.com", "configurations": [ { "key": "server_domain", "value": "myserver.com" }, { "key": "server_key", "value": "fxfxfxfxfxfx" } ] }, { "environment": "test.staircaseapi.com", "product": "myProduct", "is_local": false, "created_at": "2011-10-05T14:48:00.000", "updated_at": "2011-10-05T14:48:00.000", "created_by_environment": "test.staircaseapi.com", "configurations": [ { "key": "ttl", "value": 20 } ] } ] ``` application/json Copy 400 response. ``` { "message": "\"Invalid json body.\"" } ``` application/json Copy 404 response. ``` { "message": "No one configurations were found." } ``` application/json Copy 500 response. ``` { "message": "Internal server error" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | | `environment` | `string` query | `account.staircaseapi.com` | The environment host, configurations without environment will be retrieved if this filter is not input. | | `product` | `string` query | `newService` | Product to retrieve configurations. | ##### Response `200``application/json` 7 fields 200 response. | Field | Type | Description | | --- | --- | --- | | `environment` | `string` | The environment hosts.Example `account.staircaseapi.com` | | `product` | `string` | The product to be configured.Example `newProduct` | | `created_at` | `string` | Date that it was created.Example `2011-10-05T14:48:00.000` | | `updated_at` | `string` | Date that it was updated.Example `2011-10-05T14:48:00.000` | | `created_by_environment` | `string` | Name of environment responsible to create it.Example `2011-10-05T14:48:00.000` | | `is_local` | `boolean` | Indicates if the configuration was created by the local environment.Example `true` | | `configurations` | `object[]` | The product configurations. | | `key` | `string` | — | | `value` | `—` | — | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `404``application/json` 1 fields 404 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | `PUT` `/update-configurations` #### Update Configurations `update_environment_configurations` This service update product configurations. Configurations are used to change a product behavior. ##### Request Example configurationExample without environment application/json Copy . ``` { "environment": "account.staircaseapi.com", "product": "myProduct", "configurations": [ { "key": "server_domain", "value": "myserver.com" }, { "key": "server_key", "value": "fxfxfxfxfxfx" } ] } ``` application/json Copy . ``` { "product": "myProduct", "configurations": [ { "key": "server_domain", "value": "myserver.com" }, { "key": "server_key", "value": "fxfxfxfxfxfx" } ] } ``` ##### Response 201400404500 application/json Copy 201 response. ``` { "message": "Configurations were updated successfully." } ``` application/json Copy 400 response. ``` { "message": "Invalid body JSON." } ``` application/json Copy 404 response. ``` { "message": "No one local resource was found." } ``` application/json Copy 500 response. ``` { "message": "Internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `environment` | `string` | The environment hosts.Example `account.staircaseapi.com` | | `product`required | `string` | The product to be configured.Example `newProduct` | | `configurations` | `object[]` | The product configurations. | | `key` | `string` | Key | | `value` | `string` | Value | ##### Response `201``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configurations were updated successfully. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Invalid body JSON. | ##### Response `404``application/json` 1 fields 404 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | `DELETE` `/delete-configurations` #### Delete Configurations `delete_environment_configurations` This service delete product configurations. Configurations are used to change a product behavior. ##### Response 200400404500 application/json Copy 201 response. ``` { "message": "Configurations were deleted successfully." } ``` application/json Copy 400 response. ``` { "message": "Invalid body JSON." } ``` application/json Copy 404 response. ``` { "message": "No one configurations were found." } ``` application/json Copy 500 response ``` { "message": "Internal server error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `product` required | `string` query | `myProduct` | Product | | `environment` | `string` query | `account.staircaseapi.com` | Product | ##### Response `200``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configurations were deleted successfully. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Invalid body JSON. | ##### Response `404``application/json` 1 fields 404 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `500``application/json` 1 fields 500 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ### Customer `POST` `/create-customer` #### Create Customer ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Content-Type` required | `string` header | `application/json` | Content Type | `GET` `/retrieve-customer` #### Retrieve Customer ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Content-Type` required | `string` header | `application/json` | Content Type | | `customer_id` | `string` query | `ba4e8f60-f259-11eb-9a03-0242ac130003` | — | | `email` | `string` query | `customer@domain.com` | — | ### Account Partner `POST` `/credentials` #### Register Credentials `store_new_environment_credentials` This service manages data Partner Account credentials. Data partner credentials enable Staircase Mortgage products to securely connect with specific data partners. They authorize Staircase to send data partners requests and receive their responses, both of which are persisted in the customer’s dedicated account. The Account data bundle automatically registers the Marketplace environment which includes all needed configurations and credentials to start using Staircase products in the customer environment. ##### Request application/json Copy . ``` { "environment": "account.staircaseapi.com", "partner": "atomic", "type": "production", "credentials": { "login": "username", "password": "myPass" } } ``` ##### Response 201400 application/json Copy 201 response. ``` { "message": "Credentials are encrypted and stored successfully." } ``` application/json Copy 400 response. ``` { "message": "error in creating Credentials credentials is a required field and it must be an array" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `environment` | `string` | The environment hostExample `account.staircaseapi.com` | | `partner`required | `string` | Partner Account.Example `newService` | | `product` | `string` | Product account.Example `newProduct` | | `credentials`required | `object` | Partner that the credentials is used | | `type` | `string` | Type can be production, test or empty`production``test`Example `production` | ##### Response `201``application/json` 1 fields 201 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Credentials are encrypted and stored successfully. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error in creating credentials. | `POST` `/upload-certificate/{partner}` #### Upload Certificate `upload_partner_certificate` This service is used to generate a pre-signed URL to upload the partner certificate to Staircase cloud environment. The certificate will be securely stored and can be retrieved by the /retrieve-certificate endpoint Note: This will NOT upload your certificate. To upload the certificate file, you will need to issue a PUT request to the URL returned by the response body. See example, code snippet below: ``` # Upload Certificate to the presigned url import requests # For example, the presigned_url might look like this: upload_presigned_url = "" # Set the path to the file you want to upload filepath = "certificate.pfx" # Set the headers appropriately headers = { 'Content-Type': 'application/x-pkcs12' } # Read the file data and make the PUT request with open(filepath, 'rb') as file: payload = file.read response = requests.put(url=upload_presigned_url, headers=headers, data=payload) ``` ##### Request application/json Copy . ``` { "host": "account.staircaseapi.com" } ``` ##### Response 200400500 application/json Copy 200 response ``` { "message": "Pre-signed url successfully generated", "host": "my_partner_host", "type": "production", "presigned_url": "https://my_partner-certificate-bucket.s3.amazonaws.com/" } ``` application/json Copy 400 response ``` { "message": "host must exist in body" } ``` application/json Copy 500 response ``` { "message": "Internal server error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | | `partner` required | `string` path | `my_partner_name` | Partner Account. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `host`required | `string` | The environment hostExample `account.staircaseapi.com` | ##### Response `200``application/json` 3 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Pre-signed URL successfully generated. | | `host` | `string` | host | | `presigned_url` | `string` | Pre-signed URL to upload file. | ##### Response `400``application/json` 1 fields 400 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request. | ##### Response `500``application/json` 1 fields 500 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | `PUT` `/credentials` #### Update Credentials `update_new_environment_credentials` This service updates existing data partner credentials. The password provided when creating the credentials must be supplied in the request body when calling this service. ##### Request application/json Copy . ``` { "environment": "account.staircaseapi.com", "partner": "atomic", "product": "myProduct", "type": "production", "credentials": { "login": "username", "password": "" } } ``` ##### Response 200400404 application/json Copy 200 response. ``` { "message": "Credentials are encrypted and updated successfully" } ``` application/json Copy 400 response. ``` { "message": "error in creating Credentials credentials is a required field and it must be an array" } ``` application/json Copy 404 response. ``` { "message": "Credentials Not Found." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `environment` | `string` | The environment hostExample `account.staircaseapi.com` | | `partner`required | `string` | Partner that the credentials is usedExample `newService` | | `product` | `string` | Product account credentials.Example `newProduct` | | `credentials`required | `object` | Partner that the credentials is used | ##### Response `200``application/json` 1 fields 200 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Credentials are encrypted and updated successfully. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `404``application/json` 1 fields 404 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | `GET` `/retrieve-certificate/{partner}` #### Retrieve Certificate `retrieve_partner_certificate` This service is used to generate a pre-signed URL to download the partner certificate from Staircase cloud environment. The certificate is securely stored and can be uploaded by the /upload-certificate endpoint ##### Response 200400404500 application/json Copy 200 response ``` { "message": "Pre-signed URL successfully generated", "presigned_url": "https://bucket.s3.amazonaws.com/my_partner/my_partner_host.pfx?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=111111" } ``` application/json Copy 400 response ``` { "message": "The partner path must exist. Please use /{partner}?host={host}" } ``` application/json Copy 404 response ``` { "message": "Certificate not found." } ``` application/json Copy 500 response ``` { "message": "Internal server error" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `partner` required | `string` path | `my_partner_name` | Partner Account. | | `host` required | `string` query | `my_partner_host` | The host of the partner that was used to upload the certificate. | | `should_use_only_local_env` | `boolean` query | `true` | Define if it should only retrieve certificate from local environment and not master environment. (in any case, local environment has preference) | ##### Response `200``application/json` 3 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message. | | `presigned_url` | `string` | The pre-signed URL used to retrieve the partner host certificate. | | `is_certificate_from_local_env` | `boolean` | Informs if the pre-signed URL was retrieved from local environment or master environment. | ##### Response `400``application/json` 1 fields 400 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request. | ##### Response `404``application/json` 1 fields 404 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Certificate not found. | ##### Response `500``application/json` 1 fields 500 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | `DELETE` `/credentials` #### Delete Credentials `delete-delete-credentials` This service deletes all data partner and credentials that have been created for a specific environment or product locally. ##### Response 200400403404 application/json Copy 200 response ``` { "message": "Credentials are encrypted and stored successfully." } ``` application/json Copy 400 response ``` { "message": "f\"error in retrieving Credentials environment is a required field in the queryString\"" } ``` application/json Copy 403 response ``` { "message": "error in retrieving Credentials Wrong Password" } ``` application/json Copy 404 response ``` { "message": "Not Found" } ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | | `environment` | `string` query | `account.staircaseapi.com` | Environment | | `product` | `string` query | `newService` | Product to retrieve credentials. | | `partner` required | `string` query | `newService` | Partner Account. | | `type` | `string` query | `production` | Type can be production, test or empty | | `password` | `string` query | `` | Password used to encrypt the Credentials | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields 400 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `403``application/json` 1 fields 403 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `404``application/json` 1 fields 404 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ### Account Customer `POST` `/customer-accounts` #### Create Customer Account `post-customer-accounts` Create Customer Account creates your account in Staircase. After successful account creation, an email containing an API key is sent to the email address you provided. Company Organizations: Organizations help you group your accounts and environments, as you grow and scale with Staircase. Define a Company organization by going to the Add Company Organization service, after is created you can retrieve the company organization. To obtain access to Staircase APIs in the documentation environment "api.staircase.co", activate your API Key in this link. Use your activated API Key to send requests to any product in the documentation. ##### Request Create AccountCreate Account with Organization application/json Copy Creates a customer account with required fields ``` { "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "company_name": "DoeINC" } ``` application/json Copy Creates a customer account with organization ID instead of Company Name ``` { "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "organization_id": "fxfxfxfx-fxfx-fxfx-fxfx-fxfxfxfxfxfx" } ``` ##### Response application/json Copy Account creation successful. ``` { "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "company_name": "DoeINC" } ``` ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `first_name`required | `string` | Customer first nameExample `Alan` | | `last_name`required | `string` | Customer last nameExample `Turing` | | `email`required | `string` | Customer email addressExample `Alan.Turing@example.com` | | `company_name`required | `string` | Public company nameExample `TuringINC` | | `organization_id` | `string` | Organization IDExample `fxfxfxfx-fxfxfx-fxfxfx-fxfxfxfx` | | `callback_url` | `string` | URL address used to redirect the user to a webpage once its click on the confirmation button inside the welcome email. The confirmation_token used to confirm the email will be added on the query parameters in this URL.Example `https://mydomain.com` | ##### Response `201``application/json` 6 fields Account creation successful. | Field | Type | Description | | --- | --- | --- | | `account_id`required | `string` | Account IDExample `f2ee7908-daee-4da0-9cbe-f8dbcb9dab53` | | `first_name`required | `string` | Customer first nameExample `Alan` | | `last_name`required | `string` | Customer last nameExample `Turing` | | `email`required | `string` | Customer email addressExample `Alan.Turing@example.com` | | `company_name`required | `string` | Public company nameExample `TuringINC` | | `organization_id` | `string` | Organization IDExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | ##### Other responses `400``500` `PUT` `/customer-accounts` #### Update Customer Account `put-customer-accounts` Update Customer Account updates your account in Staircase. An organization can be added to the user by updating the organization_id field. ##### Request ExampleExample2 application/json Copy Updates a customer account ``` { "account_key": "92e23b69-643c-453c-811d-ec2bc20a35e0", "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "company_name": "DoeINC" } ``` application/json Copy Updates a customer account with organization ID instead of Company Name ``` { "account_key": "92e23b69-643c-453c-811d-ec2bc20a35e0", "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "organization_id": "fxfxfxfx-fxfx-fxfx-fxfx-fxfxfxfxfxfx" } ``` ##### Response application/json Copy Account creation successful. ``` { "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "company_name": "DoeINC" } ``` ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `account_key`required | `string` | API key associated to the userExample `92e23b69-643c-453c-811d-ec2bc20a35e0` | | `first_name` | `string` | Customer first nameExample `Alan` | | `last_name` | `string` | Customer last nameExample `Turing` | | `email` | `string` | Customer email addressExample `Alan.Turing@example.com` | | `company_name` | `string` | Public company nameExample `TuringINC` | | `organization_id` | `string` | Organization IDExample `fxfxfxfx-fxfxfx-fxfxfx-fxfxfxfx` | ##### Response `200``application/json` 6 fields Account creation successful. | Field | Type | Description | | --- | --- | --- | | `account_id`required | `string` | Account IDExample `f2ee7908-daee-4da0-9cbe-f8dbcb9dab53` | | `first_name`required | `string` | Customer first nameExample `Alan` | | `last_name`required | `string` | Customer last nameExample `Turing` | | `email`required | `string` | Customer email addressExample `Alan.Turing@example.com` | | `company_name`required | `string` | Public company nameExample `TuringINC` | | `organization_id` | `string` | Organization IDExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | ##### Other responses `400` `GET` `/organization-account` #### Retrieve Organization Account List `get-retrieve-organization-account-list` This service retrieves a list of customer accounts associated with a Company organization, organizations are defined in the Company product. Company Organizations: Organizations help you group your accounts and environments, as you grow and scale with Staircase. Define a Company organization by going to the Add Company Organization service, after is created you can retrieve the company organization in this service. ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | | `organization_id` required | `string` query | `fxfxfxfx-fxfx-fxfx-fxfx-fxfxfxfxfx` | The organization ID. | ##### Response `200``application/json` 6 fields Account retrieved successful. | Field | Type | Description | | --- | --- | --- | | `account_id`required | `string` | Account IDExample `f2ee7908-daee-4da0-9cbe-f8dbcb9dab53` | | `account_key`required | `string` | Account KeyExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | | `organization_id`required | `string` | Organization IDExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | | `first_name`required | `string` | Customer first nameExample `Alan` | | `last_name`required | `string` | Customer last nameExample `Turing` | | `email`required | `string` | Customer email addressExample `Alan.Turing@example.com` | ##### Other responses `400``401` `POST` `/organization-account` #### Create Organization Account `post-create-organization-account` Create Organization Account creates organization account in Staircase. ##### Request application/json Copy Create using required fields ``` { "organization_id": "fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx" } ``` ##### Response application/json Copy Account creation successful. ``` { "first_name": "Vlad", "last_name": "Doe", "email": "vlad@example.com", "company_name": "DoeINC" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `organization_id`required | `string` | Organization IDExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | | `first_name` | `string` | Customer first nameExample `Alan` | | `last_name` | `string` | Customer last nameExample `Turing` | | `email` | `string` | Customer email addressExample `Alan.Turing@example.com` | ##### Response `201``application/json` 6 fields Account creation successful. | Field | Type | Description | | --- | --- | --- | | `account_id`required | `string` | Account IDExample `f2ee7908-daee-4da0-9cbe-f8dbcb9dab53` | | `account_key`required | `string` | Account KeyExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | | `organization_id`required | `string` | Organization IDExample `fxfxfxfx-fxfxfxfx-fxfxfxfx-fxfxfxfx` | | `first_name`required | `string` | Customer first nameExample `Alan` | | `last_name`required | `string` | Customer last nameExample `Turing` | | `email`required | `string` | Customer email addressExample `Alan.Turing@example.com` | ##### Other responses `400` `POST` `/confirm-email` #### Confirm Customer Email `post-confirm-email` This service confirms the customer email and return the user key. A confirmation token must be provided. This confirmation token can be found on the query parameters of the confirmation button URL address on the email sent by Customer Creation service. Once the customer email is confirmed, the service will continue to provide the user key in the response for 1 hour. After 1 hour, the user key will not be provided in the response anymore. ##### Request application/json Copy Example of a successful email confirmation. ``` { "confirmation_token": "" } ``` ##### Response application/json Copy Email confirmed successful. ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `confirmation_token` | `string` | A confirmation token. This confirmation token can be found on the query parameters of the confirmation button URL address on the email sent by Customer Creation service.Example `` | ##### Response `200``application/json` 1 fields Email was already confirmed previously. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Email was already confirmed previously. | ##### Response `201``application/json` 1 fields Email confirmed successful. | Field | Type | Description | | --- | --- | --- | | `api_key` | `string` | User API key. | ##### Other responses `400` `GET` `/retrieve-account` #### Retrieve Account `retrieve_account` This service is used to retrieve account details by API_key When a customer account is created, the API_key is send to the customer by email. This can be used on this service to retrieve the customer account details ##### Response 200400500 application/json Copy 200 response ``` { "account_id": "1f4bf452-1da2-8f6c-976c-8a779523156a", "company_name": "FoobarINC", "email": "example@email.com", "first_name": "John", "last_name": "Doe" } ``` application/json Copy 400 response ``` { "message": "The query string parameter must contain the api_key parameter. Please use /retrieve-account?api_key=" } ``` application/json Copy 500 response ``` { "message": "Internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `api_key` required | `string` query | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The api_key that was send to the customer upon account creation. | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `account_id` | `string` | Account unique identifier. | | `company_name` | `string` | Customer account company name. | | `email` | `string` | Customer account email. | | `first_name` | `string` | Customer account first_name. | | `last_name` | `string` | Customer account last_name. | ##### Response `400``application/json` 1 fields 400 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request. | ##### Response `500``application/json` 1 fields 500 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ### Site Logs `GET` `/marketing-logs` #### Get Site Logs `getMarketingLogs` Get Marketing Logs ##### Response 200400404 application/json Copy Successfully get Marketing Logs. ``` { "foo": "bar" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_configuration_id` required | `string` query | `some-configuration-id` | Site Configuration ID | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200` ### Policy Store `POST` `/policy-store` #### Create Policy Store `createPolicyStore` Creates a policy store. A policy store is a container for policies. ##### Request application/json Copy ``` { "description": "Example policy store" } ``` ##### Response 201400404 application/json Copy Successfully created policy store. ``` { "policy_store_id": "Dc3v9eLa2UbfCrw6wrkcmK" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `description`required | `string` | Description of the policy store.Example `Example policy store` | ##### Response `201``application/json` 1 fields Successfully created policy store. | Field | Type | Description | | --- | --- | --- | | `policy_store_id`required | `string` | ID of the policy store. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/policy-store` #### List Policy Stores `listPolicyStore` List Policy Store List created policy stores. A policy store is a container for policies. ##### Response 200400404 application/json Copy Successfully get list of policy stores. ``` { "next_token": "AQICAHisuNZI1E/P3KXm5hmEqogC7wTB89VLTeJv4gbr", "policy_stores": [ { "policy_store_id": "Dc3v9eLa2UbfCrw6wrkcmK", "description": "test", "created_at": "2024-04-23T20:35:36.300514+00:00", "updated_at": "2024-04-23T20:35:36.300514+00:00" } ] } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `limit` | `integer` query | `5` | Number of policy stores to return. | | `next_token` | `string` query | `null` | Next token. | ##### Response `200``application/json` 2 fields Successfully get list of policy stores. | Field | Type | Description | | --- | --- | --- | | `policy_stores`required | `object[]` | Policy stores array. | | `policy_store_id`required | `string` | ID of the policy store. | | `description`required | `string` | Description of the policy store. | | `created_at`required | `string (date-time)` | Creation date of the policy store. | | `updated_at`required | `string (date-time)` | Last update date of the policy store. | | `next_token`required | `string` | Next token. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `DELETE` `/policy-store/{policy_store_id}` #### Delete Policy Store `deletePolicyStore` Delete policy store. A policy store is a container for policies. ##### Response 400404 application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `204` `PUT` `/policy-store/{policy_store_id}` #### Update Policy Store `updatePolicyStore` Update policy store. A policy store is a container for policies. ##### Response 200400404 application/json Copy Successfully updated policy store. ``` { "message": "Policy store updated successfully." } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | ##### Response `200``application/json` 1 fields Successfully updated policy store. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Policy `POST` `/policy-store/{policy_store_id}/policy` #### Create Policy `createPolicy` Creates a Cedar policy and saves it in the specified policy store. A policy is a statement that either permits or forbids a principal to take one or more actions on a resource. Each policy is evaluated independently of any other policy. For more information about how Cedar policies are structured and evaluated, see Example of Cedar policy that permits a borrower to get property information on a specific property: Show the rest ``` permit(principal == ExampleCo::Loan::Borrower::\"John\",action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"],resource == ExampleCo::Loan::Property::\"154 Road\") when {true}; ``` Example of Cedar policy that permits a borrower to get property information on any property: ``` permit(principal == ExampleCo::Loan::Borrower::\"John\", action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"], resource) when {true}; ``` Example of Cedar policy that forbids a borrower to get property information on a specific property: ``` forbid(principal == ExampleCo::Loan::Borrower::\"John\", action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"], resource == ExampleCo::Loan::Property::\"154 Road\") when {true}; ``` ##### Request Permits a borrower to get property information on a specific propertyPermits a borrower to get property information on any propertyForbids a borrower to get property information on a specific property application/json Copy ``` { "definition": "permit(principal == ExampleCo::Loan::Borrower::\"John\",action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"],resource == ExampleCo::Loan::Property::\"154 Road\") when {true};", "description": "example" } ``` application/json Copy ``` { "definition": "permit(principal == ExampleCo::Loan::Borrower::\"John\", action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"], resource) when {true};", "description": "example" } ``` application/json Copy ``` { "definition": "forbid(principal == ExampleCo::Loan::Borrower::\"John\", action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"], resource == ExampleCo::Loan::Property::\"154 Road\") when {true};", "description": "example" } ``` ##### Response 201400404 application/json Copy Successfully created policy. ``` { "policy_id": "CR3KDTmvdYUGoPFeUapsFY" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `definition`required | `string` | Cedar policy definition.Example `permit(principal,action,resource) when {principal.owner == resource.owner};"}}` | | `description` | `string` | Description of the policy.Example `example` | ##### Response `201``application/json` 1 fields Successfully created policy. | Field | Type | Description | | --- | --- | --- | | `policy_id`required | `string` | ID of the policy. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/policy-store/{policy_store_id}/policy` #### List Policies `listPolicies` List created policies. ##### Response 200400404 application/json Copy Successfully get list of policies. ``` { "next_token": null, "policies": [ { "policy_id": "QYihkmqrnZTSvzQNhbpcjR", "description": "example", "principal": { "entityType": "loan::borrower", "entityId": "john" }, "resource": { "entityType": "loan::preapprovallist", "entityId": "johnlist" }, "created_at": "2024-04-22T16:50:10.977564+00:00", "updated_at": "2024-04-22T16:50:10.977564+00:00" } ] } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | | `limit` | `integer` query | `5` | Number of policies to return. | | `next_token` | `string` query | `null` | Next token. | ##### Response `200``application/json` 2 fields Successfully get list of policies. | Field | Type | Description | | --- | --- | --- | | `policies`required | `object[]` | Policies array. | | `policy_id`required | `string` | ID of the policy. | | `description`required | `string` | Description of the policy. | | `principal`required | `object` | Principal of the policy. | | `resource`required | `object` | Resource of the policy. | | `created_at`required | `string (date-time)` | Creation date of the policy. | | `updated_at`required | `string (date-time)` | Last update date of the policy. | | `next_token`required | `string` | Next token. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `DELETE` `/policy-store/{policy_store_id}/policy/{policy_id}` #### Delete Policy `deletePolicy` Delete policy. ##### Response 400404 application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | | `policy_id` required | `string` path | `CR3KDTmvdYUGoPFeUapsFY` | ID of the policy. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `204` `PUT` `/policy-store/{policy_store_id}/policy/{policy_id}` #### Update Policy `updatePolicy` Update policy. ##### Request Permits a borrower to get property information on a specific propertyPermits a borrower to get property information on any propertyForbids a borrower to get property information on a specific property application/json Copy ``` { "definition": "permit(principal == ExampleCo::Loan::Borrower::\"John\",action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"],resource == ExampleCo::Loan::Property::\"154 Road\") when {true};", "description": "example" } ``` application/json Copy ``` { "definition": "permit(principal == ExampleCo::Loan::Borrower::\"John\", action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"], resource) when {true};", "description": "example" } ``` application/json Copy ``` { "definition": "forbid(principal == ExampleCo::Loan::Borrower::\"John\", action in [ExampleCo::Loan::Action::\"GetPropertyInfo\"], resource == ExampleCo::Loan::Property::\"154 Road\") when {true};", "description": "example" } ``` ##### Response 200400404 application/json Copy Successfully updated policy store. ``` { "message": "Policy store updated successfully." } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | | `policy_id` required | `string` path | `CR3KDTmvdYUGoPFeUapsFY` | ID of the policy. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `definition`required | `string` | Cedar policy definition.Example `permit(principal,action,resource) when {principal.owner == resource.owner};"}}` | | `description` | `string` | Description of the policy.Example `example` | ##### Response `200``application/json` 1 fields Successfully updated policy store. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/policy-store/{policy_store_id}/policy/{policy_id}` #### Get Policy `getPolicy` Delete Policy Get policy. ##### Response 200400404 application/json Copy Successfully deleted policy. ``` { "principal": { "entityType": "loan::borrower", "entityId": "john" }, "resource": { "entityType": "loan::preapprovallist", "entityId": "johnlist" }, "definition": "permit(\n principal == loan::borrower::\"john\",\n action in [loan::Action::\"ReadPreapprovallist\",loan::Action::\"UpdatePreapprovallist\",loan::Action::\"DeletePreapprovallist\"],\n resource == loan::preapprovallist::\"johnlist\"\n) when {\n true\n};", "description": "example", "created_at": "2024-04-22T16:50:10.977564+00:00", "updated_at": "2024-04-22T16:50:10.977564+00:00" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | | `policy_id` required | `string` path | `CR3KDTmvdYUGoPFeUapsFY` | ID of the policy. | ##### Response `200``application/json` 6 fields Successfully deleted policy. | Field | Type | Description | | --- | --- | --- | | `principal`required | `object` | Principal of the policy. | | `resource`required | `object` | Resource of the policy. | | `definition`required | `string` | Definition of the policy. | | `description`required | `string` | Description of the policy. | | `created_at`required | `string (date-time)` | Creation date of the policy. | | `updated_at`required | `string (date-time)` | Last update date of the policy. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Policy Store Schema `PUT` `/policy-store/{policy_store_id}/schema` #### Put Policy Store Schema `putPolicyStoreSchema` Creates or updates the policy Cedar json schema in the specified policy store. The schema is used to validate any policies submitted to the policy store. Existing policies and templates are not re-evaluated against the changed schema. For more information and examples about Cedar schema format, see . Example of Cedar schema: ``` { "ExampleCo::Mortgage": { "actions": { "GetPropertyInfo": { "appliesTo": { "principalTypes": [ "Borrower" ], "resourceTypes": [ "Property" ] } }, "GetListingInfo": { "appliesTo": { "principalTypes": [ "Borrower" ], "resourceTypes": [ "Listing" ] } } }, &Show the restquot;entityTypes": { "Property": { "shape": { "type": "Record", "attributes": { "address": { "type": "String" }, "property_identifier": { "type": "String" }, "loan_identifier": { "type": "String" } } } }, "Listing": { "shape": { "type": "Record", "attributes": { "total_price": { "type": "String" }, "listing_identifier": { "type": "String" } } } }, "Borrower": { "shape": { "attributes": { "first_name": { "type": "String" }, "last_name": { "type": "String" }, "person_identifier": { "type": "String" }, "loan_identifier": { "type": "String" } }, "type": "Record" } } } } } ``` ##### Request application/json Copy ``` { "definition": { "ExampleCo::Loan": { "actions": { "GetPropertyInfo": { "appliesTo": { "principalTypes": [ "Borrower" ], "resourceTypes": [ "Property" ] } } }, "entityTypes": { "Property": { "shape": { "type": "Record", "attributes": {} } }, "Borrower": { "shape": { "attributes": {}, "type": "Record" } } } } } } ``` ##### Response 200400404 application/json Copy Successfully created/updated policy store schema. ``` { "message": "Policy store updated successfully." } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `definition` | `object` | Cedar schema of the policy store. | ##### Response `200``application/json` 1 fields Successfully created/updated policy store schema. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/policy-store/{policy_store_id}/schema` #### Get Policy Store Schema `getPolicyStoreSchema` Retrieve defined schema in the specified policy store. ##### Response 200400404 application/json Copy Successfully created/updated policy store schema. ``` { "schema": { "ExampleCo::Loan": { "entityTypes": { "Borrower": { "shape": { "attributes": {}, "type": "Record" } }, "Property": { "shape": { "attributes": {}, "type": "Record" } } }, "actions": { "GetPropertyInfo": { "appliesTo": { "principalTypes": [ "Borrower" ], "resourceTypes": [ "Property" ] } } } } }, "namespaces": [ "ExampleCo::Loan" ], "created_at": "2024-04-23T20:33:36.040403+00:00", "updated_at": "2024-04-24T11:19:28.118220+00:00" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Resource not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `policy_store_id` required | `string` path | `Dc3v9eLa2UbfCrw6wrkcmK` | ID of the policy store. | ##### Response `200``application/json` 4 fields Successfully created/updated policy store schema. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | Policy store schema. | | `namespaces`required | `string[]` | Namespaces. | | `created_at`required | `string (date-time)` | Creation date of the policy store schema. | | `updated_at`required | `string (date-time)` | Last update date of the policy store schema. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Account Data `POST` `/setup-master-data` #### Set up Master data `account_store_new_environment_access` Set up master Account data Register the environment and API key, this configuration will set up the Account to retrieve data from the environment, allowing to set up the customer to start working with Staircase products. The Account data bundle automatically registers the Marketplace environment which includes all needed configurations and credentials to start using Staircase products in the customer environment. ##### Request application/json Copy . ``` { "environment": "test2.staircaseapi.com\"", "api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Response application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `environment`required | `string` | The environment hostExample `test.staircaseapi.comm` | | `api-key`required | `string (api-key)` | The API key used in order to access APIs in the hostExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL service address. | | `message` | `string` | The error details. | `DELETE` `/setup-master-data` #### Remove Master data `account_remove_environments_access` Remove Master Account Data Removes the environment configuration and data so that it can stop retrieving credentials and configurations from another environment. ##### Response application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `Content-Type` required | `string` header | `application/json` | Content Type | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL service address. | | `message` | `string` | The error details. | ##### Response `404``application/json` 1 fields 404 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The error details. | ### Access Amazon SSO `POST` `/sso/amazon` #### Create SSO Configuration `createSSOConfigurationAmazon` Create SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "amzn1.application-oa2-client.1234567890abcdef1234567890abcdef", "client_secret": "" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Amazon set successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_secret`required | `string (client_secret)` | SSO provider client secret.Example `` | | `client_id`required | `string (client_id)` | SSO provider client id.Example `amzn1.application-oa2-client.1234567890abcdef1234567890abcdef` | ##### Response `201``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Amazon set successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration existent | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `PUT` `/sso/amazon` #### Update SSO Configuration `updateSSOConfigurationAmazon` Update SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "amzn1.application-oa2-client.1234567890abcdef1234567890abcdef", "client_secret": "" } ``` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Google updated successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_secret`required | `string (client_secret)` | SSO provider client secret.Example `` | | `client_id`required | `string (client_id)` | SSO provider client id.Example `amzn1.application-oa2-client.1234567890abcdef1234567890abcdef` | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Google updated successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/sso/amazon` #### Get SSO Configuration `getSSOConfigurationAmazon` Retrieve SSO configuration set on environment. ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "approved_js_origin": "https://auth.env.staircaseapi.com", "oauth_authorized_redirect": "https://auth.env.staircaseapi.com/oauth2/idpresponse" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `200``application/json` 2 fields OK response | Field | Type | Description | | --- | --- | --- | | `approved_js_origin` | `string` | approved_js_origin.Example `https://auth.env.staircaseapi.com` | | `oauth_authorized_redirect` | `string` | oauth_authorized_redirect.Example `https://auth.env.staircaseapi.com/oauth2/idpresponse` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `DELETE` `/sso/amazon` #### Delete SSO Configuration `deleteSSOConfigurationsAmazon` Delete SSO configuration set on environment. ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``401``404` ### Access Apple SSO `POST` `/sso/apple` #### Create SSO Configuration `createSSOConfigurationApple` Create SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "com.example.app", "team_id": "ABCDEFGH12345678", "key_id": "XYZ1234567890", "private_key": "" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Apple set successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `client_id`required | `string (client_id)` | SSO provider client id.Example `client_id` | | `team_id`required | `string (team_id)` | SSO provider team id.Example `team_id` | | `key_id`required | `string (key_id)` | SSO provider key id.Example `team_id` | | `private_key`required | `string (private_key)` | SSO provider private key.Example `` | ##### Response `201``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Apple set successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration existent | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `PUT` `/sso/apple` #### Update SSO Configuration `updateSSOConfigurationApple` Update SSO configuration on environment. Providers Supported: Google. ##### Request application/json Copy ``` { "client_id": "com.example.app", "team_id": "ABCDEFGH12345678", "key_id": "XYZ1234567890", "private_key": "" } ``` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Apple updated successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `client_id`required | `string (client_id)` | SSO provider client id.Example `client_id` | | `team_id`required | `string (team_id)` | SSO provider team id.Example `team_id` | | `key_id`required | `string (key_id)` | SSO provider key id.Example `team_id` | | `private_key`required | `string (private_key)` | SSO provider private key.Example `` | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Apple updated successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/sso/apple` #### Get SSO Configuration `getSSOConfigurationApple` Retrieve SSO configuration set on environment. ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "approved_js_origin": "https://auth.env.staircaseapi.com", "oauth_authorized_redirect": "https://auth.env.staircaseapi.com/oauth2/idpresponse" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `200``application/json` 2 fields OK response | Field | Type | Description | | --- | --- | --- | | `approved_js_origin` | `string` | approved_js_origin.Example `https://auth.env.staircaseapi.com` | | `oauth_authorized_redirect` | `string` | oauth_authorized_redirect.Example `https://auth.env.staircaseapi.com/oauth2/idpresponse` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `DELETE` `/sso/apple` #### Delete SSO Configuration `deleteSSOConfigurationsApple` Delete SSO configuration set on environment. ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``401``404` ### Access Facebook SSO `POST` `/sso/facebook` #### Create SSO Configuration `createSSOConfigurationFacebook` Create SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "1234567890123456", "client_secret": "" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Facebook set successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_secret`required | `string (client_secret)` | SSO provider client secret.Example `` | | `client_id`required | `string (client_id)` | SSO provider client id.Example `client_id` | ##### Response `201``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Facebook set successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration existent | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `PUT` `/sso/facebook` #### Update SSO Configuration `updateSSOConfigurationFacebook` Update SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "1234567890123456", "client_secret": "" } ``` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Facebook updated successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_secret`required | `string (client_secret)` | SSO provider client secret.Example `` | | `client_id`required | `string (client_id)` | SSO provider client id.Example `client_id` | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Facebook updated successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/sso/facebook` #### Get SSO Configuration `getSSOConfigurationFacebook` Retrieve SSO configuration set on environment. ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "approved_js_origin": "https://auth.env.staircaseapi.com", "oauth_authorized_redirect": "https://auth.env.staircaseapi.com/oauth2/idpresponse" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `200``application/json` 2 fields OK response | Field | Type | Description | | --- | --- | --- | | `approved_js_origin` | `string` | approved_js_origin.Example `https://auth.env.staircaseapi.com` | | `oauth_authorized_redirect` | `string` | oauth_authorized_redirect.Example `https://auth.env.staircaseapi.com/oauth2/idpresponse` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `DELETE` `/sso/facebook` #### Delete SSO Configuration `deleteSSOConfigurationsFacebook` Delete SSO configuration set on environment. ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``401``404` ### Access Google SSO `POST` `/sso/google` #### Create SSO Configuration `createSSOConfiguration` Create SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "20581095937-l92gfggdj4tl5gn227g90.apps.googleusercontent.com", "client_secret": "" } ``` ##### Response 201400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Google set successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_secret`required | `string (client_secret)` | SSO provider client secret.Example `` | | `client_id`required | `string (client_id)` | SSO provider client id.Example `GOCSPX-MUIzom5cbFWaJs4AOIJE8JNr` | ##### Response `201``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Google set successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration existent | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `PUT` `/sso/google` #### Update SSO Configuration `updateSSOConfiguration` Update SSO configuration on environment. ##### Request application/json Copy ``` { "client_id": "20581095937-l92gfggdj4tl5gn227g90.apps.googleusercontent.com", "client_secret": "" } ``` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "message": "SSO configuration Google updated successfully" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_secret`required | `string (client_secret)` | SSO provider client secret.Example `` | | `client_id`required | `string (client_id)` | SSO provider client id.Example `GOCSPX-MUIzom5cbFWaJs4AOIJE8JNr` | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration message.Example `SSO configuration Google updated successfully` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields SSO Configuration Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/sso/google` #### Get SSO Configuration `getSSOConfiguration` Retrieve SSO configuration set on environment. ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "approved_js_origin": "https://auth.env.staircaseapi.com", "oauth_authorized_redirect": "https://auth.env.staircaseapi.com/oauth2/idpresponse" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `200``application/json` 2 fields OK response | Field | Type | Description | | --- | --- | --- | | `approved_js_origin` | `string` | approved_js_origin.Example `https://auth.env.staircaseapi.com` | | `oauth_authorized_redirect` | `string` | oauth_authorized_redirect.Example `https://auth.env.staircaseapi.com/oauth2/idpresponse` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` `DELETE` `/sso/google` #### Delete SSO Configuration `deleteSSOConfigurations` Delete SSO configuration set on environment. ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields User not confirmed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``401``404` ### Access SSO `GET` `/{application_name}/sso/{sso_provider}` #### Get SSO by Application `getSSOApp` Get SSO Links retrieves the sing-up/sing-in and logout links needed for managing SSO logged users. Providers Supported: `Google`,`Facebook`,`SignInWithApple`,`LoginWithAmazon` There are two types of grants: - Authorization Code Grant - Implicit Grant The Authorization Code Grant will return `access_token` and `id_token` as a URL fragments in the `redirect_uri` The Implicit Grant will return `access_token` and `id_token` AND `refresh_token` as a URL fragments in the `redirect_uri` ##### Response 200400 application/json400 text/html application/json Copy OK response ``` [ { "sso_provider": "Google", "sso_signin_link": "https://auth.cerf-dev.staircaseapi.com/oauth2/authorize?identity_provider=Google&redirect_uri=https://webhook.site/123&response_type=token&client_id=6066huk2cnnuln4f2ajg71jnmv&scope=email+openid+profile", "sso_logout_link": "https://auth.cerf-dev.staircaseapi.com/logout?logout_uri=https://webhook.site/123&response_type=token&client_id=6066huk2cnnuln4f2ajg71jnmv" } ] ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `sso_provider` required | `string` path | `Google` | SSO provider. | | `application_name` required | `string` path | `access` | Application name. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY | ##### Response `200``application/json` 3 fields OK response | Field | Type | Description | | --- | --- | --- | | `sso_provider` | `string` | Configuration message.Example `Google, SSO configurations set` | | `sso_signin_link` | `string` | Redirect UI added.Example `https://ui.redirect/logged/users` | | `sso_logout_link` | `string` | Redirect UI added.Example `https://ui.redirect/logged/users` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `429``application/json` 1 fields To many requests | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401``404` ### Operations `GET` `/smoke` #### Smoke endpoint Endpoint to check service health ##### Other responses `200` `POST` `/tenants` #### Create necessary AWS instances for new tenant Tenant is client of staircase. When a new client registers we should create virtual infrastructure for him: create new domain in format {tenant_name}.api.stairacaseapi.com, map specified API to {tenant_name}.api.stairacaseapi.com/{base_path}, create new usage plan with {tenant_name} name for API's specified in api_mapping. That what this endpoint does. ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `tenant_name` | `string` | — | | `api_mapping` | `array` | — | ##### Response `202``application/json` 2 fields 202 response | Field | Type | Description | | --- | --- | --- | | `start_time` | `string` | — | | `status` | `string` | — | ##### Other responses `400` `POST` `/tenants/{tenant_name}/keys` #### Generate API key Generate API key for specified tenant and add it to tenant usage plan ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `tenant_name` required | `string` path | Tenant name | ##### Response `201``application/json` 1 fields 201 response | Field | Type | Description | | --- | --- | --- | | `x-api-key` | `string` | — | ## Errors `400``401``403``404``409``422``429``500` ## More in Distribution - Next product: Console --- # Console # Console The configurable application shell every front end was assembled in. An application in the Console is a configuration rather than a codebase: components, their properties and their ordering, resolved against a shared component library and packaged into a deployable front end. The library covers the primitives plus custom components built for this domain. Configuration-driven assembly is what carried several interfaces without several front-end codebases. ## How it works Three systems meet at one identifier. A design file is imported into the cloud provider's own component library, which generates typed components from it; a content system holds the configuration saying which of those components appear, in what order, with what labels, and against which endpoint; and the catalogue holds the record that names the application. All three are keyed on the configuration identifier Marketplace issues, which is what stops the design, the content and the deployment drifting apart. A list view — the most common shape — is a content record naming a table layout and an endpoint configuration. Building one means duplicating an existing record and editing the labels and the endpoint it reads, so a new screen over an existing API is content work rather than engineering work. Every interface came out of this shell. A rate calculator, a property-data exchange and a conversational front end are three configurations against one component library, not three codebases. ## Operations ### Console Dashboard UI `POST` `/auth/password` #### Change pass `change-pass` ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/auth/sign-in` #### Sign In `sign-in` Sign in Sign In ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/auth/sign-up` #### Sign Up `sign-up` Sign up Sign Up ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Users `GET` `/author` #### Get Author `get_author` Request author access to a pipeline to be able to: - Review and modify Dataset - Create Analysis - Share Dashboards To log in to QuickSight: - Go to - Use the QuickSight Account Name `account_name`. - Use the QuickSight User `user_name`. - Use the QuickSight User Password that was defined while obtaining Author Access. Please note the Author user is one for all the Staircase environment. It is important to understand that Author will see datasets and analysis from all the pipelines. It is recommended to use `Shared folders` in Quicksight to see datasets organized by `pipeline_name`. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` ### Console API `GET` `/configurations` #### Get configuration `get_configuration` Get configurations ##### Response application/json Copy Ok. ``` { "collections": [ { "metadata": { "serialise_to_graph": true, "fuzzy_searchable": false, "validation": true, "version": 3, "created_at": "2023-05-26T02:09:23.253331-04:00" }, "collection_id": "01H1BAT4SNVDE9HYEBZD04MNEH", "data": { "companies": [ { "@id": "01H1BAT4TZW1HXZ0RZPYK52VFV", "@type": "company", "company_identifier": "grate-company-id" }, { "@id": "01H1BAT4TZ7T9THN4MEZ9E4MMV", "@type": "company", "company_identifier": "staircase-company-id" }, { "@id": "01H1BAT4TZ6FB1ZABFM8MQGFTH", "@type": "company", "company_identifier": "ice-company-id" }, { "@id": "01H1BAT4TZ45T2C6K39CMGQQKB", "@type": "company", "company_identifier": "ice-company-id" }, { "@id": "01H1BAT4TZJ01KM1WEPRZEZHKM", "@type": "company" } ], "consoles": [ { "@id": "01H1BAT4TYBW7FJQNSB9KXXB28", "@type": "console", "console_configuration_type": "listView", "datocms_class_name": "TeamVelocity", "datocms_identifier": "123456789", "has_permission": [ "01H1BAT4TZNZSWRWX738J7KJ96", "01H1BAT4TZCRVFH26GS24DMCQG", "01H1BAT4TZAGXKEG5N4Z3STD30", "01H1BAT4TZ9XSSYVRC35APTJ51", "01H1BAT4TZ1ECXC6FM40W98VVR" ], "title": "Team Velocity List View" } ], "permissions": [ { "@id": "01H1BAT4TZNZSWRWX738J7KJ96", "@type": "permission", "company_contact_role_type": "CFO", "has_company": "01H1BAT4TZ6FB1ZABFM8MQGFTH" }, { "@id": "01H1BAT4TZAGXKEG5N4Z3STD30", "@type": "permission", "company_contact_role_type": "CFO", "has_company": "01H1BAT4TZJ01KM1WEPRZEZHKM" }, { "@id": "01H1BAT4TZCRVFH26GS24DMCQG", "@type": "permission", "has_company": "01H1BAT4TZW1HXZ0RZPYK52VFV" }, { "@id": "01H1BAT4TZ1ECXC6FM40W98VVR", "@type": "permission", "has_company": "01H1BAT4TZ7T9THN4MEZ9E4MMV" }, { "@id": "01H1BAT4TZ9XSSYVRC35APTJ51", "@type": "permission", "company_contact_role_type": "CEO", "has_company": "01H1BAT4TZ45T2C6K39CMGQQKB" } ], "product_configurations": [ { "@type": "product_configuration", "product_configuration_identifier": "marketpace-ontology-configuration-id-of-the-screen", "@id": "01H1BAT4TZC99WK5CWFMJZ3G9H" } ] }, "transaction_id": "01H1BAT4G004ZKK5DXF1GB87YV" } ], "next_token": null } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `token` | Next token for listing | ##### Other responses `200` `POST` `/configurations` #### Create configuration `create_configuration` ##### Request application/json Copy ``` { "product_configuration_identifier": "marketpace-ontology-configuration-id-of-the-screen", "title": "Team Velocity List View", "datocms_identifier": "123456789", "datocms_class_name": "TeamVelocity", "url_suffix": "/team-velocity", "configuration_type": "listView", "permissions": [ { "has_company": "staircase-company-id" }, { "has_company": "ice-company-id", "company_contact_role_type": "CEO" }, { "has_company": "ice-company-id", "company_contact_role_type": "CFO" }, { "company_contact_role_type": "CFO" }, { "has_company": "grate-company-id" } ] } ``` ##### Response 200400 application/json Copy Ok. ``` { "message": "created", "transaction_id": "01H1KQAXKB77A2PA1QSS1YEDQD", "collection_id": "01H1KQAXXWA6CR4ZSJPSHCGDGB" } ``` application/json Copy Request data invalid ``` { "message": "Request body is not valid JSON." } ``` ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` `GET` `/configurations/{configuration_id}` #### Get configuration `get_configurations` ##### Response application/json Copy Ok. ``` { "collections": [ { "metadata": { "serialise_to_graph": true, "fuzzy_searchable": false, "validation": true, "version": 3, "created_at": "2023-05-26T02:09:23.253331-04:00" }, "collection_id": "01H1BAT4SNVDE9HYEBZD04MNEH", "data": { "companies": [ { "@id": "01H1BAT4TZW1HXZ0RZPYK52VFV", "@type": "company", "company_identifier": "grate-company-id" }, { "@id": "01H1BAT4TZ7T9THN4MEZ9E4MMV", "@type": "company", "company_identifier": "staircase-company-id" }, { "@id": "01H1BAT4TZ6FB1ZABFM8MQGFTH", "@type": "company", "company_identifier": "ice-company-id" }, { "@id": "01H1BAT4TZ45T2C6K39CMGQQKB", "@type": "company", "company_identifier": "ice-company-id" }, { "@id": "01H1BAT4TZJ01KM1WEPRZEZHKM", "@type": "company" } ], "consoles": [ { "@id": "01H1BAT4TYBW7FJQNSB9KXXB28", "@type": "console", "console_configuration_type": "listView", "datocms_class_name": "TeamVelocity", "datocms_identifier": "123456789", "has_permission": [ "01H1BAT4TZNZSWRWX738J7KJ96", "01H1BAT4TZCRVFH26GS24DMCQG", "01H1BAT4TZAGXKEG5N4Z3STD30", "01H1BAT4TZ9XSSYVRC35APTJ51", "01H1BAT4TZ1ECXC6FM40W98VVR" ], "title": "Team Velocity List View" } ], "permissions": [ { "@id": "01H1BAT4TZNZSWRWX738J7KJ96", "@type": "permission", "company_contact_role_type": "CFO", "has_company": "01H1BAT4TZ6FB1ZABFM8MQGFTH" }, { "@id": "01H1BAT4TZAGXKEG5N4Z3STD30", "@type": "permission", "company_contact_role_type": "CFO", "has_company": "01H1BAT4TZJ01KM1WEPRZEZHKM" }, { "@id": "01H1BAT4TZCRVFH26GS24DMCQG", "@type": "permission", "has_company": "01H1BAT4TZW1HXZ0RZPYK52VFV" }, { "@id": "01H1BAT4TZ1ECXC6FM40W98VVR", "@type": "permission", "has_company": "01H1BAT4TZ7T9THN4MEZ9E4MMV" }, { "@id": "01H1BAT4TZ9XSSYVRC35APTJ51", "@type": "permission", "company_contact_role_type": "CEO", "has_company": "01H1BAT4TZ45T2C6K39CMGQQKB" } ], "product_configurations": [ { "@type": "product_configuration", "product_configuration_identifier": "marketpace-ontology-configuration-id-of-the-screen", "@id": "01H1BAT4TZC99WK5CWFMJZ3G9H" } ] }, "transaction_id": "01H1BAT4G004ZKK5DXF1GB87YV" } ], "next_token": null } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `configuration_id` required | `string` path | `product_configuration_identifier` | querying by $.product_configurations[*].product_configuration_identifier | ##### Other responses `200` ### Dashboard `PUT` `/dashboard/dashboards/costs-and-revenue` #### Update Costs/Revenue Dashboard `updateCostsRevenueDashboard` Starts the update of the GTL costs/revenue dashboard with metrics from Health and costs from AWS Cost Explorer. ##### Response `202``application/json` 1 fields Update is started. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message about update is started. | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Dashboards `GET` `/dashboards` #### Get Dashboards `get_all_dashboards` Get embedded link for all dashboards. Going to return all the links to all the dashboards. Response includes: - `id` - Dashboard ID - `name` - Dashboard name - `embedded_url` - Embedded URL. Links are QuickSight native with a temporary authentication token. So they can not be used for permanent share. - `public_url` - Public URL. This is a permanent link that can be used to share Dashboard outside the Staircase. It is good idea to use `embedded_link` inside a web page or web application that have authentication. Important, `public_url` can be used without `API_KEY`. Please do not share it if Dashboard has sensitive data. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Dashboard ID | | `name`required | `string` | Dashboard name | | `embedded_url`required | `string` | Embedded URL | | `public_url`required | `string` | Public URL | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `GET` `/dashboards/{dashboard_id}/public-url` #### Get Public Url `get_gashboard_public_url` Get Public URL Get dashboard public URL. It is required to specify: - `dashboard_id` - Dashboard ID from the Get Dashboards As it can be invoked without API_KEY only, it can NOT be used to share sensitive data. For now, this is the only endpoint that can be used for permanent share. ##### Response application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `dashboard_id` required | `string` path | `dashboard_id` | Dashboard ID | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `307``404` ### Datalakes `PUT` `/datalakes` #### Create or Update `create_datalake` Create or Update Datalake ##### Request application/json Copy ``` { "name": "pipe01", "verbose_name": "Pipeline 01", "dataset": { "columns": [ { "Name": "IMPORT_COMPLETED", "Type": "int" }, { "Name": "ONBOARDING_STARTED", "Type": "int" }, { "Name": "CLASSIFICATION_STARTED", "Type": "int" }, { "Name": "CLASSIFICATION_COMPLETED", "Type": "int" }, { "Name": "EXTRACTION_COMPLETED", "Type": "int" }, { "Name": "ONBOARDING_COMPLETED", "Type": "int" }, { "Name": "EXPORT_COMPLETED", "Type": "int" }, { "Name": "DELIVER_COMPLETED", "Type": "int" }, { "Name": "date", "Type": "timestamp" } ] } } ``` ##### Response 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" } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `verbose_name` | `string` | Pipeline Verbose Name | | `description` | `string` | Pipeline Description | | `job` | `object` | Pipeline Job | | `definition`required | `object` | Job Definition | | `StartAt`required | `string` | The first state | | `States`required | `object` | Job States | | `STATE_NAME` | `object` | Name of the State | | `trigger_schedule_expression`required | `string` | Pipeline Trigger Schedule Expression | | `triggers` | `array` | Triggers | | `dataset` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `datasets` | `object` | Pipeline Datasets | | `DATASET_NAME` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `product_name` | `string` | Staircase product name | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200` `GET` `/datalakes` #### Get All `get_datalakes` Get All Datalakes ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` | `string` query | `Product Name` | Product Name | ##### Response `200``application/json` 9 fields Success | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `status` | `string` | Pipeline status`COMPLETED``FAILED``IN_PROGRESS` | | `operation` | `string` | Pipeline operation`CREATE``DELETE``REVIEW``ROLLBACK``UPDATE``UPDATE_ROLLBACK` | | `product_name` | `string` | Product name | | `verbose_name` | `string` | Pipeline Verbose name | | `job_name` | `string` | Pipeline Job name | | `job_trigger_names` | `string[]` | Pipeline Job Trigger name | | `created_at` | `string` | Pipeline create date | | `updated_at` | `string` | Pipeline Success update date | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Datalake `GET` `/datalakes/{name}` #### Get One `get_datalake` Get pipeline Retrieve datalake information, such as: - `status` ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 9 fields Success | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `status` | `string` | Pipeline status`COMPLETED``FAILED``IN_PROGRESS` | | `operation` | `string` | Pipeline operation`CREATE``DELETE``REVIEW``ROLLBACK``UPDATE``UPDATE_ROLLBACK` | | `product_name` | `string` | Product name | | `verbose_name` | `string` | Pipeline Verbose name | | `job_name` | `string` | Pipeline Job name | | `job_trigger_names` | `string[]` | Pipeline Job Trigger name | | `created_at` | `string` | Pipeline create date | | `updated_at` | `string` | Pipeline Success update date | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `DELETE` `/datalakes/{name}` #### Delete One `delete_datalake` Delete datalake ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `GET` `/datalakes/{name}/config` #### Get Config `get_datalake_config` Retrieve Datalake configuration. ##### Response application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 7 fields Success | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `verbose_name` | `string` | Pipeline Verbose Name | | `description` | `string` | Pipeline Description | | `job` | `object` | Pipeline Job | | `definition`required | `object` | Job Definition | | `StartAt`required | `string` | The first state | | `States`required | `object` | Job States | | `STATE_NAME` | `object` | Name of the State | | `trigger_schedule_expression`required | `string` | Pipeline Trigger Schedule Expression | | `triggers` | `array` | Triggers | | `dataset` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `datasets` | `object` | Pipeline Datasets | | `DATASET_NAME` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `product_name` | `string` | Staircase product name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `404` ### Pipelines `PUT` `/pipelines` #### Create or Update `create_pipeline` Create or Update Pipeline will enable creation of a new pipeline or update of existing one. To create a new pipeline, you need to provide the below information: - `name` - `description` (Optional) - `product_name` (Optional) - `job` (Optional) - `dataset` (Deprecated) - `datasets` One of `dataset` or `datasets` is Required. Show the rest #### Job `job` consist of: - `definition` Definition of a job as it is described in Job documentation. Job Definition - `trigger_schedule_expression` (Deprecated) Trigger schedule expression. Create Trigger - `triggers` Triggers definition, that contains `trigger_schedule_expression` and `request_payload`. `trigger_schedule_expression` and `triggers` are optional. Only one of `trigger_schedule_expression` or `triggers` can be used. If `job` not specified, it is required to use Put Data operation ##### `definition` Job definition as it is described in the Create Job There are few recommendations to consider: ###### Save Data As of now, Job definition should contain a step that saves data to a pipeline Save data example ``` { "SaveData": { "End": true, "Method": "POST", "Path": "console-pipeline/pipelines/{pipeline_name}/data", "PathParameters": { "pipeline_name": "$.outputs.Start.pipeline_name" }, "RequestPayload": "$.outputs.Health.response_payload.metrics", "Type": "InvokeProduct" } } ``` ###### Get Latest from a pipeline it is also recommended to start job definition from getting latest data from a pipeline Get Latest data example ``` { "LatestData": { "ExceptNext": "Health", "Method": "GET", "Next": "Health", "Path": "console-pipeline/pipelines/{pipeline_name}/data/latest?sort_column=created_at", "PathParameters": { "pipeline_name": "$.outputs.Start.pipeline_name" }, "Projection": { "created_at": "$jmespath.created_at | date_format(@, '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d')" }, "Type": "InvokeProduct" } } ``` ###### Use `pipeline_name` from request_payload Dashboard Pipeline will Execute Job with `request_payload`, where `pipeline_name` equals Dashboard Pipeline `name`. To be able to run ``` PathParameters: pipeline_name: $.request_payload.pipeline_name ``` ##### `trigger_schedule_expression` A rate expression starts when you create the pipeline, and then runs on its defined schedule. Rate expressions have two required fields. Fields are separated by white space. Syntax `rate(value unit)` Where: - `value` a positive number - `unit` the unit of time. Different units are required for values of 1, such as minute, and values over 1, such as minutes. Valid values: `minute` | `minutes` | `hour` | `hours` | `day` | `days` Example of `trigger_schedule_expression` definition ``` { "trigger_schedule_expression": "rate(1 day)" } ``` ##### `triggers` Allow to specify one or more executions for the pipeline. Can be used to run pipeline many times with different `request_payload`. Consist of: - `trigger_schedule_expression`. For more information please see `trigger_schedule_expression` documentation - `request_payload` (Optional) `triggers` can be used to collection data from different Staircase accounts by specifying host and api_key in the `request_payload`. Maximum number of `triggers` is 100. Example of `triggers` definition ``` { "triggers": [ { "trigger_schedule_expression": "rate(1 day)", "request_payload": { "Host": "documentation.staicaseapi.com", "ApiKey": "API_KEY" } } ] } ``` Another example a `trigger` with custom payload, containing some data and some Staircase environment informations. ``` { "triggers": [ { "trigger_schedule_expression": "rate(1 day)", "request_payload": { "my_custom_data": { "foo": "bar" }, "Env_A": { "my_host": "A.staicaseapi.com", "my_api_key": "API_KEY" }, "Env_B": { "my_host": "B.staicaseapi.com", "my_api_key": "API_KEY" } } } ] } ``` #### Datasets Allow to define more than one dataset in a Pipeline. Datasets definition contains Dataset Name and Dataset Configuration in a form of JSON object `key` and `value` Example of a Pipeline that have 2 datasets ``` { "datasets": { "sales": { "columns": [ { "Name": "start_date", "Type": "timestamp" }, { "Name": "transaction_id", "Type": "string" } ] }, "communications": { "columns": [ { "Name": "sent_date", "Type": "timestamp" }, { "Name": "transaction_id", "Type": "string" } ] } } } ``` #### Dataset `dataset` consist of: - `columns` - `calculated_columns` (Optional) ##### `columns` Is an array of column definitions. Columns from this array will be available in the QuickSight dataset. At least one column is required in `columns` array. Column definition consist of: - `Name` - `Type` one of the following types: `int`, `float`, `string`, `timestamp` The following example creates pipeline with `job` and `dataset`. It will run pipeline every 5 mins. Will generate some random data for "metric_number", "metric_status" and "date". ``` { "name": "pipe1", "verbose_name": "Pipe 1", "job": { "definition": { "StartAt": "StartFrom", "States": { "StartFrom": { "Type": "InvokeProduct", "Method": "POST", "Path": "console-pipeline/generate_data_example", "Next":"SaveRandomData" }, "SaveRandomData": { "Type": "InvokeProduct", "Method": "POST", "Path": "console-pipeline/pipelines/{pipeline_name}/data", "PathParameters": { "pipeline_name": "pipe1" }, "RequestPayload": "$.outputs.StartFrom.response_payload", "End": true } } }, "trigger_schedule_expression": "rate(5 minutes)" }, "dataset": { "columns": [ { "Name": "metric_number", "Type": "int" }, { "Name": "metric_status", "Type": "string" }, { "Name": "date", "Type": "timestamp" } ] } } ``` ##### `calculated_columns` It is an array of QuickSight Calculated Columns. Calculated column definition consists of: - `Name` - `Expression` - Calculated Columns expression to calculate a value `Expression` transform `columns` by using one or more of the following: - Operators - Functions - Aggregate functions (you can only add these to an analysis) - Fields that contain data - Other calculated fields ``` { "calculated_columns": [ { "Name":"status_len", "Expression": "strlen({status})" }, { "Name":"now", "Expression": "now" } ] } ``` ##### Request ExamplePipelineDatasetOnlyHealthIntegration application/json Copy ``` { "name": "pipe1", "verbose_name": "Pipe 1", "job": { "definition": { "StartAt": "StartFrom", "States": { "StartFrom": { "Type": "InvokeProduct", "Method": "POST", "Path": "console-pipeline/generate_data_example", "Next": "SaveRandomData" }, "SaveRandomData": { "Type": "InvokeProduct", "Method": "POST", "Path": "console-pipeline/pipelines/{pipeline_name}/data", "PathParameters": { "pipeline_name": "pipe1" }, "RequestPayload": "$.outputs.StartFrom.response_payload", "End": true } } }, "trigger_schedule_expression": "rate(5 minutes)" }, "dataset": { "columns": [ { "Name": "metric_number", "Type": "int" }, { "Name": "metric_status", "Type": "string" }, { "Name": "date", "Type": "timestamp" } ] } } ``` application/json Copy ``` { "name": "pipe01", "verbose_name": "Pipeline 01", "dataset": { "columns": [ { "Name": "IMPORT_COMPLETED", "Type": "int" }, { "Name": "ONBOARDING_STARTED", "Type": "int" }, { "Name": "CLASSIFICATION_STARTED", "Type": "int" }, { "Name": "CLASSIFICATION_COMPLETED", "Type": "int" }, { "Name": "EXTRACTION_COMPLETED", "Type": "int" }, { "Name": "ONBOARDING_COMPLETED", "Type": "int" }, { "Name": "EXPORT_COMPLETED", "Type": "int" }, { "Name": "DELIVER_COMPLETED", "Type": "int" }, { "Name": "date", "Type": "timestamp" } ] } } ``` application/json Copy ``` { "name": "myhealth01", "verbose_name": "My Health 01", "job": { "definition": { "StartAt": "Start", "States": { "Start": { "Data": { "date": "2022-08-18", "pipeline_name": "myhealth01", "product_name": "Pre-Approval" }, "Next": "LatestData", "Type": "MockData" }, "LatestData": { "ExceptNext": "Health", "Method": "GET", "Next": "Health", "Path": "console-pipeline/pipelines/{pipeline_name}/data/latest?sort_column=created_at", "PathParameters": { "pipeline_name": "$.outputs.Start.pipeline_name" }, "Projection": { "created_at": "$jmespath.created_at | date_format(@, '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d')" }, "Type": "InvokeProduct" }, "Health": { "Method": "GET", "Next": "SaveData", "Path": "code-health-checker/performance/metrics/products/{product_name}?start_date={start_date}&end_date={end_date}&status=failed", "PathParameters": { "end_date": "$jmespath.outputs.LatestData.response_payload.created_at || outputs.Start.date", "product_name": "$.outputs.Start.product_name", "start_date": "$jmespath.outputs.LatestData.response_payload.created_at || outputs.Start.date" }, "Projection": { "metrics": "$jmespath.metrics[*].{created_at: date_format(created_at, '%Y-%m-%dT%H:%M:%S.%f','%Y-%m-%d %H:%M:%S'), transaction_id: transaction_id}", "next": "$.next_token" }, "Type": "InvokeProduct" }, "SaveData": { "End": true, "Method": "POST", "Path": "console-pipeline/pipelines/{pipeline_name}/data", "PathParameters": { "pipeline_name": "$.outputs.Start.pipeline_name" }, "RequestPayload": "$.outputs.Health.response_payload.metrics", "Type": "InvokeProduct" } } }, "trigger_schedule_expression": "rate(1 day)" }, "dataset": { "columns": [ { "Name": "transaction_id", "Type": "string" }, { "Name": "created_at", "Type": "timestamp" } ] } } ``` ##### Response 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" } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `verbose_name` | `string` | Pipeline Verbose Name | | `description` | `string` | Pipeline Description | | `job` | `object` | Pipeline Job | | `definition`required | `object` | Job Definition | | `StartAt`required | `string` | The first state | | `States`required | `object` | Job States | | `STATE_NAME` | `object` | Name of the State | | `trigger_schedule_expression`required | `string` | Pipeline Trigger Schedule Expression | | `triggers` | `array` | Triggers | | `dataset` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `datasets` | `object` | Pipeline Datasets | | `DATASET_NAME` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `product_name` | `string` | Staircase product name | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200` `GET` `/pipelines` #### Get All `get_pipelines` Get All Pipelines ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` | `string` query | `Product Name` | Product Name | ##### Response `200``application/json` 9 fields Success | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `status` | `string` | Pipeline status`COMPLETED``FAILED``IN_PROGRESS` | | `operation` | `string` | Pipeline operation`CREATE``DELETE``REVIEW``ROLLBACK``UPDATE``UPDATE_ROLLBACK` | | `product_name` | `string` | Product name | | `verbose_name` | `string` | Pipeline Verbose name | | `job_name` | `string` | Pipeline Job name | | `job_trigger_names` | `string[]` | Pipeline Job Trigger name | | `created_at` | `string` | Pipeline create date | | `updated_at` | `string` | Pipeline Success update date | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Pipeline `GET` `/pipelines/{name}` #### Get One `get_pipeline` Get pipeline Retrieve pipeline information, such as: - `status` - `job_name` - `job_trigger_names` ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 9 fields Success | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `status` | `string` | Pipeline status`COMPLETED``FAILED``IN_PROGRESS` | | `operation` | `string` | Pipeline operation`CREATE``DELETE``REVIEW``ROLLBACK``UPDATE``UPDATE_ROLLBACK` | | `product_name` | `string` | Product name | | `verbose_name` | `string` | Pipeline Verbose name | | `job_name` | `string` | Pipeline Job name | | `job_trigger_names` | `string[]` | Pipeline Job Trigger name | | `created_at` | `string` | Pipeline create date | | `updated_at` | `string` | Pipeline Success update date | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `DELETE` `/pipelines/{name}` #### Delete One `delete_pipeline` Delete pipeline ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `GET` `/pipelines/{name}/config` #### Get Config `get_pipeline_config` Retrieve Pipeline configuration. Can and should be used to be able to Update Pipeline. ##### Response application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 7 fields Success | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Pipeline Name | | `verbose_name` | `string` | Pipeline Verbose Name | | `description` | `string` | Pipeline Description | | `job` | `object` | Pipeline Job | | `definition`required | `object` | Job Definition | | `StartAt`required | `string` | The first state | | `States`required | `object` | Job States | | `STATE_NAME` | `object` | Name of the State | | `trigger_schedule_expression`required | `string` | Pipeline Trigger Schedule Expression | | `triggers` | `array` | Triggers | | `dataset` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `datasets` | `object` | Pipeline Datasets | | `DATASET_NAME` | `object` | Pipeline Dataset | | `columns`required | `array` | Columns | | `calculated_columns` | `array` | Calculated Columns | | `product_name` | `string` | Staircase product name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `404` `GET` `/pipelines/{name}/datasets` #### Get Datasets `get_pipeline_datasets` Retrieve Pipeline datasets ##### Response application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200``404` ### Pipeline Dashboards `GET` `/pipelines/{name}/dashboards` #### Get Dashboards `get_pipeline_dashboards` Get embedded link for pipeline dashboards. Going to return pipeline the links to all the dashboards. Response includes: - `id` - Dashboard ID - `name` - Dashboard name - `embedded_url` - Embedded URL. Links are QuickSight native with a temporary authentication token. So they can not be used for permanent share. - `public_url` - Public URL. This is a permanent link that can be used to share Dashboard outside the Staircase. It is good idea to use `embedded_link` inside a web page or web application that have authentication. Important, `public_url` can be used without `API_KEY`. Please do not share it if Dashboard has sensitive data. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Dashboard ID | | `name`required | `string` | Dashboard name | | `embedded_url`required | `string` | Embedded URL | | `public_url`required | `string` | Public URL | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Pipeline Data `DELETE` `/pipelines/{name}/data` #### Delete Data `delete_data` Delete Data from the Pipeline. After this operation Count Data should return zero. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `POST` `/pipelines/{name}/data` #### Put Data `put_data` Put data Put data will take an array of objects and push them into the pipeline. This endpoint is an alias of Pipeline Datasets Data / Put Data where `dataset_name` is `main`. Put Data endpoint does NOT override data. Instead, it is going to append data in the request payload with the data present in the pipeline. There is no predefined JSON schema for this operation. Objects that are in the arrays should be: Show the rest - Plain objects - Should correspond to `dataset` columns definition of the Pipeline Only data that is defined in the `dataset` columns will be saved in the pipeline. Known limits are: - Put data MAX array size 500 elements Example of data being generated ``` curl --location --request POST '' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --header 'x-api-key: ' ``` #### Default values for columns It is possible to specify default values for columns. Can be provider as a `key=value` in the query parameters For examplem having dataset specified as ``` { "columns": [ { "Name": "start_date", "Type": "timestamp" }, { "Name": "stop_date", "Type": "timestamp" }, { "Name": "transaction_id", "Type": "string" }, { "Name": "time_spent_seconds", "Type": "float" }, { "Name": "status", "Type": "string" }, { "Name": "name", "Type": "string" }, { "Name": "flow_name", "Type": "string" } ] } ``` It is possible to set `flow_name` be `$.request_payload.pipeline_name` if it is null ``` { "Method": "POST", "End": true, "Path": "console-pipeline/pipelines/{pipeline_name}/data?flow_name={flow_name}", "PathParameters": { "pipeline_name": "$.request_payload.pipeline_name", "flow_name": "$.outputs.Start.flow_names[0]" }, "RequestPayload": "$jmespath.outputs.response_payload.results", "Type": "InvokeProduct" } ``` #### Savings one row Pipeline Put Data accepts an array of objects. To save one row it is possible to do one of following: - Prepare data as an array of one object - Use JMESPath Pipe expressions and arrays, for example `$jmespath.outputs.Pipelines.response_payload | [@]` Example of SaveData, saving only one row to a Pipeline ``` { "Save": { "Type": "InvokeProduct", "Method": "POST", "Path": "console-pipeline/pipelines/{pipeline_name}/data", "PathParameters": { "pipeline_name": "$.request_payload.pipeline_name" }, "RequestPayload": "$jmespath.outputs.Pipelines.response_payload | [@]", "End": true } } ``` #### Returns This operation usually returns: ``` { "message": "ok" } ``` This means data was accepted by the pipeline, but it does NOT guarantee data will be saved in the Dataset. If data was not saved to Dataset: - most probably, there are problems with data format - `timestamp` fields have wrong formats - `int` fields be a string instead on integer Important note, it may take 10-30 seconds for pipeline to consume and save data. ##### Request PutDemoDataPutDemoDataWithMilliseconds application/json Copy ``` [ { "metric_number": 100, "metric_status": "SUCCESS", "date": "2022-08-15 23:23:23" } ] ``` application/json Copy ``` [ { "metric_number": 100, "metric_status": "SUCCESS", "date": "2022-08-15 23:23:23.123" } ] ``` ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | | `column_name` | `string` query | `Value` | Column default value | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `GET` `/pipelines/{name}/data/count` #### Count Data `count_data` Get data count in the pipeline ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `count`required | `integer` | Count | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `GET` `/pipelines/{name}/data/latest` #### Latest Data `latest_data` Get the latest data object from the pipeline. It is required to specify `sort_column` to allow data be sorted and latest be returned. To avoid data duplicates and unnecessary operations, it is a good practice to use The Latest Data endpoint inside a Job before extracting data from a Staircase product. It is a good idea to filter data by date when extracting it from a Staircase product. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `sort_column` required | `string` query | `date` | Sort Column | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` ### Pipeline Dataset Data `POST` `/pipelines/{name}/datasets/{dataset_name}/data` #### Put Data `put_dataset_data` Put data Put data to a dataset. Dataset should be defined in the Pipeline configuration in the `datasets`. Read Pipeline Put Data for more information. ##### Request PutDemoDataPutDemoDataWithMilliseconds application/json Copy ``` [ { "metric_number": 100, "metric_status": "SUCCESS", "date": "2022-08-15 23:23:23" } ] ``` application/json Copy ``` [ { "metric_number": 100, "metric_status": "SUCCESS", "date": "2022-08-15 23:23:23.123" } ] ``` ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | | `dataset_name` required | `string` path | `ExampleDatasetName` | Dataset Name | | `column_name` | `string` query | `Value` | Column default value | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `DELETE` `/pipelines/{name}/datasets/{dataset_name}/data` #### Delete Data `delete_dataset_data` Delete Data from the Pipeline dataset. Read Pipeline Delete Data for more information. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | | `dataset_name` required | `string` path | `ExampleDatasetName` | Dataset Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `GET` `/pipelines/{name}/datasets/{dataset_name}/data/count` #### Count Data `count_dataset_data` Get data count in the pipeline dataset. Read Pipeline Count Data for more information. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | | `dataset_name` required | `string` path | `ExampleDatasetName` | Dataset Name | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `count`required | `integer` | Count | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `GET` `/pipelines/{name}/datasets/{dataset_name}/data/latest` #### Latest Data `latest_dataset_data` Get the latest data object from the pipeline dataset. Read Pipeline The Latest Data for more information. ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `sort_column` required | `string` query | `date` | Sort Column | | `name` required | `string` path | `pipeline_name` | Pipeline Name | | `dataset_name` required | `string` path | `ExampleDatasetName` | Dataset Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` ### Pipeline Debug `POST` `/pipelines/{name}/run-job` #### Run Pipeline Job `run_pipeline_job` Run Pipeline Job. It is possible to run pipeline job with `pipeline_name`. `requestBody` is optional, but can contain data similar to `triggers` request_payload ##### Request application/json Copy ``` { "mp_host": "marketplace.staircaseapi.com", "mp_key": "API_KEY", "comply_auth": "TOKEN", "comply_host": "compliance-auth.comply-authentication.staircaseapi.com" } ``` ##### Response 200400403 application/json Copy Success ``` { "execution_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "job_name": "job_name" } ``` application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `execution_id` | `string (ulid)` | Job Execution IDExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `job_name` | `string` | Job Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `GET` `/pipelines/{name}/error-logs` #### Get Error Logs `get_pipeline_error-logs` Retrieve Pipeline Error Logs ##### Response application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200``404` ### Account `GET` `/quicksight` #### Status `quicksight_get` Get QuickSight status Expected response ``` { "status": "ACCOUNT_CREATED" } ``` ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `status` | `string` | QuickSight Status | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `POST` `/quicksight` #### Activate `quicksight_activate` Activate QuickSight account ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` `DELETE` `/quicksight` #### Delete `quicksight_delete` Delete QuickSight account ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` ### Chat `POST` `/service-message` #### Send message to Chat `sendMessage` Chat This endpoint allows to send a message to user in Chat product. ##### Request application/json Copy ``` { "connection_id": "WbETDfY8IAMCE8A=", "message_id": "b2QlQarRO8" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `connection_id` | `string` | The identifier of connection | | `message_id` | `string` | The message identifier | ##### Response `201``application/json` 2 fields Assistant created | Field | Type | Description | | --- | --- | --- | | `connection_id` | `string` | The identifier of connection | | `message_id` | `string` | The message identifier | ##### Other responses `400``403``404` ### Setup `POST` `/sign_in` #### Sign In `sign-in` Sign in. Sign in the credentials ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response 200400401403500502 application/json Copy OK. ``` { "id_token": "xxxxxx", "refresh_token": "", "token_type": "yyyyyy" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 3 fields OK. | Field | Type | Description | | --- | --- | --- | | `id_token` | `string` | The ID token. | | `refresh_token` | `string` | The refresh token. | | `token_type` | `string` | The token type. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Proxy `POST` `/trust_score` #### Get Trust Score `get_configuration` This endpoint serves as a proxy to the Get Trust Score api that allows bypassing api_key authorization, yet, is limited in domains that can access it. ##### Request application/json Copy ``` { "phone_number": "8167434789", "transaction_id": "01H3YA4JVJ3ZF3M41NXK9PA27T" } ``` ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `phone_number`required | `string` | Valid Phone Number | | `birth_date` | `string` | Should follow YYYY-MM-DD format. | | `transaction_id`required | `string` | Transaction ID | | `console_configuration_id` | `string` | Console app configuration ID | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Invocation ID | ##### Other responses `403``422` `POST` `/identity` #### Get Identity `get_identity` This endpoint serves as a proxy to the Get Identity api that allows bypassing api_key authorization, yet, is limited in domains that can access it. ##### Request application/json Copy ``` { "phone_number": "8167434789", "birth_date": "1990-01-01", "transaction_id": "01H3YA4JVJ3ZF3M41NXK9PA27T" } ``` ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `phone_number`required | `string` | Valid Phone Number | | `birth_date`required | `string` | Should follow YYYY-MM-DD format. | | `transaction_id`required | `string` | Transaction ID | | `console_configuration_id` | `string` | Console app configuration ID | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Invocation ID | ##### Other responses `403``422` `POST` `/{api_name}/invocations/{id}` #### Get Invocation Status `get_invocation_status` This endpoint serves as a proxy to the Get Invocation Status of Identity apis, referenced by the api_name and identifer of the invocation. `api_name` should be one of ['trust_score', 'identity']. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `api_name` required | `string` path | `trust_score` | Identity api name | | `id` required | `string` path | `01H3FP37TVHBY7R9C1013BDGM5` | Invocation ID | ##### Other responses `200``403``422` ### Connection Proxy `POST` `/vendors/{vendor_name}/flows/{flow_name}/jobs` #### Invoke Connection Flow `invoke_connection_flow` This endpoint serves as a proxy to the Invoke Partner Flow api that allows bypassing api_key authorization, yet, is limited in domains that can access it. List of flows that can be invoked with this proxy is also limited and pre-defined. Please, refer to documentation of original endpoint for the request and response schemas. ##### Request application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "callback_url": "https://webhook.site/2c40525f-69ec-485f-a79a-7256406e8da4", "request_payload": {} } ``` ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `vendor_name` required | `string` path | `prove` | Vendor name | | `flow_name` required | `string` path | `get_trust_score` | Flow name | ##### Response `202``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | Invocation ID | | `job_status` | `string` | Job status | ##### Other responses `403``422` `POST` `/vendors/{vendor_name}/flows/{flow_name}/jobs/{job_id}` #### Get Invocation Status `get_invocation_status` This endpoint serves as a proxy to the Retrieve Flow Execution Status. Please, refer to original documentation for request and response schemas. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `vendor_name` required | `string` path | `prove` | Vendor name | | `flow_name` required | `string` path | `get_trust_score` | Flow name | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Job invocation ID | ##### Other responses `200``403``422` ### Datalake Data `POST` `/datalakes/{name}/data` #### Put Data `put_datalake_data` Put data Put data will the data from valid Staircase collection. Known limits are: - Put data MAX array size 500 elements Important note, it may take 10-30 seconds for pipeline to consume and save data. ##### Request application/json Copy ``` [ { "metric_number": 100, "metric_status": "SUCCESS", "date": "2022-08-15 23:23:23" } ] ``` ##### Response 400403 application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `pipeline_name` | Pipeline Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `200``404` ## Errors `400``401``403``404``422``500``502` ## Notes The catalogue records no narrative row for this slot. What appears above is read from the recorded build documentation and from the operation set. The component inventories — several hundred records naming each component, its properties and its content-system shape — are internal build material and are not published. ## More in Distribution - Previous product: Access - Next product: Environment --- # Environment # Environment Creating, configuring, cost-tracking, budgeting and tearing down a dedicated cloud environment over HTTP. An environment here is a whole cloud account, not a namespace: its own domain, its own certificates, its own API key, its own stack set. It is created, configured, metered against a budget and destroyed through calls. Teardown is a first-class path with scripted removal of stacks, storage and identity, rather than an operational runbook someone follows by hand. ## How it works Cost attribution reaches down to individual model conversations and up to a per-environment budget. Metering at that granularity is what makes a budget enforceable instead of advisory — a budget that can only be checked after the invoice arrives cannot stop anything. A configuration check returns a vector of policy answers rather than a pass or fail, so an environment that is out of policy names which control it fell out of. ## Operations ### Activate Key `POST` `/activate-key` #### Activate Key for Environment `activateKey` Activate key used to activate a key for being used in the environment. ##### Request application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string` | X-api-key to be activated in the environmentExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `200``application/json` 3 fields Key activated. | Field | Type | Description | | --- | --- | --- | | `fqdn`required | `string` | Fully qualified domain name of the environment where the key was activated. | | `status`required | `string` | Status of the key activation. | | `message`required | `string` | Message about the key activation. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `500``application/json` 1 fields Key Activation error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Other responses `403` ### Budgets `PUT` `/budgets/{fqdn}` #### Update environment budget `updateBudget` This API allows the Staircase Finance team to update the budget of a given environment. ##### Request application/json Copy ``` { "products": [ { "product_name": "Language", "monthly_budget": 1500 }, { "product_name": "Batch", "monthly_budget": 750 }, { "product_name": "Datalake", "monthly_budget": 750 } ] } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY received via email upon account creation | | `fqdn` required | `string` path | `example.staircaseapi.com` | Environment fully qualified domain name. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `products`required | `object[]` | List of products and their monthly budget. | | `product_name`required | `string` | Name of the product.Example `Environment` | | `monthly_budget`required | `number` | Monthly budget for the product.Example `1000` | ##### Response `201``application/json` 3 fields Environment creation In-progress. | Field | Type | Description | | --- | --- | --- | | `domain_name`required | `string` | Fully qualified domain name of the environment. | | `monthly_budget`required | `object` | Monthly budget for the environment. | | `products` | `object[]` | List of products and their monthly budget. | | `product_name`required | `string` | Name of the product.Example `Environment` | | `monthly_budget`required | `number` | Monthly budget for the product.Example `1000` | | `last_update_datetime`required | `string` | Last update time stamp. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `PUT` `/budgets` #### Create or update budget for products owned by team `createOrUpdateTeamBudget` Create or update team budget This API manages and monitors daily spending on products for each company by storing budget information and summing all related spending per company and product. If spending exceeds the budget, it sends alerts to the company’s Slack #alerts-negative channel for each additional dollar spent. ##### Request application/json Copy ``` { "budget_per_day": 25, "product_identifier": "c20994b0-be01-4421-a075-8dcea035d155", "company_identifier": "01G52C9RCP0Q5C6JYEPE4487VV" } ``` ##### Response 200400 application/json Copy Environment creation In-progress. ``` { "budget_per_day": 25, "product_identifier": "c20994b0-be01-4421-a075-8dcea035d155", "company_identifier": "01G52C9RCP0Q5C6JYEPE4487VV" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY received via email upon account creation | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `budget_per_day`required | `number` | US dollars per day.Example `25` | | `product_identifier`required | `string` | Product identifier.Example `c20994b0-be01-4421-a075-8dcea035d155` | | `company_identifier`required | `string` | Company identifier fromExample `01G52C9RCP0Q5C6JYEPE4487VV` | ##### Response `200``application/json` 3 fields Environment creation In-progress. | Field | Type | Description | | --- | --- | --- | | `budget_per_day`required | `number` | US dollars per day.Example `25` | | `product_identifier`required | `string` | Product identifier.Example `c20994b0-be01-4421-a075-8dcea035d155` | | `company_identifier`required | `string` | Company identifier fromExample `01G52C9RCP0Q5C6JYEPE4487VV` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ### Costs `GET` `/costs` #### Retrieve product costs `getProductCosts` Retrieve the detailed product costs across the organization. Due to the monthly billing cycle, the values will change until the end of the month is reached, and the final adjustments are applied. The authorization access token for using this service can be obtained from Comply Authentication ##### Response 200400 application/json400 text/html application/json Copy Response body with the detailed costs of a given product across all environments. ``` { "total_cost": "$ 1785.4194 USD", "costs_unit": "USD", "total_cost_raw": 1785.4194, "product_name": "Test", "environments_count": 330, "average_environment_cost": 5.4104, "costs_by_environment": [ { "costs": 146.4983, "organization_id": "01G5XXXXXXXXXX93E41X70MXS", "environment_domain": "my-subdomain.staircaseapi.com" } ], "costs_by_service": [ { "aws_service": "Amazon EC2 Container Registry (ECR)", "cost": 654.9967 }, { "aws_service": "AWS Key Management Service", "cost": 318.5916 }, { "aws_service": "Amazon Simple Storage Service", "cost": 13.0348 }, { "aws_service": "AWS Lambda", "cost": 7.3645 }, { "aws_service": "AWS WAF", "cost": 5.8065 }, { "aws_service": "Amazon DynamoDB", "cost": 1.9304 }, { "aws_service": "AmazonCloudWatch", "cost": 0.6591 }, { "aws_service": "Amazon Simple Queue Service", "cost": 0.5514 }, { "aws_service": "CodeBuild", "cost": 0 } ], "costs_by_period": [ { "time_period": "2022-08-01-2022-08-02", "cost": 70.3507 }, { "time_period": "2022-08-02-2022-08-03", "cost": 76.8517 } ] } ``` application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token. | | `product_name` required | `string` query | `Environment` | Product name | | `start_date` required | `string` query | `2022-01-01` | start date for the time range | | `end_date` required | `string` query | `2022-01-31` | end date for the time range | ##### Response `200``application/json` 8 fields Response body with the detailed costs of a given product across all environments. | Field | Type | Description | | --- | --- | --- | | `total_costs`required | `string` | Formatted total costs for the given product name. | | `costs_unit`required | `string` | Unit for the costs values. | | `total_costs_raw`required | `number` | Total costs for the given product name. | | `environments_count`required | `number` | Number of environments in which the product is deployed. | | `average_environment_cost`required | `number` | Average cost per environments. | | `costs_by_environment`required | `object[]` | List of Product costs per environment | | `product_by_environment_costs` | `object` | Data object containing the Product costs per environment | | `environment_domain` | `string` | Domain of the environment | | `costs` | `number` | Product costs of the environment | | `organization_id` | `string` | Domain of the environment | | `costs_by_service`required | `object` | Product costs by AWS service | | `costs_by_period` | `object` | Product costs by day | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/environment-costs/{api_key}` #### Retrieve environment costs `getEnvironmentCosts` Retrieve environment costs. When resource_details is set to true, the output will show the costs detailed by service instead of the component. Due to the monthly billing cycle, the values will change until the end of the month is reached, and the final adjustments are applied. This service only provides data for last 14 days. The authorization access token for using this service can be obtained from Comply Authentication ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token. | | `api_key` required | `string` path | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for the environment to query | | `start_date` required | `string` query | `2022-01-01` | start date for the time range | | `end_date` required | `string` query | `2022-01-31` | end date for the time range | | `resource_details` | `boolean` query | `true` | If enabled it will show the Environment resources usage detail, resource details cannot be used with more that 14 days old dates. | ##### Response `200``application/json` 4 fields Response body with the list of stacks deployed in a given environment. | Field | Type | Description | | --- | --- | --- | | `unit`required | `string` | Currency | | `total_cost`required | `string` | Total cost for the given environment. | | `time_range`required | `object` | Time range queried. | | `start_date`required | `string` | Start date for the time range queried | | `end_date`required | `string` | End date for the time range queried | | `usage_details`required | `object[]` | Usage details of the environment by stack name. | | `service`required | `string` | Name of the resource service. | | `cost`required | `string` | Total cost generated by the resource. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` ### EnvironmentCosts `POST` `/costs` #### Save Costs `save-costs` For tracking non AWS related costs. Use this API for reporting usage of external services that are not tracked by AWS. For example, this API is used by the Bot product to report the price of conversation for specific bot. ##### Request application/json Copy ``` { "usage": 3, "name": "Personal Identity Collector", "invocation_id": "1234567890" } ``` ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `usage`required | `number` | Usage of the external service, in US Cents.Example `100` | | `name`required | `string` | Name of the external service.Example `Personal Identity Collector` | | `invocation_id` | `string` | Unique identifier for the invocation of the external service. | ##### Response `200``application/json` 1 fields Response body with confirmation of the saved costs. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Confirmation message. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ### Environment `POST` `/environment` #### Create Environment `createEnvironment` Create environment This service allows you to create a staircase environment for with a given subdomain. You can also include a callback URL with an optional payload to get notified automatically after your environment creation is finished; After the environment is created it is subscribed to Environment and Deploy products automatically. - Callback payload request example: ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "subdomain": "my-env", "organization_id": "26d4253f8509" "callback_url": "", "callback_payload": {"callback_id":"identifier_callback"} } ``` - Callback payload response example: ``` { "environment_status": "ACTIVE", "environment_fqdn": "my-env.staircaseapi.com", "message": "Environment ready to use", "callback_payload": {"callback_id":"identifier_callback"} } ``` ##### Request application/json Copy ``` { "subdomain": "mysubdomain", "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "organization_id": "26d4253f8509", "callback_url": "https://mycallbak_url.com/callback_url", "callback_payload": { "callback_id": "identifier_callback" } } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY received via email upon account creation | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `subdomain`required | `string` | Subdomain for the New Staircase environment.Example `marketplace` | | `api_key`required | `string (uuid)` | API-KEY received via email upon account creationExample `` | | `organization_id` | `string` | Organization ID to which the account belongs toExample `b665gncdb891` | | `callback_url` | `string` | Callback URL POST endpoint to be called upon environment creation completionExample `https://mycallbak_url.com/callback_url` | | `callback_payload` | `object` | User defined payload to be sent to the callback URL suppliedExample `{'callback_id':'identifier_callback'}` | ##### Response `201``application/json` 2 fields Environment creation In-progress. | Field | Type | Description | | --- | --- | --- | | `staircase_environment`required | `object` | Staircase Environment creation status. | | `api_key`required | `string` | Unique identifier for the environment. | | `status_url`required | `string` | URL for checking the status while it's not Active. | | `status`required | `string` | Status of the environment creation. | | `message`required | `string` | Status description message. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `PUT` `/environment` #### Update Environment Data `updateEnvironmentData` This service allows you to update the environment data such as organization ID ##### Request application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "organization_id": "26d4253f8509" } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY received via email upon account creation | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string (uuid)` | API-KEY received via email upon account creationExample `` | | `organization_id`required | `string` | Organization ID to which the account belongs toExample `b665gncdb891` | ##### Response `200``application/json` 2 fields Environment Data Update. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Status description message. | | `status`required | `string` | Status of the operation executed | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `DELETE` `/environment` #### Disable Environment `disableEnvironment` This service allows you to disable a given environment. Disabling an environment will delete all the resources in it and the environment will not be recoverable The authorization access token for using this service can be obtained from Comply Authentication The token requires an admin level permission ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Account-key received via email upon account creation. | | `environment_fqdn` required | `string` query | `my-env.staircaseapi.com` | Fully qualified domain name of the staircase environment. | ##### Response `200``application/json` 2 fields Environment Data Update. | Field | Type | Description | | --- | --- | --- | | `environment_fqdn`required | `string` | Fully qualified domain name of the environment. | | `organization_id`required | `string` | Organization ID of the queried environment. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/environment` #### Get Environment Data `getEnvironmentData` This service allows you to retrieve the environment data such as organization ID ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Account-key received via email upon account creation. | | `environment_fqdn` required | `string` query | `my-env.staircaseapi.com` | Fully qualified domain name of the staircase environment. | ##### Response `200``application/json` 5 fields Environment Data Update. | Field | Type | Description | | --- | --- | --- | | `environment_fqdn`required | `string` | Fully qualified domain name of the environment. | | `organization_id`required | `string` | Organization ID of the queried environment. | | `environment_owner`required | `string` | Owner email of the queried environment. | | `company_name`required | `string` | Company name of queried environment. | | `last_updated_at`required | `string` | When environment was updated. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `DELETE` `/environment/delete` #### Clean Environment `disableEnvironment` This service allows you to clean a given environment. Cleaning an environment will delete all the resources in it and the environment will not be recoverable ##### Request application/json Copy ``` { "target_account_id": "123456789033" } ``` ##### Response application/json Copy Request data invalid ``` { "message": "target_account_id must be provided." } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `target_account_id`required | `string` | AWS account ID of the environment to be cleaned. The account ID must be a 12-digit number within Staircase organization. | | `callback_url` | `string (uri)` | URL to be called when the cleaning process is complete. The URL must be accessible from the internet.s | | `resources_to_retain` | `object` | Object specifying arrays of S3 and Glue resources to be retained during cleanup. Each array contains objects representing individual resources. A report will be generated post-cleanup detailing retained and removed resources. In case of errors in retaining a specified resource, the user will be notified for manual intervention. | | `S3` | `object[]` | Array of objects, each representing an S3 bucket name to be retained. | | `bucket_name`required | `string` | Name of the S3 bucket to be retained. | | `Glue` | `object[]` | Array of objects, each representing a Glue resource to be retained. | | `database_name`required | `string` | Name of the Glue database to be retained. | | `IAMUser` | `string` | IAM User to be retained. | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `job_id`required | `string` | ID of the cleaning job.Example `01GXQZV8M1V57GEZHK29SR1J3J` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `POST` `/` #### Add region `addRegion` This service allows you to configure new region is this environment, so it will be ready to get Staircase bundles deployed in it WAF distribution will be created. The distribution ID will be available inside the environment token data. api.subdomain.staircaseapi.com custom API GW domain name will be created. {region_name}.subdomain.staircaseapi.com custom API GW domain name will be created. Route53 failover configuration will be created for api.subdomain.staircaseapi.com and used for the health checks managed by the Environment product. Route53 us-east-1.domain.com to direct to API Gateway on us-east-1 ##### Request application/json Copy ``` { "region_name": "us-east-2" } ``` ##### Response 200400 application/json Copy Ok. ``` { "message": "Region added" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `region_name`required | `string` | Region name`us-east-2``us-west-1``us-west-2`Example `us-east-2` | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | message | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/stacks/{api_key}` #### Retrieve environment products `getProductsDeployed` Retrieve the environment products Get environment components Fetch list of deployed components in a given environment. The authorization access token for using this service can be obtained from Comply Authentication ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token. | | `api_key` required | `string` path | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API-KEY | ##### Response `200``application/json` 1 fields Response body with the list of stacks deployed in a given environment. | Field | Type | Description | | --- | --- | --- | | `stacks`required | `object[]` | List of stacks in the environment | | `stack_name` | `string` | Name of the stack deployed. | | `stack_status`required | `string` | Current status of the stack. | | `created_at`required | `string` | Creation time stamp. | | `last_updated_at`required | `string` | Last update time stamp. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` ### Hello `POST` `/hello-world` #### Hello `execute_query` Hello World Dummy hello world endpoint ##### Response application/json Copy Ok. ``` { "message": "ok" } ``` ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Hello message.Example `ok` | ### Products `GET` `/product-deployments` #### Retrieve products deployments `getProductDeployments` Retrieve product deployments Retrieve all the environments in which the product is deployed with their Health API KEY. The authorization access token for using this service can be obtained from Comply Authentication ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token. | | `base_path` required | `string` query | `code-tester` | The base path of the product you want to query | ##### Response `200``application/json` 1 fields Response body with the list of environments in which the product is deployed. | Field | Type | Description | | --- | --- | --- | | `environments`required | `object[]` | List of environments with the base path given present. | | `domain_name`required | `string` | Name of the stack. | | `api_key`required | `string` | Health API KEY | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` ### EnvironmentManager `DELETE` `/products` #### Delete deployed product `deleteProductServices` This service triggers the deletion of a given product, if no specific services are given all the services deployed for the given product name will be deleted. Deletion of a given service or services will remove the resources and will cause loss of data. Admin level permissions are necessary for deleting products from a Staircase environment, unless you are the owner of the environment. The authorization access token for using this service can be obtained from Comply Authentication ##### Request application/json Copy ``` { "product_name": "Test", "services": [ { "service_name": "service-code-tester" } ] } ``` ##### Response 201400 application/json Copy Environment creation In-progress. ``` [ { "status": "SUBMITTED" } ] ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Authorization token, obtained through comply service. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `product_name`required | `string` | Name of the product to be deletedExample `Test` | | `services` | `object[]` | List of services to be deleted | | `service_name`required | `string` | Name of the service to be deletedExample `service-code-tester` | ##### Response `201``application/json` 1 fields Environment creation In-progress. | Field | Type | Description | | --- | --- | --- | | `status`required | `string` | Status of the deletion.Example `SUBMITTED` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Environment creation failure. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/products` #### Get Deployed Products `getDeployedProducts` Retrieve the products deployed in the environment Get deployed products Retrieves a list of the products deployed in the environment with their respective components. The authorization access token for using this service can be obtained from Comply Authentication ##### Response 200400 application/json Copy Response body with the list of products and services deployed in the staircase environment. ``` [ [ { "product_name": "Environment", "services": [ { "service_name": "environment-manager", "status": "UPDATED" }, { "service_name": "environment-administrator", "status": "UPDATED" } ] } ] ] ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Authorization token, obtained through comply service. | ##### Response `200``application/json` 2 fields Response body with the list of products and services deployed in the staircase environment. | Field | Type | Description | | --- | --- | --- | | `product_name`required | `string` | Product Name deployed in the staircase environment. | | `services`required | `object[]` | List of services attached to the product. | | `status`required | `string` | Deployment status of the service. | | `service_name`required | `string` | Name of the service deployed. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Product not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/products/{product_name}` #### Get Deployed Product `getDeployedProductServices` Retrieve the details of a product deployed in the environment Get deployed products Retrieves the list of services deployed containing status and service name for the product name given, as log as it is deployed in the staircase environment. The authorization access token for using this service can be obtained from Comply Authentication ##### Response 200400 application/json Copy Response body with the list of services deployed in the staircase environment for the provided product name. ``` [ [ { "service_name": "environment-manager", "status": "UPDATED" }, { "service_name": "environment-administrator", "status": "UPDATED" } ] ] ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Authorization token, obtained through comply service. | | `product_name` required | `string` path | `Environment` | Name of the product to query | ##### Response `200``application/json` 2 fields Response body with the list of services deployed in the staircase environment for the provided product name. | Field | Type | Description | | --- | --- | --- | | `status`required | `string` | Deployment status of the service. | | `service_name`required | `string` | Name of the service deployed. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/service-key` #### Get Service Key `get-service-key` Get service key Environment service API-KEY can be used for retrieving telemetry data. Health product accepts it as X-API-KEY header, enabling products and teams to querying metrics for products deployed in the environment. The authorization access token for using this service can be obtained from Comply Authentication ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token, obtained through comply service. | ##### Response `200``application/json` 1 fields Response body with the environment status and, environment details | Field | Type | Description | | --- | --- | --- | | `service_key`required | `string` | UUID value of the service key. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Service key error. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/budgets` #### Get Budgets `get-budgets-list` List of currently applied budgets for this environment. List of currently applied budgets for this environment. It calculates only for resources tagged with "sc:product:name" tag with this value. Budget is always monthly. ##### Response `200``application/json` 1 fields Response body with the environment current budgets per product. | Field | Type | Description | | --- | --- | --- | | `budgets` | `object[]` | List of budgets per product. | | `product`required | `string` | Product name. It calculates only for resources tagged with "sc:product:name" tag with this value. | | `amount`required | `string` | Budget amount in US Dollars per month. | `PATCH` `/budgets` #### Update Budgets `update-budgets` Update the thresholds for the budgets. Update the threshold for specific products. ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Response `200``application/json` 1 fields Response body with the environment updated budgets. | Field | Type | Description | | --- | --- | --- | | `budgets` | `object[]` | List of budgets per product. | | `product`required | `string` | Product name. It calculates only for resources tagged with "sc:product:name" tag with this value. | | `amount`required | `string` | Budget amount in US Dollars per month. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ### Reports `GET` `/reports` #### Get Cost Reports `getCostReports` Provides reports about AWS costs produced by Staircase Products deployed to Staircase Environments. The unit type of the all costs in reports is presented in cents by default. You can change it to "USD" by passing it as a query parameter `costs_unit_type`. If start_date and end_date are not specified, the default date range is the last 30 days. ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `start_date` | `string` query | `2023-01-01` | Start date. | | `end_date` | `string` query | `2023-02-01` | End date. | | `granularity` | `string` query | `DAILY` | Granularity. | | `customer_company_name` | `string` query | `Bank Of America` | Customer company name. Case insensitive. | | `staircase_team` | `string` query | `Cerf` | Staircase team name. Case insensitive. | | `costs_unit_type` | `string` query | `USD` | Costs unit type. If not specified, the default unit type is CENT. | ##### Response `200``application/json` 5 fields Response body | Field | Type | Description | | --- | --- | --- | | `date_range`required | `object` | The date range for which the report is applicable. | | `start`required | `string` | The start date of the range in YYYY-MM-DD format. | | `end`required | `string` | The end date of the range in YYYY-MM-DD format. | | `costs_unit_type`required | `string` | The unit type of costs in reports.`CENT``USD`Example `USD` | | `granularity` | `string` | The dates granularity of the report.`DAILY``MONTHLY``NONE`Example `DAILY` | | `products`required | `object[]` | A list of Staircase products included in the report. Data bundles are united to a single "Data Bundles" product. | | `product_name` | `string` | The name of the product. | | `reports`required | `object[]` | A collection of cost reports, each corresponding to a single time period. If 'granularity' query parameter is not NONE, it might contain more than one report object. | | `type`required | `string` | The type of report.`COSTS_PER_ENVIRONMENT_PER_PRODUCT` | | `date_range` | `object` | The date range for which the report is applicable. | | `start`required | `string` | The start date of the range in YYYY-MM-DD format. | | `end`required | `string` | The end date of the range in YYYY-MM-DD format. | | `result`required | `object[]` | An array of results, each representing a different environment. | | `environment`required | `string` | The name or identifier of the environment. | | `total_cost`required | `integer` | The total cost associated with this environment. | | `costs_per_product_sum`required | `integer` | The sum of costs broken down per product. | | `costs_per_product`required | `object` | A breakdown of costs per product. | | `unknown_product_cost`required | `integer` | Costs associated with unknown or unclassified products. | | `staircase_team`required | `string` | The name of the Staircase team owning the environment. | | `customer_company_name`required | `string` | The name of the customer company owning the environment. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ### Configurations `POST` `/update-configurations` #### Update configurations `update-configurations` Update Configurations Update environment configurations validates the latest configurations of the environment and if they are not up-to-date it updates them. ##### Request application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Authorization token, obtained through comply service. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string (uuid)` | API-KEY received via email upon account creationExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `201``application/json` 1 fields Environment creation In-progress. | Field | Type | Description | | --- | --- | --- | | `staircase_environment` | `object` | Staircase Environment creation status. | | `status`required | `string` | Status of the environment configurations update process.`UPDATED``UPDATE_FAILED``UPDATING` | | `message`required | `string` | Information message for the given status | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Environment creation failure. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/get-configurations/{api_key}` #### Get configurations `get-configurations` Get the environment configurations Fetch the status of the environment configurations. ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Authorization token, obtained through comply service. | | `api_key` required | `string` path | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API-KEY | ##### Response `200``application/json` 11 fields Response body with the environment status and, environment details | Field | Type | Description | | --- | --- | --- | | `MFA_Enabled`required | `string` | Status of the user with MFA_Enabled configuration.`MISSING``OK` | | `Login_Restricted`required | `string` | Status of the AWS console login restriction.`MISSING``OK` | | `Main_Certificate`required | `string` | Status of the Main Certificate configuration.`MISSING``OK` | | `Wild_Certificate`required | `string` | Status of the Wild Certificate configuration.`MISSING``OK` | | `Email_Domain`required | `string` | Status of the Email Domain configuration.`MISSING``OK` | | `DKIM_Verification`required | `string` | Status of the DKIM verification.`MISSING``OK` | | `MX_Records`required | `string` | Status of the MX DNS records.`MISSING``OK` | | `API_Gateway`required | `string` | Status of the API GW Configuration.`MISSING``OK` | | `Health_Service_Key`required | `string` | Status of the Health service API key configuration.`MISSING``OK` | | `VPC_Flow_Logs` | `string` | Status of the VPC Flow Log configuration.`MISSING``OK` | | `CloudFront_Distribution`required | `string` | Status of the CloudFront distribution configuration.`MISSING``OK` | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ### Status `GET` `/environment/delete/{id}` #### Retrieve Cleaning Status `getCleaningStatus` Foo ##### Response 400404 text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Cleaning invocation was not found. ``` { "status": "NOT_FOUND" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `490kokf3-aa93-409f-b4e7-756e019d83f5` | The cleaning invocation ID. | ##### Response `200``application/json` 2 fields Cleaning job invocation status. | Field | Type | Description | | --- | --- | --- | | `status`required | `string` | Status of the cleaning job invocation.`FAILED``IN_PROGRESS``NOT_FOUND``RUNNING``SUCCEEDED` | | `logs`required | `string` | Logs of the cleaning invocation. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting an X-API-KEY. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Cleaning invocation was not found. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the cleaning job.`NOT_FOUND` | ### Environment Creator `POST` `/vendors/staircase/flows/env-create/jobs` #### Invoke Create Environment Flow `invokeCreateEnvironmentFlow` This endpoint allows launching Create Environment Flow. It is an asynchronous job, so response contains `job_id`, that allows to track the job's execution here. Result of the job will be sent to the `callback_url` specified in the appropriate field. If job finishes successfully, `job_status` will be "Completed"; `response_payload` will contain the `api_key`, `domain`, `subdomain` and `organization_id`, and it will look like this: Show the rest ``` { "job_id": "e26ffa3d-4ae6-4582-8982-5d61f8a75c54", "job_status": "Completed", "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "request_collection_id": "01F7S0X38J6R41HW279D8YP8KJ", "response_collection_id": "01F7S0YSQPGW9WC51378PR7TM3", "response_payload": { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain": "organization-a1b2c3d4e5f6", "subdomain": "organization-a1b2c3d4e5f6.staircaseapi.com", "organization_id": "4321-4321-4321-4321-4321" } } ``` If job fails to complete, `job_status` will be "Failed" and `response_payload` will contain detailed information about failed job (`Error` and `Cause` fields), and will look like this: ``` { "job_id": "98da2ca6-8fbb-4f00-bde9-91f8b33712f2", "job_status": "Failed", "transaction_id": "01FYRX3TTMKSR6XG070GA3MG17", "request_collection_id": null, "response_collection_id": null, "response_payload": { "Error": "CallVendorError", "Cause": { "errorMessage": { "message": "A company_organization with company \"X\" and organization \"X-org-1\" already exists." }, "errorType": "CallVendorError", "requestId": "77a1db7e-12d4-42f3-887e-82387a2ca8cd" } }, "status_code": null } ``` For testing, you can use webhook.site service. With this, you instantly get a unique, random URL that you can put into the `callback_url` field and use it to receive HTTP requests. ##### Request application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2", "request_payload": { "organization_name": "Org-1", "first_name": "John", "last_name": "Doe", "email": "john.doe@domain.com" } } ``` ##### Response 202400 application/json Copy Request accepted ``` { "job_id": "160701d5-a034-41db-aade-26e4134ac8bb", "job_status": "Started" } ``` application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` query | `environment-creator` | This parameter is required to be `environment-creator`. Anything else would cause a failure | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `request_collection_id` | `string` | Request collection ID | | `response_collection_id` | `string` | Response collection ID | | `callback_url`required | `string (uri)` | Destination URL on which final result of the flow execution will be sent | | `request_payload`required | `object` | Data that have to passed into the flow | | `organization_name`required | `string` | Name of the Organization that Environment will belong to | | `first_name`required | `string` | First Name of the owner of Account that Environment will belong to | | `last_name`required | `string` | Last Name of the owner of Account that Environment will belong to | | `email`required | `string` | Email of the owner of Account that Environment will belong to | ##### Response `202``application/json` 2 fields Request accepted | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | Execution ID | | `job_status` | `string` | Execution status | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner or flow not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `GET` `/vendors/staircase/flows/env-create/jobs/{job_id}` #### Retrieve Create Environment Flow Execution Status `retrieveCreateEnvironmentFlowExecutionStatus` Retrieve flow execution status of Create Environment flow This endpoint allows getting status of the Create Environment Flow. ##### Response 200400 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": { "api_key": "", "domain": "organization-a1b2c3d4e5f6", "subdomain": "organization-a1b2c3d4e5f6.staircaseapi.com", "organization_id": "4321-4321-4321-432" } } } ``` application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Execution ID | | `product_name` required | `string` query | `environment-creator` | This parameter is required to be `environment-creator`. Anything else would cause a failure | | `detailed` | `string` query | `false` | Returns detailed execution history including execution data if set to `true`. Default `false`. | | `next_token` | `string` query | `oei09uo8yr7tvweyuni29eirv9kod` | If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error. | | `reverse_order` | `string` query | `true` | Returns events in ascending order of their timeStamp if set to `false`. Default is descending `true`. | | `max_results` | `integer` query | `100` | The maximum number of results that are returned per call. You can use next-token to obtain further pages of results. The default is 50 and the maximum allowed page size is 1000. This is only an upper limit. The actual number of results returned per call might be fewer than the specified maximum. | ##### Response `200``application/json` 6 fields Execution status successfully retrieved | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Execution status`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` | | `executed_events` | `string[]` | List of executed events | | `last_event` | `string` | Last executed event | | `details` | `object[]` | Executed events details | | `input` | `object` | Short data you used for invoking the flow. | | `transaction_id`required | `string` | Transaction ID | | `request_collection_id`required | `string` | Request collection ID | | `response_collection_id`required | `string` | Response collection ID | | `callback_url`required | `string (uri)` | Destination URL on which final result of the flow execution was configured to be sent | | `output` | `object` | Short data of the output. | | `response_payload`required | `object` | Response payload. | | `api_key` | `string` | — | | `domain` | `string` | — | | `subdomain` | `string` | — | | `organization_id` | `string` | — | | `extraction_errors`required | `one of` | Extraction errors. | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner, flow or execution not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `POST` `/vendors/staircase/flows/env-create/jobs/{job_id}` #### Terminate Create Environment Flow Execution `terminateCreateEnvironmentFlowExecution` Terminate execution of Create Environment Flow This endpoint allows stopping execution of Create Environment Flow. ##### Response 201400 application/json Copy Execution successfully terminated ``` { "job_id": "9348765c-2eda-46d6-9214-7119c175dc5f", "status": "ABORTED", "stop_date": "2021-06-25 13:15:34.447000+03:00" } ``` application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Execution ID | | `product_name` required | `string` query | `environment-creator` | This parameter is required to be `environment-creator`. Anything else would cause a failure | ##### Response `201``application/json` 3 fields Execution successfully terminated | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | Execution job id. | | `status` | `string` | Status of the execution. | | `stop_date` | `string` | Stop date. | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner, flow or execution not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `GET` `/vendors/staircase/flows/env-create/executions` #### List Create Environment Flow Executions `listCreateEnvironmentFlowExecutions` Retrieve flow executions status This endpoint allows getting status of flow executions. ##### Response 200400 application/json Copy Executions list successfully retrieved ``` { "executions": [ { "job_id": "6b54387a-fe7e-4fb0-ad2a-40c70ebd0f1c", "flow_name": "ocrolus-ide-classify-and-extract", "status": "SUCCEEDED", "start_date": "2021-06-25 13:34:56.441000+03:00", "stop_date": "2021-06-25 13:37:31.348000+03:00" }, { "job_id": "a32f4f6b-a906-4b11-9f96-edaf1dcac592", "flow_name": "ocrolus-ide-classify-and-extract", "status": "ABORTED", "start_date": "2021-06-25 13:06:42.681000+03:00", "stop_date": "2021-06-25 13:15:34.447000+03:00" }, { "job_id": "57340187-45f2-41ea-984a-cdc731a2d7f0", "flow_name": "ocrolus-ide-classify-and-extract", "status": "FAILED", "start_date": "2021-06-25 13:02:19.838000+03:00", "stop_date": "2021-06-25 13:11:07.252000+03:00" } ], "next_token": "AAAAKgAAAAIAAAAAAAAAAcsQMPbdXoFFnzT2rEqFsqrT0zHE/qEYZz+7bsEqn/szszKZGF+UqlAFcP48NpKsyXcxMIaopLnNb398gvFSPLP1AeV3K35+eWnxTNf0J8w+v3jiBLuzY/EaIPtvKlsUP7d1ARcA5Z2pppZqUkDNXgOqxMQTZPAbmyBNST+OdPbMylcX275vZ/0X4PyPvxnYgp53L97rJ0JMcQT/2+/Y8NAJQxsUESi00tv9E/glloA4hyvPAuFW6rZL8VY5bU7kh4LiPL9BmOhKaN+0QazQxaJZJmStj6jN2F27v0FpSkyl+ENTy4nZrw40PlRzg6Es8gZjxouPRD9erBiTahioV4lW9jpIu82rXX4N6e6lK5sfN+p68qNorq+F7jp9LokkC3idROMs4iB4OX2rX7YguDIbgg0NZneQndTE+Opph7eXlxMAXMIbxpSgI5TYyCQIP1GjsE66dCPldJBoogFv9IIEnt/38ZLpyOwwQnGVOLw8O/ARwH+Ev52AJIVUGVNqTA==" } ``` application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` query | `environment-creator` | This parameter is required to be `environment-creator`. Anything else would cause a failure | | `next_token` | `string` query | `p9208y937gtyuhoivju38hry0gvy3ruhifnc3kcd` | If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error. | | `status_filter` | `string` query | `ABORTED` | If specified, only list the executions whose current execution status matches the given filter. | | `max_results` | `integer` query | `100` | The maximum number of results that are returned per call. You can use next-token to obtain further pages of results. The default is 50 and the maximum allowed page size is 1000. This is only an upper limit. The actual number of results returned per call might be fewer than the specified maximum. | ##### Response `200``application/json` 2 fields Executions list successfully retrieved | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination token to get next results | | `executions` | `object[]` | List of executions | | `job_id` | `string` | Execution ID | | `flow_name` | `string` | Flow name | | `status` | `string` | Execution status | | `start_date` | `string` | Execution start date | | `stop_date` | `string` | Execution stop date | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner, flow or execution not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | ### Operations `POST` `/activate-auth-token` #### Activate auth token `activate-auth-token` Activates the authentication token on the given environment such token is used for performing operations of management in the environment where the environment product is deployed. IMPORTANT right after deploying environment manager this endpoint should be called, the environment token retrieved by the service should be stored as it is a one time only allowed operation ##### Request application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string (uuid)` | API-KEY received via email upon account creationExample `` | ##### Response `200``application/json` 2 fields Token activated. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Successful token activation message.`Auth Token activated successfully` | | `token`required | `string` | Authorization TokenExample `` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 1 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Environment creation failure. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `POST` `/disable-environment` #### Disable environment `disableEnvironment` Disable environment used to disable and delete all the resources of a staircase environment assigned to the API-KEY provided. ##### Request application/jsonExample application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "subdomain": "environment-manager" } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "subdomain": "mycoolsubdomain" } ``` ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API-KEY for using the endpoint. | | `Authorization` required | `string` header | `` | Authorization token. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string` | API-KEY assigned to the environment to be disabled | | `subdomain`required | `string` | Subdomain assigned to the environment to be disabled | ##### Response `202``application/json` 2 fields Environment disabled. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Disable process status message. | | `status`required | `string` | Status of the disabling process. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 3 fields Unauthorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | | `Message` | `string` | Access denied error message. | ##### Response `403``application/json` 3 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | | `Message` | `string` | Access denied error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Environment disable failure. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `POST` `/documentation-activate-key` #### Documentation environment key activation `activateKey` This service activates your API key and enables you to preview Staircase product APIs. ##### Request application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string` | API-KEY to be activated in the documentation environment.Example `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `200``application/json` 3 fields Key activated. | Field | Type | Description | | --- | --- | --- | | `fqdn`required | `string` | Fully qualified domain name of the environment where the key was activated. | | `status`required | `string` | Status of the key activation. | | `message`required | `string` | Message about the key activation. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Key Activation error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/env-tools/maintenance-access` #### Maintenance access Retrieve a set of temporal credential for the environment to perform maintenance or support tasks ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service | | `Authorization` required | `string` header | `` | Authorizartion token | | `resource_type` | `string` query | `logs` | resource type for which the access will be granted | | `access_level` | `string` query | `read` | level of access to the resource | ##### Response `200``application/json` 3 fields Temporal login credentials | Field | Type | Description | | --- | --- | --- | | `username` | `string` | Username allowed for the temporal access. | | `account_alias` | `string` | Account alias to be used for accessing. | | `password` | `string` | One time Password. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL of the documentation | | `message` | `string` | Error message. | ##### Response `401``application/json` 2 fields Access Denied | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting proper access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting proper access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Maintenance access failure. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/environment/{api_key}` #### Get environment status `get-environment` Get environment Fetch environment status. ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `api_key` required | `string` path | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API-KEY | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Environment creation failure. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200` `GET` `/list-environments` #### List active environments `list-environments` List environments Fetch list of active environments. ##### Response 400 application/json400 text/html application/json Copy Bad request. ``` Bad request ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token. | ##### Response `200``application/json` 1 fields Response body with the list of child environment active. | Field | Type | Description | | --- | --- | --- | | `environments`required | `object[]` | List of active child environments FQDN and service API-KEY | | `fqdn` | `string` | Domain name of the environment. | | `service-key` | `string` | API-KEY of the environment. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Environment not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `401` `GET` `/service-key/{api_key}` #### Get service API-KEY `get-service-key` Get service key Fetch service key value. ##### Response text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | X-API-KEY for using the service. | | `Authorization` required | `string` header | `` | Authorization token. | | `api_key` required | `string` path | `` | Environment API-KEY | ##### Response `200``application/json` 1 fields Response body with the environment status and, environment details | Field | Type | Description | | --- | --- | --- | | `service_key`required | `string` | UUID value of the service key. | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `401``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `403``application/json` 2 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL for getting access | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Service key error. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ## Errors `400``401``403``404``422``500` ## More in Distribution - Previous product: Console - Next product: Finance --- # Finance # Finance Metering and billing keyed to the same product identifier every endpoint definition carries. Finance meters each invocation against the product API it called, using the identifier already present in that endpoint's definition. There is no separate billing catalogue to keep in step with the API catalogue, because they are the same identifier. Price revisions are versioned per API, and vendor cost is reported alongside what was charged. ## How it works Metered units can be negative. That is what expresses a charge reversed when a call returned nothing usable — a credit rather than a suppressed record, so the ledger still shows the attempt. Keeping the attempt visible matters for the waterfall: a vendor tried and returning nothing is exactly the event the ordering is tuned on. ## Operations ### Metrics `POST` `/metrics` #### Create Finance Metrics `createFinanceMetric` Create Finance Metric This service enables storing finance metrics. The unit value is a required field that can be either positive or negative according to the direction of the transaction. ##### Request application/json Copy ``` { "product_api_identifier": "product_api_identifier_2", "product_price_identifier": "product_price_identifier_2", "product_identifier": "c5b45e21-6946-4110-bf83-8ca90fac5493", "transaction_id": "01G0KZARZ46W8KZ81277V5C0HA", "request_collection_id": "2I8JNKZARZ46W8KZ81277V5CASD", "response_collection_id": "328JNKZARZ46W8KZ81277V5SKDS", "company_name": "customer_comp", "price_unit_type": "transaction", "price_timing_type": "completion", "price_amount": 10, "price_amount_unit_type": "cents" } ``` ##### Response 201400 application/json400 text/html403404 application/json Copy Success response. ``` { "message": "metric created" } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 11 fields | Field | Type | Description | | --- | --- | --- | | `product_api_identifier`required | `string` | Unique identifier for payable unitExample `product_api_identifier_1` | | `product_price_identifier`required | `string` | Unique identifier for priceExample `product_price_identifier_1` | | `transaction_id` | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled.Example `01G0KZARZ46W8KZ81277V5C0HA` | | `request_collection_id` | `string` | Unique identifier for Staircase request collectionExample `2I8JNKZARZ46W8KZ81277V5CASD` | | `response_collection_id` | `string` | Unique identifier for Staircase response collectionExample `328JNKZARZ46W8KZ81277V5SKDS` | | `company_name` | `string` | Company nameExample `comp_name` | | `price_unit_type`required | `string` | The unit of the platform where the price evaluation can be determined as relevant`api_call``datapoint``document``environment``hour``image``page``person``person-hour``pm``pm-hour``product``seat``subscription``transaction`Example `product` | | `price_timing_type`required | `string` | Price is included into billing based on this defined schedule.`completion``monthly`Example `completion` | | `product_identifier`required | `string` | Unique identifier for productExample `c5b45e21-6946-4110-bf83-8ca90fac5493` | | `price_amount`required | `number` | Value of the unit in selected unit price. This value can be negative or positive.Example `95` | | `price_amount_unit_type`required | `string` | Unit of the price`cents`Example `cents` | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message response | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `POST` `/products/finance-service/custom_endpoint/create-finance-metric` #### Create Finance Metric `createFinanceMetric` Create finance metric Create finance metric. Results will be saved in the output collection. Remember transaction_id and response_collection_id from the response to get the collection data from Persistence API: Retrieve Collection Response collection example ``` { "metadata": { "version": 2, "validation": true, "product_name": "finance-service" }, "transaction_id": "01GME0M8HH3TXS0STWANH32VRC", "collection_id": "01GME0M8KYYBNYQSEVB7MXKVXW", "data": { "finance_metrics": [ { "@id": "01GQJPZJAFSMTB9EDYKGQ85VKK", "@type": "finance_metric", "has_finance_metrShow the restic_identifier": { "has_value": "01GQJPZJAFSMTB9EDYKGQ85VKK" }, "has_collection_id": { "has_value": "" }, "has_organization_id": { "has_value": "john.doe@test.co" }, "has_produce_identifier": { "has_value": "customer" }, "has_product_api_identifier": { "has_value": "active" }, "has_transaction_id": { "has_value": "test-co-1" } } ] } } } ``` ##### Request application/json Copy ``` { "request_data": { "finance_metrics": [ { "has_transaction_id": { "has_value": "test-co-1" }, "has_collection_id": { "has_value": "https://test-co-1.com" }, "has_organization_id": { "has_value": "john.doe@test.co" }, "has_produce_identifier": { "has_value": "customer" }, "has_product_api_identifier": { "has_value": "product-api-identifier" } } ] } } ``` ##### Response 201400 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" } ``` application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string (uri)` | Callback URL. | | `request_data`required | `object` | Request JSON body. | | `finance_metrics` | `object[]` | Finance metric filter | | `has_transaction_id` | `object` | Transaction ID | | `has_value` | `string` | Transaction IDExample `01GQJPZG07MMFTF6ZZ3BVK1ZFP` | | `has_collection_id` | `object` | Collection ID | | `has_value` | `string` | Collection IDExample `01GQJPZFXPRR8QMR31CG92J27D` | | `has_organization_id` | `object` | Organization ID | | `has_value` | `string` | Organization IDExample `test-co-1@gmail.com` | | `has_produce_identifier` | `object` | Product Identifier | | `has_value` | `string` | Product IdentifierExample `customer` | | `has_product_api_identifier` | `object` | Product API Identifier | | `has_value` | `string` | Product API IdentifierExample `62f5691e-7fd0-4728-ac3c-977dea07f338` | ##### Response `201``application/json` 12 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `request_collection_id`required | `string` | Request collection ID. | | `response_collection_id`required | `string` | Response collection ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | | `widget_url` | `string` | Product widget_url listening on the connector widget_url | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner, flow or execution not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `POST` `/metrics/query` #### Create Asynchronous Metric Query `create_async_query_execution` Create Asynchronous Query Execution The service creates asynchronous query execution to retrieves a list of metrics given one or multiple filters. To retrieve all results, send the request with the same query parameters and next_token provided on the previous call until next_token does not appear in the response. ##### Request application/json Copy Create asynchronous query execution ``` { "product_api_identifier": "c4c7a50e-ef10-4885-9a9d-2c04d7410084", "product_price_identifier": "ecb11b04-e99c-4610-8db1-990367c25883", "transaction_id": "01F2Q6WJXF5DK3ERTZ18JHSNE8", "start_date": "2022-04-11", "end_date": "2022-04-15" } ``` ##### Response 201400 application/json400 text/html403 application/json Copy Ok. ``` { "query_id": "c62a1228-fae7-44c8-aebe-8706ecfb9fc4", "status": "IN_PROGRESS" } ``` application/json Copy Failed Creation. ``` { "message": "Error in creating metric " } ``` text/html Copy Failed Creation. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 11 fields | Field | Type | Description | | --- | --- | --- | | `product_api_identifier` | `string` | Unique identifier for payable unitExample `product_api_identifier_1` | | `product_price_identifier` | `string` | Unique identifier for priceExample `product_price_identifier_1` | | `transaction_id` | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled.Example `01G0KZARZ46W8KZ81277V5C0HA` | | `request_collection_id` | `string` | Unique identifier for Staircase request collectionExample `2I8JNKZARZ46W8KZ81277V5CASD` | | `response_collection_id` | `string` | Unique identifier for Staircase response collectionExample `328JNKZARZ46W8KZ81277V5SKDS` | | `company_name` | `string` | Company nameExample `comp_name` | | `price_unit_type` | `string` | The unit of the platform where the price evaluation can be determined as relevant`api_call``datapoint``document``environment``hour``image``page``person``person-hour``pm``pm-hour``product``seat``subscription``transaction`Example `product` | | `price_timing_type` | `string` | Price is included into billing based on this defined schedule.`completion``monthly`Example `completion` | | `product_identifier` | `string` | Unique identifier for the productExample `3f312801-e3bb-49c2-a59b-8e2c05958c1b` | | `start_date`required | `string` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format.Example `2021-04-13` | | `end_date`required | `string` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format.Example `2021-04-16` | ##### Response `201``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `query_id` | `string` | Unique identifier for running query execution | | `status` | `string` | Status of the query execution | ##### Response `400``application/json` 1 fields Failed Creation. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message reason why the creation has failed | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `GET` `/metrics/query/{query_id}` #### Get Asynchronous Query Result `get_async_query_result` The service retrieves a list of metrics by given query id. To retrieve all results, send the next_token provided on the previous call until next_token does not appear in the response. ##### Response 200400 application/json400 text/html403404 application/json Copy Ok. ``` { "query_id": "fd99d4de-1632-487f-8576-2ee064e75b51", "status": "SUCCEEDED", "result_csv_file": "https://finance-athena-result-795294970345.s3.amazonaws.com/fd99d4de-1632-487f-8576-2ee064e75b51.csv&Expires=1659342953", "data": { "metrics": [ { "product_api_identifier": "c4c7a50e-ef10-4885-9a9d-2c04d7410084", "product_price_identifier": "ecb11b04-e99c-4610-8db1-990367c25883", "transaction_id": "da2dbe64-33c0-4de2-b5a4-745f0b60ee4c", "host_environment": "documentation.staircaseapi.com", "date": "2022-08-01 03:32:42.000", "company_name": "bohr", "price_unit_type": "subscription", "price_timing_type": "monthly", "price_amount": "10000.0", "price_amount_unit_type": "cents" }, { "product_api_identifier": "df7d610c-0e6e-4bbd-86c0-7de39e29dd8a", "product_price_identifier": "6c58cf4d-0d97-49dd-8d1a-fd44387734e4", "transaction_id": "aaa55ebb-43e8-4722-96cd-050bf2b5c29c", "host_environment": "documentation.staircaseapi.com", "date": "2022-08-01 03:32:20.000", "company_name": "bohr", "price_unit_type": "subscription", "price_timing_type": "monthly", "price_amount": "50000.0", "price_amount_unit_type": "cents" }, { "product_api_identifier": "6ee48f0c-7bd8-43de-9bf9-afce5e85bd08", "product_price_identifier": "4159a209-bc65-48eb-8735-7cb3600d7fa0", "transaction_id": "2c71d744-9589-4812-a373-e4bcec7df5c5", "host_environment": "documentation.staircaseapi.com", "date": "2022-08-01 03:28:51.000", "company_name": "bohr", "price_unit_type": "subscription", "price_timing_type": "monthly", "price_amount": "100000.0", "price_amount_unit_type": "cents" } ] } } ``` application/json Copy Error Response. ``` { "response": { "value": { "message": "Filters not allowed ", "allowed filters": [ "product_name", "status", "partner_name", "metric_type", "operation_status", "product_name and severity", "product_name and status", "operation_stauts and partner_name", "start_date and end_date can be combined with every filter" ] } } } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `query_id` required | `string` path | `1fc23e2-b13e-405a-a3de-a5228950e3b8` | Unique query execution id | | `x-api-key` required | `string` header | `` | API key | | `limit` | `integer` query | `150` | The number of results to return in this request. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the query execution | | `result_csv_file` | `string` | URL for query result in CSV format | | `metrics` | `object[]` | Metrics | | `host_environment` | `string` | Environment host where the product is deployed. | | `product_api_identifier` | `string` | Unique identifier for payable unit | | `product_price_identifier` | `string` | Unique identifier for price | | `transaction_id` | `string` | Transaction ID | | `request_collection_id` | `string` | Unique identifier for Staircase request collection | | `response_collection_id` | `string` | Unique identifier for Staircase response collection | | `company_name` | `string` | Company name | | `price_unit_type` | `string` | The unit of the platform where the price evaluation can be determined as relevant | | `price_timing_type` | `string` | Price is included into billing based on this defined schedule. | | `price_amount` | `string` | Value of the unit in selected unit price. This value can be negative or positive. | | `price_amount_unit_type` | `string` | Unit of the price | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Aggregated Metric Migrations `POST` `/migrations` #### Create Aggregated Finance Metric Migration Configurations `createFinanceMigrationConfigurations` Create Finance Migration Configurations This service creates migration configurations to allow migrating aggregated finance data to another environment. Aggregated finance data is needed for generating finance reports from them. ##### Request application/json Copy ``` { "migration_configuration_name": "test_name", "target_environment_api_key": "apikey", "target_environment_domain": "documentation.staircaseapi.com" } ``` ##### Response 201400 application/json400 text/html403404 application/json Copy Success response. ``` { "message": "migration configuration created" } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `migration_configuration_name`required | `string` | Migration configuration nameExample `test-migration` | | `target_environment_domain`required | `string` | Domain of target environmentExample `documentation.staircaseapi.com` | | `target_environment_api_key`required | `string` | API key of given target environmentExample `1111111-22222-333333` | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message response | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `GET` `/migrations` #### List Aggregated Finance Metric Migration Configurations `listFinanceMigrationConfigurations` List Finance Migration Configurations This service allows retrieving Finance product migration configuration ##### Response 200400 error response400 text/html403404 application/json Copy Ok. ``` { "migration_configurations": [ { "migration_configuration_name": "test_name", "target_environment_api_key": "apikey", "target_environment_domain": "template.staircaseapi.com" } ] } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `migration_configurations` | `object[]` | Configurations | | `migration_configuration_name` | `string` | Unique configuration nameExample `test_configuration` | | `target_environment_api_key` | `string` | Target environment API keyExample `111111-222222-333333` | | `target_environment_domain` | `string` | Target environment domainExample `documentation.staircaseapi.com` | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `PUT` `/migrations/{migration_configuration_name}` #### Update Aggregated Finance Metric Migration Configurations `updateFinanceMigrationConfigurations` Update Finance Migration Configurations This service updates migration configuration. ##### Request application/json Copy ``` { "target_environment_api_key": "apikey", "target_environment_domain": "documentation.staircaseapi.com" } ``` ##### Response 201400 application/json400 text/html403404 application/json Copy Success response. ``` { "message": "migration configuration updated" } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | | `migration_configuration_name` required | `string` path | `test_configuration_name` | Unique configuration name | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `target_environment_domain`required | `string` | Domain of target environmentExample `documentation.staircaseapi.com` | | `target_environment_api_key`required | `string` | API key of given target environmentExample `1111111-22222-333333` | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message response | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `GET` `/migrations/{migration_configuration_name}` #### Get Aggregated Finance Metric Migration Configurations `getFinanceMigrationConfigurations` Get Finance Migration Configurations This service allows retrieving Finance product migration configuration ##### Response 200400 error response400 text/html403404 application/json Copy Ok. ``` { "migration_configuration_name": "test_name", "target_environment_api_key": "apikey", "target_environment_domain": "documentation.staircaseapi.com" } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | | `migration_configuration_name` required | `string` path | `test_configuration_name` | Unique configuration name | | `x-api-key` required | `string` header | `` | API key | ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `migration_configuration_name` | `string` | Unique configuration nameExample `test_configuration` | | `target_environment_api_key` | `string` | Target environment API keyExample `111111-222222-333333` | | `target_environment_domain` | `string` | Target environment domainExample `documentation.staircaseapi.com` | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `DELETE` `/migrations/{migration_configuration_name}` #### Delete Aggregated Finance Metric Migration Configurations `deleteFinanceConfigurations` Delete Finance Configurations This service allows deleting Finance product configuration ##### Response 200400 error response400 text/html403404 application/json Copy Ok. ``` { "message": "migration configuration deleted" } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | | `migration_configuration_name` required | `string` path | `test_configuration_name` | Unique configuration name | | `x-api-key` required | `string` header | `` | API key | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Unique configuration nameExample `test_configuration` | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ### Reports `POST` `/reports/finance` #### Create Finance Metric Reports `createFinanceMetricReport` Create Finance Metric Report This service allows the creation of financial reports for given dates. Request body allows filtering reports by some fields. This service starts asynchronous report execution and returns a unique report ID for checking report execution status and getting report results if report execution is finished. ##### Request application/json Copy ``` { "product_api_identifiers": [ "id_1", "id_2" ], "product_price_identifiers": [ "product_price_identifier_1", "product_price_identifier_2" ], "start_date": "2021-04-13", "end_date": "2021-05-13" } ``` ##### Response 202400401403404405 application/json Copy Report execution started ``` { "report_id": "9a6aa8-4f2-400d-9451-e1e127485" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `product_api_identifiers` | `array` | List of API ID | | `product_price_identifiers` | `array` | List of product price identifier | | `price_amount_unit_type` | `string` | Price unit`cents`Example `cents` | | `start_date`required | `string` | Start date in ISO8601 formatExample `2021-04-13` | | `end_date`required | `string` | End date in ISO8601 formatExample `2021-05-13` | ##### Response `202``application/json` 1 fields Report execution started | Field | Type | Description | | --- | --- | --- | | `report_id` | `string` | Report ID | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `POST` `/reports/finance/aggregated` #### Create Aggregated Finance Metric Reports `createAggregatedFinanceMetricReport` Create Aggregated Finance Metric Report This service allows the creation of financial reports from aggregated metric data for given dates. In order to get a finance report for multiple environments, please have a look at the migrations(/migrations) service for migrating aggregated finance metrics. Request body allows filtering reports by some fields. This service starts asynchronous report execution and returns a unique report ID for checking report execution status and getting report results if report execution is finished. There is no retention period for aggregated finance metrics. ##### Request application/json Copy ``` { "product_api_identifiers": [ "id_1", "id_2" ], "environments": [ "documentation.staircaseapi.com" ], "product_price_identifiers": [ "product_price_identifier_1", "product_price_identifier_2" ], "start_date": "2021-04-13", "end_date": "2021-05-13" } ``` ##### Response 202400401403404405 application/json Copy Report execution started ``` { "report_id": "9a6aa8-4f2-400d-9451-e1e127485" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `product_api_identifiers` | `array` | List of API ID | | `environments` | `array` | List of environment names | | `product_price_identifiers` | `array` | List of product price identifier | | `price_amount_unit_type` | `string` | Price unit`cents`Example `cents` | | `start_date`required | `string` | Start date in ISO8601 formatExample `2021-04-13` | | `end_date`required | `string` | End date in ISO8601 formatExample `2021-05-13` | ##### Response `202``application/json` 1 fields Report execution started | Field | Type | Description | | --- | --- | --- | | `report_id` | `string` | Report ID | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `GET` `/reports/{report_id}` #### Get Finance Report Result `getFinanceReportResult` This service retrieves the status of a Report Execution for a given report_id. Status = IN_PROGRESS, SUCCEEDED, or FAILED. Continue to ping this service until you receive a status = SUCCEEDED or FAILED. Created report results have one month retention period. ##### Response 200400403404405 application/json Copy Report status ``` { "report_id": "979a6aa8-4f2-400d-9451-80ee1e127485", "status": "SUCCEEDED", "created_at": "2022-05-06:11:53:38", "finished_at": "2022-05-06:11:55:10", "expired_at": "1654864684", "report_data": { "total": 0, "price_amount_unit_type": "cents", "environments": [] } } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` application/json Copy Not found. ``` { "message": "Not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | API key | | `report_id` required | `string` path | `979a6aa8-4f2-400d-9451-80ee1e127485` | Report ID | ##### Response `200``application/json` 6 fields Report status | Field | Type | Description | | --- | --- | --- | | `report_id` | `string` | Report ID | | `status` | `string` | IN_PROGRESS, FAILED, or SUCCEEDED`FAILED``IN_PROGRESS``SUCCEEDED` | | `report_data` | `object` | Report payload | | `created_at` | `string` | Create date of report executionExample `2022-05-06:11:53:38` | | `finished_at` | `string` | Finish date of report executionExample `2022-05-06:11:55:10` | | `expired_at` | `string` | Expiration timestamp in string formatExample `1654864684` | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ## Errors `400``401``403``404``405``422``504` ## More in Distribution - Previous product: Environment - Next product: Host --- # Host # Host Deploying a third-party vendor's own software to run inside a customer-managed cloud account. Some vendors sell software rather than an API, and some data cannot leave a customer's account. Host installs the vendor's engine inside the customer's own environment and operates it there, so the integration behaves like every other one while the documents never leave. Document-extraction engines are the main case. The vendors installed this way appear below. ## How it works The alternative was routing documents to a vendor's cloud, which is a different data-residency position and a different contract. Installing the engine locally keeps both the integration surface and the residency boundary intact at once. ## Operations ### Hostings `POST` `/hostings` #### Create New `CreateNewHosting` Create New Hosting endpoint ##### Request application/jsonapplication/json application/json Copy ``` { "ami_id": "Example AMI", "instance_type": "Example Instance Type" } ``` application/json Copy ``` { "ami_id": null, "instance_type": null } ``` ##### Response 200400403500 application/json Copy Ok. ``` { "code": 200, "message": { "host_name": "test" } } ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/hostings/{hosting_name}` #### Get by name `GetHosting` Get Hosting endpoint ##### Response 200400403404500 application/json Copy Ok. ``` { "code": 200, "message": { "host": "example" } } ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Error ``` { "message": "Unable to find a hosting with given parameters." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `hosting_name` required | `string` path | `Test` | Hosting Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `DELETE` `/hostings/{hosting_name}` #### Remove by name `RemoveHosting` Remove Hosting endpoint ##### Response 200400403404500 application/json Copy Ok. ``` { "code": 200, "message": { "info": "example" } } ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Error ``` { "message": "Unable to find a hosting with given parameters." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `hosting_name` required | `string` path | `Test` | Hosting Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ### AMI-Storage `POST` `/share-ami` #### Share-AMI `ShareAMI` Share AMI Share AMI endpoint ##### Response 200400 application/json400 text/html403500 application/json Copy Ok. ``` { "code": 200, "message": "example" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `string` | Payload | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ### Host `POST` `/ami-infos` #### Create New AMI info `CreateNewAMIInfo` Create New AMI info endpoint ##### Request application/jsonapplication/json application/json Copy ``` { "ami_id": "Example AMI", "ami_name": "Example Instance Type", "health_check_url": "Example Health Check Url" } ``` application/json Copy ``` { "ami_id": null, "ami_name": null, "health_check_url": null } ``` ##### Response 200400 application/json400 text/html403500 application/json Copy Ok. ``` { "code": 200, "message": "AMI info created successfully" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/ami-infos/{ami_name}` #### Get AMI Info `GetAMIInfo` Get AMI Info endpoint ##### Response 200400 application/json400 text/html403404500 application/json Copy Ok. ``` { "code": 200, "message": { "host": "example" } } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Error ``` { "message": "Unable to find a ami information with given parameters." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ami_name` required | `string` path | `Test` | AMI Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `DELETE` `/ami-infos/{ami_name}` #### Remove AMI Info `RemoveAMIInfo` Remove AMI Info endpoint ##### Response 200400 application/json400 text/html403404500 application/json Copy Ok. ``` { "code": 200, "message": "Example" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Error ``` { "message": "Unable to find a ami information with given parameters." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ami_name` required | `string` path | `Test` | AMI Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `PUT` `/ami-infos/{ami_name}` #### Update New AMI info `UpdateNewAMIInfo` Update New AMI info endpoint ##### Request application/jsonapplication/json application/json Copy ``` { "ami_id": "Example AMI", "health_check_url": "Example Health Check Url" } ``` application/json Copy ``` { "ami_id": null, "health_check_url": null } ``` ##### Response 200400 application/json400 text/html403500 application/json Copy Ok. ``` { "code": 200, "message": "AMI info updated successfully" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ami_name` required | `string` path | `Test` | AMI Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ### SoftworksAI `POST` `/process-batches` #### Add New Batch for Processing `process-tobatches` Add a new batch for processing. The service process a batch with one or multiple documents in SoftworksAI. Mortgage documents can be classified and extracted by this service. Documents can be processed according to the priority specified in the request, you can send High, Medium, and Low. The batch request will be received and will be in progress, the status of the batch can be got by calling the service /batch-info/{name}, which will provide each generated document status, classification, and ID. ##### Request application/json Copy An example of a payload. ``` { "Name": "00-batch-from-api-initial-test-healthy-check-001", "FileList": [ "https://somebucketname.s3.us-east-1.amazonaws.com/MultiDocs_10_pages.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host" ], "Priority": "High", "transaction_id": "01FMVZRHRT0B5GWJR5DC36AVWE" } ``` ##### Response 201202400 application/json400 text/html401403422 application/json Copy Created. ``` { "code": 201, "message": "IN PROGRESS" } ``` application/json Copy Accepted. ``` { "code": 202, "message": "IN PROGRESS" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `Name`required | `string` | Batch identifier.Example `00-batch-from-api-initial-test-healthy-check-001` | | `FileList`required | `string[]` | List of files to process. | | `Priority`required | `string` | Batch processing priority.`High``Low``Medium`Example `High` | | `transaction_id`required | `string` | Transaction idExample `01FMVZRHRT0B5GWJR5DC36AVWE` | ##### Response `201``application/json` 2 fields Created. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `string` | Description response. | ##### Response `202``application/json` 2 fields Accepted. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `string` | Description response. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/batch-info/{name}` #### Retrieve Documents Associated with Batch `batch-info` Get all docs associated with a batch This service get all documents processed under a batch name , the current status and document type identified by SoftworksAI. A document ID is generated under the following scenarios: - The batch processed has multiple documents with a URL for each. - One PDF document with multiple pages, each processed page will have its own document ID. ##### Response 200400 application/json400 text/html401403404422 application/json Copy Ok. ``` [ { "id": 1 }, { "name": "00-batch-from-api-initial-test-healthy-check-001" }, { "stage": "Recognition" }, { "status": "processing" }, { "assignedTo": "SYSTEM" }, { "scannedDate": "3/12/2021 3:14:04 PM" }, { "modifiedDate": "3/12/2021 3:14:04 PM" }, { "docType": "" }, { "tenantName": "" }, { "errorMessage": "" }, { "FileList": [ "\\\\10.0.0.123\\Workflow\\TrapezeProject\\Pending\\Batches\\00-batch-from-api-initial-test-healthy-check-001\\2.Recognition\\MultiDocs_10_pages_CV20210312151404.pdf" ] }, { "Priority": "High" } ] ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Not Found ``` { "code": "404", "message": "Not Found." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `00-batch-from-api-initial-test-healthy-check-001` | Name of the batch which extracted data it's being requested. | ##### Response `200``application/json` 16 fields Ok. | Field | Type | Description | | --- | --- | --- | | `inFileName` | `string` | — | | `inDocId` | `integer` | — | | `inNumPages` | `integer` | — | | `numPages` | `integer` | — | | `id` | `integer` | — | | `name` | `string` | — | | `stage` | `string` | — | | `status` | `string` | — | | `assignedTo` | `string` | — | | `scannedDate` | `string` | — | | `modifiedDate` | `string` | — | | `docType` | `string` | — | | `tenantName` | `string` | — | | `errorMessage` | `string` | — | | `FileList` | `string[]` | — | | `Priority` | `string` | — | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/batch-status/{name}` #### Retrieve Batch Status `batch-status` Get batch status This service get all documents processed under a batch name , the current status and document type identified by SoftworksAI. A document ID is generated under the following scenarios: - The batch processed has multiple documents with a URL for each. - One PDF document with multiple pages, each processed page will have its own document ID. ##### Response 200202400 application/json400 text/html401403404422 application/json Copy Ok. ``` [ { "id": 1 }, { "name": "00-batch-from-api-initial-test-healthy-check-001" }, { "stage": "Recognition" }, { "status": "processing" }, { "assignedTo": "SYSTEM" }, { "scannedDate": "3/12/2021 3:14:04 PM" }, { "modifiedDate": "3/12/2021 3:14:04 PM" }, { "docType": "" }, { "tenantName": "" }, { "errorMessage": "" }, { "FileList": [ "\\\\10.0.0.123\\Workflow\\TrapezeProject\\Pending\\Batches\\00-batch-from-api-initial-test-healthy-check-001\\2.Recognition\\MultiDocs_10_pages_CV20210312151404.pdf" ] }, { "Priority": "High" } ] ``` application/json Copy Ok. ``` [ { "id": 1 }, { "name": "00-batch-from-api-initial-test-healthy-check-001" }, { "stage": "Recognition" }, { "status": "processing" }, { "assignedTo": "SYSTEM" }, { "scannedDate": "3/12/2021 3:14:04 PM" }, { "modifiedDate": "3/12/2021 3:14:04 PM" }, { "docType": "" }, { "tenantName": "" }, { "errorMessage": "" }, { "FileList": [ "\\\\10.0.0.123\\Workflow\\TrapezeProject\\Pending\\Batches\\00-batch-from-api-initial-test-healthy-check-001\\2.Recognition\\MultiDocs_10_pages_CV20210312151404.pdf" ] }, { "Priority": "High" } ] ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Not Found ``` { "code": "404", "message": "Not Found." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `00-batch-from-api-initial-test-healthy-check-001` | Name of the batch which extracted data it's being requested. | ##### Response `200``application/json` 12 fields Ok. | Field | Type | Description | | --- | --- | --- | | `id` | `integer` | — | | `name` | `string` | — | | `stage` | `string` | — | | `status` | `string` | — | | `assignedTo` | `string` | — | | `scannedDate` | `string` | — | | `modifiedDate` | `string` | — | | `docType` | `string` | — | | `tenantName` | `string` | — | | `errorMessage` | `string` | — | | `FileList` | `string[]` | — | | `Priority` | `string` | — | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Other responses `202` `GET` `/extract/batch-name/{name}` #### Retrieve List of Extracted Fields `extract-all` Get list of extracted fields This service returns all extracted documents for one batch in SoftworksAI. For documents with multiple pages, this service returns all documents extracted as well. ##### Response 200400 application/json400 text/html401403404422 application/json Copy Ok. ``` [ { "fieldlist": [ { "position": [ { "page": 1 }, { "inputFilePageNumber": 1 }, { "inputFileID": 10015 }, { "top": 0 }, { "bottom": 0 }, { "left": 0 }, { "right": 0 } ] }, { "name": "DocumentType" }, { "data": "W-2" }, { "dataOriginal": "W-2" }, { "conf": 100 } ] }, { "id": 10023 }, { "docType": "W-2" }, { "docConf": 93 } ] ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Not Found ``` { "code": "404", "message": "Not Found." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `00-batch-from-api-initial-test-healthy-check-001` | Name of the batch which extracted data it's being requested. | ##### Response `200``application/json` 4 fields Ok. | Field | Type | Description | | --- | --- | --- | | `fieldList` | `object[]` | — | | `position` | `object[]` | — | | `page` | `integer` | — | | `inputFilePageNumber` | `integer` | — | | `inputFileID` | `integer` | — | | `top` | `integer` | — | | `bottom` | `integer` | — | | `left` | `integer` | — | | `right` | `integer` | — | | `name` | `string` | — | | `data` | `string` | — | | `dataOriginal` | `string` | — | | `conf` | `integer` | — | | `id` | `integer` | — | | `docType` | `string` | — | | `docConf` | `integer` | — | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `PUT` `/{name}/pages` #### Update And Approve Pages `updateAndApprovePages` The service updates And approves pages ##### Request application/json Copy An example of a payload. ``` [ { "id": 124, "docID": 31, "pageNumber": 1, "docType": "Form 1003 Uniform Residential Loan Application", "docConf": 94, "confThresh": 90, "split": true, "outputDocId": 1, "inputFilePageNumber": 2 } ] ``` ##### Response 200400 application/json400 text/html401403422 application/json Copy Ok. ``` { "code": 200, "message": "Configuration updated successfully" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `00-batch-from-api-initial-test-healthy-check-001` | Name of the batch which extracted data it's being requested. | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `string` | Status message. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Not Found. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/{name}/pages` #### Get Pages `getPages` The service gets pages for the batch ##### Response 200400 application/json400 text/html401403422 application/json Copy Ok. ``` [ { "id": 167, "docID": 6, "pageNumber": 1, "docType": "Miscellaneous", "docConf": 52, "confThresh": 75, "split": true, "outputDocId": 0, "inputFilePageNumber": 1, "filePath": "" } ] ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `00-batch-from-api-initial-test-healthy-check-001` | Name of the batch which extracted data it's being requested. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Not Found. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Other responses `200` `GET` `/document_types` #### Get Document Types `getDocumentTypes` The service gets document types ##### Response 200400 application/json400 text/html401403422 application/json Copy Ok. ``` [ "W2" ] ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Not Found. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Other responses `200` `GET` `/document_types/{document_type}/fields` #### Get Fields `getFields` The service gets fields ##### Response 200400 application/json400 text/html401403422 application/json Copy Ok. ``` [ { "fieldList": [ { "position": { "page": 1, "inputFilePageNumber": 1, "inputFileID": 2, "top": 0, "bottom": 0, "left": 0, "right": 0 }, "name": "DocumentType", "data": "Form 1008 Uniform Underwriting and Transmittal Summary", "dataOriginal": "Form 1008 Uniform Underwriting and Transmittal Summary", "conf": 103 } ], "id": 21, "docType": "Form 1004C Manufactured Home Appraisal", "docConf": 89 } ] ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Unprocessable Entity ``` { "code": "422", "message": "Unprocessable Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type` required | `string` path | `W2` | Document Type | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not Found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Not Found. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Other responses `200` ### Images `GET` `/images` #### Get Supported Images `GetSupportedImages` Get Supported Images endpoint ##### Response 200400403500 application/json Copy Ok. ``` { "code": 200, "message": [ { "image_name": "host-example", "suggested_instance_type": "t2.xlarge", "rules": { "auto_shutdown": true, "manual_start": true, "manual_shutdown": true, "rdp_access": true, "auto_start": false } } ] } ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `array` | Payload | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ### Actions `POST` `/hostings/{hosting_name}/start` #### Hosting Start `StartHosting` Start Hosting endpoint ##### Response 200400403404500 application/json Copy Ok. ``` { "code": 200, "message": { "info": "example" } } ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Error ``` { "message": "Unable to find a hosting with given parameters." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `hosting_name` required | `string` path | `Test` | Hosting Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `POST` `/hostings/{hosting_name}/stop` #### Hosting Stop `StopHosting` Stop Hosting endpoint ##### Response 200400403404500 application/json Copy Ok. ``` { "code": 200, "message": { "info": "example" } } ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Error ``` { "message": "Unable to find a hosting with given parameters." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `hosting_name` required | `string` path | `Test` | Hosting Name | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Payload | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/hostings/{hosting_name}/rdp_access` #### Get RDP Access `GetRDPAccess` Get RDP Access endpoint ##### Response 200400403500 application/json Copy Ok. ``` [ "Example" ] ``` application/json Copy Bad request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `hosting_name` required | `string` path | `Test` | Hosting Name | ##### Response `400``application/json` 2 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `200` ### Operations `GET` `/get-base-url` #### Get Base URL `get-base-url-ephesoft` Provides a base URL to interact with the current installation of Ephesoft web service. ##### Response 200403 application/json Copy Ok. ``` { "base_url": "http://host-Publi-XXXXXXXXXXXX-1838739269.us-east-1.elb.amazonaws.com:8300" } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `base_url` | `string` | Base URL that can be hit in order to interact with Ephesoft AI’s API. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `500``application/json` 1 fields Batch job creation failure. | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Other responses `401` `GET` `/get-license-requirement` #### Get information to request new license `get-license-requirement` Ephesoft partner requires a file and Installation details to request a license from the support portal. This service gets the details needed to request a new license and returns a presigned URL with the document to download. License portal to get a license from Ephesoft: ##### Response 200400 application/json Copy Ok. ``` { "total_cores": 2, "product_version": "2020.1", "server_os_details": "Microsoft® Windows", "mac_address": "00:AA:BB:CC:DD", "database_detail": "DB", "system_memory": "1GB", "detail_properties_file": "http://host-Publi-XXXXXXXXXXXX-1838739269.us-east-1.elb.amazo" } ``` application/json Copy Bad Request ``` { "code": "400", "message": "Bad request." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | ##### Response `200``application/json` 7 fields Ok. | Field | Type | Description | | --- | --- | --- | | `total_cores` | `number` | Total cores for your specific environment | | `product_Error description` | `string` | Version of Ephesoft | | `server_os_details` | `string` | SO that is currently used for your Ephesoft product | | `mac_address` | `string` | All mac address that you need to request a license before your complete an installation | | `database_detail` | `string` | Version of database | | `system_memory` | `string` | Total memory for server | | `detail_properties_file` | `string` | URL of request license file | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ## Providers - Byte Software - Ephesoft - SoftworksAI ## Errors `400``401``403``404``408``409``422``500``502``503` ## More in Distribution - Previous product: Finance - Next product: Marketplace --- # Marketplace # Marketplace The product catalogue and provisioning service: bundles, versioned publication, dependency resolution and single-call rollback. Publishing makes a bundle installable. The catalogue resolves what a bundle depends on, installs the set, and keeps every published version so a rollback is one call rather than a redeployment. It also serves the ontology itself. Families, categories, products, APIs and prices are readable and writable through it, so the product tree is queryable rather than only written down. ## How it works Every publication is proved twice before it ships. A bundle and its dependencies are installed into a long-lived review environment, which proves it can go into an environment that already has state, and into a second environment wiped daily, which proves it can install from nothing. A bundle that cannot do both does not publish. Those are different failure modes. An installer that assumes prior state breaks on a new customer; an installer that assumes a clean slate breaks on an upgrade. Testing only one of them catches half the class. ## Operations ### Athlete `POST` `/ontology/athletes` #### Register Athlete `register_athlete` This endpoint registers an `Athlete` entity in the ontology, allowing for future links of such to the `Team` entity. ##### Request application/json Copy ``` { "first_name": "Sebastian", "last_name": "Vettel", "email": "sebastian.vettel@gmail.com" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `first_name`required | `string` | Athlete's name | | `last_name`required | `string` | Athlete's surname | | `email`required | `string` | Email address of the Athlete | ##### Response `201``application/json` 1 fields Athlete has been registered. | Field | Type | Description | | --- | --- | --- | | `athlete_id` | `string` | Athlete ID referencing the registered Athlete. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/athletes/{athlete_id}` #### Delete Athlete `delete_athlete` This endpoint deletes `Athlete` from the ontology. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `athlete_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Athlete ID | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `GET` `/ontology/athletes/{athlete_id}` #### Retrieve Athlete `retrieve_athlete` This endpoint retrieves `Athlete` from the ontology. User can additionally request for the team information to which athlete is linked to be returned using the query parameters. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `athlete_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Athlete ID | | `include_team_info` | `boolean` query | `true` | Switch for the team information | ##### Response `200``application/json` 1 fields Athlete has been retrieved. | Field | Type | Description | | --- | --- | --- | | `athlete` | `object` | Athlete information | | `athlete_id`required | `string` | Athlete ID referencing the registered Athlete. | | `first_name`required | `string` | First name of the Athlete | | `last_name`required | `string` | Last name of the Athlete | | `email`required | `string` | Email address of the Athlete | | `team` | `object` | Team information | | `team_name`required | `string` | Team name | | `team_id`required | `string` | Team ID | | `created_at`required | `string` | Date of the creation | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PATCH` `/ontology/athletes/{athlete_id}` #### Update Athlete `update_athlete` This endpoint updates `Athlete` instance in the ontology. ##### Request application/json Copy ``` { "first_name": "Sebastian" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `athlete_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Athlete ID | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `first_name` | `string` | Athlete's first name | | `last_name` | `string` | Athlete's last name | | `email` | `string` | Athlete's email address | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` ### Team `POST` `/ontology/teams` #### Register Team `register_team` This endpoint registers a `Team` entity in the ontology, allowing for future references of such in relation to `Athlete` and `Product` entities. ##### Request application/json Copy ``` { "team_name": "Bohr" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `team_name`required | `string` | Team name | ##### Response `201``application/json` 1 fields Team has been registered. | Field | Type | Description | | --- | --- | --- | | `team_id` | `string` | Team ID referencing the registered Team. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `GET` `/ontology/teams` #### Retrieve Teams `retrieve_teams` This endpoint retrieves all registered Teams in the ontology. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Response `200``application/json` 1 fields Team has been registered. | Field | Type | Description | | --- | --- | --- | | `teams` | `array` | Array of retrieved Teams | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/teams/{team_id}` #### Delete Team `delete_team` This endpoint deletes `Team` from the ontology. #### Warning If the referenced `Team` has `Athlete` or `Product` linked to it, user should first unlink those and only then proceed with the deletion. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `PATCH` `/ontology/teams/{team_id}` #### Update Team `update_team` This endpoint updates `Team` instance in the ontology. ##### Request application/json Copy ``` { "team_name": "Bushnell" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `team_name`required | `string` | Team name | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `GET` `/ontology/teams/{team_id}` #### Retrieve Team `retrieve_team` This endpoint retrieves `Team` from the ontology. #### Query Parameters User can specify whether the information about the Team's linked products or athletes is needed, which is `false` by default. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | | `include_athletes_info` | `boolean` query | `true` | Switch for the athlete information | | `include_products_info` | `boolean` query | `true` | Switch for the product information | ##### Response `200``application/json` 1 fields Athlete has been retrieved. | Field | Type | Description | | --- | --- | --- | | `team`required | `object` | Team information | | `team_name`required | `string` | Team name | | `team_id`required | `string` | Team ID | | `created_at`required | `string` | Date of the creation | | `products` | `array` | Array of products linked to the Team | | `athletes` | `array` | Array of athletes linked to the Team | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/teams/{team_id}/athletes` #### Link Athlete to Team `link_athlete_to_team` This endpoint links the specified `Athlete` to the provided `Team`. If the `Athlete` is already linked with some `Team`, the request is declined - user should unlink it from that `Team` first. ##### Request application/json Copy ``` { "athlete_id": "436bffb6-f398-469b-b619-55f0ecf09b65" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `athlete_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `201``application/json` 1 fields Athlete has been successfully linked to the Team. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/teams/{team_id}/athletes/{athlete_id}` #### Unlink Athlete from Team `unlink_athlete_from_team` This endpoint unlinks `Athlete` from the provided `Team`. If the provided 'Athlete' is not linked with the given `Team` the request is declined. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | | `athlete_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Athlete ID | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `POST` `/ontology/teams/{team_id}/products` #### Link Product to Team `link_product_to_team` This endpoint links the specified `Product` to the provided `Team`. If the `Product` is already linked with some `Team`, the request is declined - user should unlink it from that `Team` first. ##### Request application/json Copy ``` { "product_id": "c5b605e0-54bf-45a1-b275-400e3313be9c" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `product_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `201``application/json` 1 fields Product has been successfully linked to the Team. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/teams/{team_id}/products/{product_id}` #### Unlink Product from Team `unlink_product_from_team` This endpoint unlinks `Product` from the provided `Team`. If the provided 'Product' is not linked with the given `Team` the request is declined. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `team_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Team ID | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` ### Subscription[warning] `POST` `/subscriptions` #### Create Subscription[warning] `createSubscription` Create a subscription Create a subscription for components to keep an environment up to date. If a component contains dependencies, all dependencies will be added to subscription automatically. After a subscription is created or updated, all new items will be deployed immediately. Response contains the list of subscribed to products including dependencies. ##### Subscribing using product identifiers Retrieve components, that are linked to a particular product, use `Get Product Components` endpoint. Show the rest Example in python: ``` import requests http = requests.Session http.headers['x-api-key'] = marketplace_api_key def get_components(marketplace_env: str, product_id: str) -> list[str]: response = http.get(f"") return response.json['components'] component_names = [ *get_components(marketplace_domain_name, product_id_of_connector), *get_components(marketplace_domain_name, product_id_of_persistence), ] http.post( "", json={ "domain_name": subscriber_domain_name, "api_key": subscriber_api_key, "component_names": component_names, }, ) ``` You can read more about linking a component to a product `here` ##### Subscription status Status changes when subscription-specific operations occur. For example, if the Component to which you're subscribed gets an update, or you create a subscription. The following is an ordered flow for the subscription status changes. | Status | Meaning | | --- | --- | | `INITIATED` | Subscription to a component has been created and awaiting the delivery. | | `IN_QUEUE` | Delivery started, deployments are pending. | | `FAILED` | Delivery failed, deployment attempts have failed. | | `SUCCEEDED` | Delivery succeeded. | ##### Observe delivery status One way of observing deliveries' statuses in your environment is using `Listen to Deliveries` API. However, if you don't need to monitor deliveries continuously – you can tell Marketplace to notify you once the component you initiated a direct subscription to has or hasn't been successfully delivered. The notification is emitted via the “webhook” with a structure of its payload described below. Delivery statuses of dependencies are included only if there were failed deliveries Events are sent in payloads of a “HTTP requests” using `POST` method. ``` { "$schema": "", "additionalProperties": true, "type": "object", "description": "Schema for the payload event emitted to callback.", "properties": { "transaction_id": { "type": "string", "description": "Transaction identifier. Unique per delivery." }, "truncated": { "type": "boolean", "description": "Event can be truncated if many direct subscriptions were initiated." }, "domain_name": { "type": "string", "description": "Subscription receiver domain name." }, "components": { "type": "array", "description": "List of components subscription was initiated for.", "items": { "type": "object", "properties": { "component_name": { "type": "string", "description": "Component name delivery initiated for." }, "last_deployment_id": { "type": "string", "description": "Latest available deployment ID used in delivery. Can be null." }, "delivery_status": { "type": "string", "enum": [ "FAILED", "SUCCEEDED" ], "description": "The status of the delivery." }, "component_publication_id": { "type": "string", "description": "The bundle ID of a component used in the delivery process. Can be null." }, "status_updated_date": { "type": "string", "description": "Last time the status was updated." } } } }, "failed_dependencies": { "type": "array", "description": "List of components subscription was initiated for.", "items": { "type": "object", "properties": { "component_name": { "type": "string", "description": "Component name delivery initiated for." }, "last_deployment_id": { "type": "string", "description": "Latest available deployment ID used in delivery. Can be null." }, "delivery_status": { "type": "string", "enum": [ "FAILED", "SUCCEEDED" ], "description": "The status of the delivery." }, "component_publication_id": { "type": "string", "description": "The bundle ID of a component used in the delivery process. Can be null." }, "status_updated_date": { "type": "string", "description": "Last time the status was updated." } } } } } } ``` ###### Troubleshooting Events are dispatched once the delivery process completes, which includes the successful or failed deployment of all components and their respective dependencies. An event is deemed as successfully delivered when its recipient acknowledges with an HTTP status code that falls within the range of successful responses. If an event isn't successfully delivered, the Marketplace will make six additional attempts to resend the event, with each attempt following an exponential back off strategy. To confirm the propagation of the webhook, you can utilize Retrieve Transaction Collections with the transaction ID, which is returned during the creation of the subscription. Collection data example: ``` { "delivery": { "components": [ { "status_updated_date": "2023-05-05T12:28:38.547030+00:00", "component_name": "Marketplace", "delivery_status": "SUCCEEDED", "component_publication_id": "01H01965DB8QGSD9EZWF1VS7BC" }, { "status_updated_date": "2023-05-05T12:28:38.547030+00:00", "component_name": "marketplace-ontology", "delivery_status": "SUCCEEDED", "component_publication_id": "01G02003BD8GQSD9ZEFF1BEVND" } ], "domain_name": "tea.staircaseapi.com", "failed_dependencies": [], "truncated": false }, "partner_response": { "request_response_elapsed_time": 0.38052, "response_status_code": 200, "response_text": "{\"message\": \"event_received\"}", "http_connection_established": true } } ``` Collection is not yet valid for the Lexicon version 3. #### Deprecation notice Marketplace will stop accepting `products` and `data` fields starting from December 2022. In order to subscribe to components, please use `component_names` field instead. Example: ``` import requests requests.post( "", json={ "domain_name": subscriber_domain_name, "api_key": subscriber_api_key, "component_names": [ "Connector", "Deploy", "Health", ], }, ) ``` #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. #### Subscriber validation Marketplace will validate `domain_name` to `api_key` attachment to verify the claim of the environment ownership. Depending on the ownership validation results, Marketplace can either abort or the request or carry on with the subscription changes. ##### Request Subscribe to Miscellaneous ComponentsSubscribe to Credit ComponentsSubscribe to DevOps Suite Components application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Deploy", "Environment" ] } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "amazing.staircaseapi.com", "components_names": [ "Credit" ] } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Assess", "Assess-security-data", "Assess-staircase-data", "Assess-swagger-data", "Build", "Code", "Comply", "Deploy", "Environment", "Test" ] } ``` ##### Response 201400 application/json400 text/html403404409 application/json Copy Subscription has been created ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Assess", "Assess-security-data", "Assess-staircase-data", "Assess-swagger-data", "Build", "Code", "Comply", "Deploy", "Environment", "Test" ] } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested product not found ``` { "message": "Component was not found" } ``` application/json Copy Subscription already exist ``` { "message": "Subscription for domain already exists" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `domain_name`required | `string` | Environment domain nameExample `template.staircaseapi.com` | | `api_key`required | `string` | Environment API keyExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | | `component_names`required | `string[]` | Array of component names. Must have unique items. | | `callback_url` | `string (uri)` | Used for a subscription observability. | ##### Response `201``application/json` 2 fields Subscription has been created | Field | Type | Description | | --- | --- | --- | | `domain_name` | `string` | Environment domain nameExample `template.staircaseapi.com` | | `component_names` | `string[]` | The list of components to subscribe to | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested product not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error message.Example `Component was not found` | ##### Response `409``application/json` 1 fields Subscription already exist | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Conflict error message.Example `Subscription for domain already exists` | `PATCH` `/subscriptions` #### Extend Subscription[warning] `updateSubscription` Extend a subscription. Extend a subscription for components to keep environment up to date. This operation will extend existing subscriptions, keeping them together with new ones. If a component contains dependencies, all dependencies will be added to the subscription automatically. After subscription is created or updated, all new items will be deployed immediately. Response contains the list of new subscribed to products including dependencies. Show the rest ##### Subscribing using product identifiers Retrieve components, that are linked to a particular product, use `Get Product Components` endpoint. Example in python: ``` import requests http = requests.Session http.headers['x-api-key'] = marketplace_api_key def get_components(marketplace_env: str, product_id: str) -> list[str]: response = http.get(f"") return response.json['components'] component_names = [ *get_components(marketplace_domain_name, product_id_of_connector), *get_components(marketplace_domain_name, product_id_of_persistence), ] http.post( "", json={ "domain_name": subscriber_domain_name, "api_key": subscriber_api_key, "component_names": component_names, }, ) ``` You can read more about linking a component to a product `here` ##### Subscription status Status changes when subscription-specific operations occur. For example, if the Component to which you're subscribed gets an update, or you create a subscription. The following is an ordered flow for the subscription status changes. | Status | Meaning | | --- | --- | | `INITIATED` | Subscription to a component has been created and awaiting the delivery. | | `IN_QUEUE` | Delivery started, deployments are pending. | | `FAILED` | Delivery failed, deployment attempts have failed. | | `SUCCEEDED` | Delivery succeeded. | ##### Observe delivery status One way of observing deliveries' statuses in your environment is using `Listen to Deliveries` API. However, if you don't need to monitor deliveries continuously – you can tell Marketplace to notify you once the component you initiated a direct subscription to has or hasn't been successfully delivered. The notification is emitted via the “webhook” with a structure of its payload described below. Delivery statuses of dependencies are included only if there were failed deliveries Events are sent in payloads of a “HTTP requests” using `POST` method. ``` { "$schema": "", "additionalProperties": true, "type": "object", "description": "Schema for the payload event emitted to callback.", "properties": { "transaction_id": { "type": "string", "description": "Transaction identifier. Unique per delivery." }, "truncated": { "type": "boolean", "description": "Event can be truncated if many direct subscriptions were initiated." }, "domain_name": { "type": "string", "description": "Subscription receiver domain name." }, "components": { "type": "array", "description": "List of components subscription was initiated for.", "items": { "type": "object", "properties": { "component_name": { "type": "string", "description": "Component name delivery initiated for." }, "last_deployment_id": { "type": "string", "description": "Latest available deployment ID used in delivery. Can be null." }, "delivery_status": { "type": "string", "enum": [ "FAILED", "SUCCEEDED" ], "description": "The status of the delivery." }, "component_publication_id": { "type": "string", "description": "The bundle ID of a component used in the delivery process. Can be null." }, "status_updated_date": { "type": "string", "description": "Last time the status was updated." } } } }, "failed_dependencies": { "type": "array", "description": "List of components subscription was initiated for.", "items": { "type": "object", "properties": { "component_name": { "type": "string", "description": "Component name delivery initiated for." }, "last_deployment_id": { "type": "string", "description": "Latest available deployment ID used in delivery. Can be null." }, "delivery_status": { "type": "string", "enum": [ "FAILED", "SUCCEEDED" ], "description": "The status of the delivery." }, "component_publication_id": { "type": "string", "description": "The bundle ID of a component used in the delivery process. Can be null." }, "status_updated_date": { "type": "string", "description": "Last time the status was updated." } } } } } } ``` ###### Troubleshooting Events are dispatched once the delivery process completes, which includes the successful or failed deployment of all components and their respective dependencies. An event is deemed as successfully delivered when its recipient acknowledges with an HTTP status code that falls within the range of successful responses. If an event isn't successfully delivered, the Marketplace will make six additional attempts to resend the event, with each attempt following an exponential back off strategy. To confirm the propagation of the webhook, you can utilize Retrieve Transaction Collections with the transaction ID, which is returned during the creation of the subscription. Collection data example: ``` { "delivery": { "components": [ { "status_updated_date": "2023-05-05T12:28:38.547030+00:00", "component_name": "Marketplace", "delivery_status": "SUCCEEDED", "component_publication_id": "01H01965DB8QGSD9EZWF1VS7BC" }, { "status_updated_date": "2023-05-05T12:28:38.547030+00:00", "component_name": "marketplace-ontology", "delivery_status": "SUCCEEDED", "component_publication_id": "01G02003BD8GQSD9ZEFF1BEVND" } ], "domain_name": "tea.staircaseapi.com", "failed_dependencies": [], "truncated": false }, "partner_response": { "request_response_elapsed_time": 0.38052, "response_status_code": 200, "response_text": "{\"message\": \"event_received\"}", "http_connection_established": true } } ``` Collection is not yet valid for the Lexicon version 3. #### Deprecation notice Marketplace will stop accepting `products` and `data` fields starting from December 2022. In order to subscribe to components, please use `component_names` field instead. Example: ``` import requests requests.patch( "", json={ "domain_name": subscriber_domain_name, "api_key": subscriber_api_key, "component_names": [ "Connector", "Deploy", "Health", ], }, ) ``` #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. #### Subscriber validation Marketplace will validate `domain_name` to `api_key` attachment to verify the claim of the environment ownership. Depending on the ownership validation results, Marketplace can either abort or the request or carry on with the subscription changes. ##### Request Subscribe to Miscellaneous ComponentsSubscribe to Credit ComponentsSubscribe to DevOps Suite Components application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Deploy", "Environment" ] } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "amazing.staircaseapi.com", "components_names": [ "Credit" ] } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Assess", "Assess-security-data", "Assess-staircase-data", "Assess-swagger-data", "Build", "Code", "Comply", "Deploy", "Environment", "Test" ] } ``` ##### Response 201400 application/json400 text/html403404 application/json Copy Subscription has been updated ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Assess", "Assess-security-data", "Assess-staircase-data", "Assess-swagger-data", "Build", "Code", "Comply", "Deploy", "Environment", "Test" ] } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested subscription not found ``` { "message": "Subcription not found" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `domain_name`required | `string` | Environment domain nameExample `template.staircaseapi.com` | | `api_key`required | `string` | Environment API keyExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | | `component_names`required | `string[]` | Array of component names. Must have unique items. | | `callback_url` | `string (uri)` | Used for a subscription observability. | ##### Response `201``application/json` 2 fields Subscription has been updated | Field | Type | Description | | --- | --- | --- | | `domain_name` | `string` | Environment domain nameExample `template.staircaseapi.com` | | `component_names` | `string[]` | The list of components to subscribe to | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested subscription not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error message.Example `Subcription not found` | `PUT` `/subscriptions` #### Modify Subscription[warning] `modifySubscription` Modify subscription. Modifies subscription for components to keep environment up to date. This operation will overwrite existing subscriptions. If a component contains dependencies, all dependencies will be added to the subscription automatically. After subscription is created or updated, all new items will be deployed immediately. Response contains the list of new subscribed to products including dependencies. Show the rest ##### Subscribing using product identifiers Retrieve components, that are linked to a particular product, use `Get Product Components` endpoint. Example in python: ``` import requests http = requests.Session http.headers['x-api-key'] = marketplace_api_key def get_components(marketplace_env: str, product_id: str) -> list[str]: response = http.get(f"") return response.json['components'] component_names = [ *get_components(marketplace_domain_name, product_id_of_connector), *get_components(marketplace_domain_name, product_id_of_persistence), ] http.post( "", json={ "domain_name": subscriber_domain_name, "api_key": subscriber_api_key, "component_names": component_names, }, ) ``` You can read more about linking a component to a product `here` ##### Subscription status Status changes when subscription-specific operations occur. For example, if the Component to which you're subscribed gets an update, or you create a subscription. The following is an ordered flow for the subscription status changes. | Status | Meaning | | --- | --- | | `INITIATED` | Subscription to a component has been created and awaiting the delivery. | | `IN_QUEUE` | Delivery started, deployments are pending. | | `FAILED` | Delivery failed, deployment attempts have failed. | | `SUCCEEDED` | Delivery succeeded. | ##### Observe delivery status One way of observing deliveries' statuses in your environment is using `Listen to Deliveries` API. However, if you don't need to monitor deliveries continuously – you can tell Marketplace to notify you once the component you initiated a direct subscription to has or hasn't been successfully delivered. The notification is emitted via the “webhook” with a structure of its payload described below. Delivery statuses of dependencies are included only if there were failed deliveries Events are sent in payloads of a “HTTP requests” using `POST` method. ``` { "$schema": "", "additionalProperties": true, "type": "object", "description": "Schema for the payload event emitted to callback.", "properties": { "transaction_id": { "type": "string", "description": "Transaction identifier. Unique per delivery." }, "truncated": { "type": "boolean", "description": "Event can be truncated if many direct subscriptions were initiated." }, "domain_name": { "type": "string", "description": "Subscription receiver domain name." }, "components": { "type": "array", "description": "List of components subscription was initiated for.", "items": { "type": "object", "properties": { "component_name": { "type": "string", "description": "Component name delivery initiated for." }, "last_deployment_id": { "type": "string", "description": "Latest available deployment ID used in delivery. Can be null." }, "delivery_status": { "type": "string", "enum": [ "FAILED", "SUCCEEDED" ], "description": "The status of the delivery." }, "component_publication_id": { "type": "string", "description": "The bundle ID of a component used in the delivery process. Can be null." }, "status_updated_date": { "type": "string", "description": "Last time the status was updated." } } } }, "failed_dependencies": { "type": "array", "description": "List of components subscription was initiated for.", "items": { "type": "object", "properties": { "component_name": { "type": "string", "description": "Component name delivery initiated for." }, "last_deployment_id": { "type": "string", "description": "Latest available deployment ID used in delivery. Can be null." }, "delivery_status": { "type": "string", "enum": [ "FAILED", "SUCCEEDED" ], "description": "The status of the delivery." }, "component_publication_id": { "type": "string", "description": "The bundle ID of a component used in the delivery process. Can be null." }, "status_updated_date": { "type": "string", "description": "Last time the status was updated." } } } } } } ``` ###### Troubleshooting Events are dispatched once the delivery process completes, which includes the successful or failed deployment of all components and their respective dependencies. An event is deemed as successfully delivered when its recipient acknowledges with an HTTP status code that falls within the range of successful responses. If an event isn't successfully delivered, the Marketplace will make six additional attempts to resend the event, with each attempt following an exponential back off strategy. To confirm the propagation of the webhook, you can utilize Retrieve Transaction Collections with the transaction ID, which is returned during the creation of the subscription. Collection data example: ``` { "delivery": { "components": [ { "status_updated_date": "2023-05-05T12:28:38.547030+00:00", "component_name": "Marketplace", "delivery_status": "SUCCEEDED", "component_publication_id": "01H01965DB8QGSD9EZWF1VS7BC" }, { "status_updated_date": "2023-05-05T12:28:38.547030+00:00", "component_name": "marketplace-ontology", "delivery_status": "SUCCEEDED", "component_publication_id": "01G02003BD8GQSD9ZEFF1BEVND" } ], "domain_name": "tea.staircaseapi.com", "failed_dependencies": [], "truncated": false }, "partner_response": { "request_response_elapsed_time": 0.38052, "response_status_code": 200, "response_text": "{\"message\": \"event_received\"}", "http_connection_established": true } } ``` Collection is not yet valid for the Lexicon version 3. #### Deprecation notice Marketplace will stop accepting `products` and `data` fields starting from December 2022. In order to subscribe to components, please use `component_names` field instead. Example: ``` import requests requests.put( "", json={ "domain_name": subscriber_domain_name, "api_key": subscriber_api_key, "component_names": [ "Connector", "Deploy", "Health", ], }, ) ``` #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. #### Subscriber validation Marketplace will validate `domain_name` to `api_key` attachment to verify the claim of the environment ownership. Depending on the ownership validation results, Marketplace can either abort or the request or carry on with the subscription changes. ##### Request Subscribe to Miscellaneous ComponentsSubscribe to Credit ComponentsSubscribe to DevOps Suite Components application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Deploy", "Environment" ] } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "amazing.staircaseapi.com", "components_names": [ "Credit" ] } ``` application/json Copy ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Assess", "Assess-security-data", "Assess-staircase-data", "Assess-swagger-data", "Build", "Code", "Comply", "Deploy", "Environment", "Test" ] } ``` ##### Response 201400 application/json400 text/html403404 application/json Copy Subscription has been updated ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "domain_name": "one.staircaseapi.com", "component_names": [ "Assess", "Assess-security-data", "Assess-staircase-data", "Assess-swagger-data", "Build", "Code", "Comply", "Deploy", "Environment", "Test" ] } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested subscription not found ``` { "message": "Subcription not found" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `domain_name`required | `string` | Environment domain nameExample `template.staircaseapi.com` | | `api_key`required | `string` | Environment API keyExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | | `component_names`required | `string[]` | Array of component names. Must have unique items. | | `callback_url` | `string (uri)` | Used for a subscription observability. | ##### Response `201``application/json` 2 fields Subscription has been updated | Field | Type | Description | | --- | --- | --- | | `domain_name` | `string` | Environment domain nameExample `template.staircaseapi.com` | | `component_names` | `string[]` | The list of components to subscribe to | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested subscription not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error message.Example `Subcription not found` | `DELETE` `/subscriptions/{domain_name}` #### Delete Subscription[warning] `deleteSubscription` Delete a subscription Delete subscription from an environment. If query parameter not specified then a subscription for all components will be deleted. This will delete deployment history for affected components. #### Deprecation notice Marketplace will stop accepting `product_name` and `data_bundle_name` query parameters starting from December 2022. In order to delete subscription from a component, please use `component_name` query parameter instead. Example: ``` import requests requests.delete( f"", params={"component_name": component_name}, ) ``` ##### Response 400 application/json400 text/html403404 application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested subscription not found ``` { "message": "Subscription not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `domain_name` required | `string` path | `template.staircaseapi.com` | Domain name | | `component_name` | `string` query | `ComponentName` | The name of the component from Marketplace | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested subscription not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Subscription not found` | ##### Other responses `204` `GET` `/subscriptions/{domain_name}/status` #### Check Status[warning] `components_delivery_statuses` Subscription Status #### Subscription Status Retrieves a status of delivery for each subscribed component that an environment has subscribed to. Use query parameters to get status by specific component. ##### Subscription status Status changes when subscription-specific operations occur. For example, if the Component to which you're subscribed gets an update, or you create a subscription. The following is an ordered flow for the subscription status changes. Show the rest | Status | Meaning | | --- | --- | | `INITIATED` | Subscription to a component has been created and awaiting the delivery. | | `IN_QUEUE` | Delivery started, deployments are pending. | | `FAILED` | Delivery failed, deployment attempts have failed. | | `SUCCEEDED` | Delivery succeeded. | #### Deprecation notice Starting from December 2022 Marketplace will no longer display status entries inside the `products` and `data` arrays. Status entries will be represented in an array named `components`, and have the following changes: | Deprecated field | Moved to | | --- | --- | | `products[*].product_name` | `components[*].component_name` | | `products[*].deploy_status` | `components[*].delivery_status` | | `products[*].using_bundle_id` | `components[*].component_publication_id` | | `data[*].product_name` | `components[*].component_name` | | `data[*].deploy_status` | `components[*].delivery_status` | | `data[*].using_bundle_id` | `components[*].component_publication_id` | In `products[*].{field name}`, `data[*].{field name}` and `components[*].{field name}` – the `[*]` notation refers to “any item of the array” of `products`, `data` or `components` accordingly. ##### Get changes Before the new release gets rolled out, users can use `force_compact_status_report` query parameter with the value `true` (case-sensitive) to get responses as documented. When this parameter is provided, Marketplace will respond with new schema changes applied. Here's the example on how to invoke such request: ``` import json, requests delivery_statuses = requests.get( f"", params={"force_compact_status_report": json.dumps(True)}, ) ``` Output example: ``` { "domain_name": "twenty-uch.staircaseapi.com", "components": [ { "delivery_status": "SUCCEEDED", "component_name": "Connector", "last_deployment_id": "01GCD2RTN1PT5PE0NHMGV1SQ8R", "status_updated_date": "2022-09-25T09:29:03.843986+00:00", "component_publication_id": "01RC91SYEC28WZT714KXQPF0QD" } ], "page": { "count": 1, "next_token": null } } ``` #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. ##### Response 200400403404 application/json Copy Deployment status per product ``` { "domain_name": "dev-marketplace.staircaseapi.com", "components": [ { "component_name": "Assess-data", "status_updated_date": "2021-09-20T16:01:51.141673+00:00", "component_publication_id": "01G18AHNKFAEF3QEKTZJBTDF86", "delivery_status": "SUCCEEDED", "last_deployment_id": "01GCD2RTN1PT5PE0NHMGV1SQ8R" } ], "page": { "count": 1, "next_token": null } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `domain_name` required | `string` path | `template.staircaseapi.com` | Domain name | | `force_compact_status_report` | `string` query | `true` | Whether or not to use the new version of status representation. Not required for the invocation. | | `next_token` | `string` query | `eyJhZnRlcl9wcm9kdWN0X3R5cGUiOiAiU0VSVklDRSIsICJhZnRlcl9wcm9kdWN0X25hbWUiOiAiQSIsICJhZnRlcl9kb21haW5fbmFtZSI6ICI5OC51d2lueC5raW5kLmNsb3VkIn0=` | Pagination token. Works only with `force_compact_status_report` applied. | ##### Response `200``application/json` 3 fields Deployment status per product | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `domain_name` | `string` | Environment domain name.Example `template.staircaseapi.com` | | `components` | `object[]` | The list of components with delivery statuses. | | `component_name` | `string` | Component name.Example `Build` | | `delivery_status` | `string` | Delivery status.`FAILED``INITIATED``IN_QUEUE``SUCCEEDED`Example `SUCCEEDED` | | `component_publication_id` | `string` | The bundle ID of a component used in the delivery process. Can be null.Example `01G18AHNKFAEF3QEKTZJBTDF86` | | `status_updated_date` | `string` | Last updated date.Example `2021-09-21T00:27:57.112734+00:00` | | `last_deployment_id` | `string` | Latest available deployment ID used in delivery. Can be null.Example `01GCD2RTN1PT5PE0NHMGV1SQ8R` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `GET` `/subscriptions/{domain_name}/deployments` #### List Deployment History `getSubscriptionDeployments` #### List Deployment History Retrieves deployment history for each component in an environment. Note: It's recommended to provide specific component name to filter out deployment logs. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400 application/json400 text/html403404 application/json Copy Subscription deployment history by product. ``` { "domain_name": "template.staircaseapi.com", "logs": [ { "deployment_status": "SUCCEEDED", "component_name": "Build", "created_at": "2021-05-31T17:45:00.352518+00:00", "deployment_bundle_id": "620cc74e-4ffe-489c-955e-64e8e1693352" }, { "deployment_status": "SUCCEEDED", "component_name": "Code", "created_at": "2021-07-02T10:02:18.339430+00:00", "deployment_bundle_id": "a48e4d44-31d0-4106-8518-1d67e0abb783" } ], "page": { "count": 2, "next_token": null } } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested deployment logs not found ``` { "message": "Deployment history not found" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `domain_name` required | `string` path | `template.staircaseapi.com` | Domain name | | `component_name` | `string` query | `Build` | Component name from Marketplace. If provided, Marketplace will list deployments for this component only. | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `3` | Limit the count of items returned. Must be greater than or equal to 1 and less than or equal to 100. | ##### Response `200``application/json` 3 fields Subscription deployment history by product. | Field | Type | Description | | --- | --- | --- | | `domain_name` | `string` | Environment domain name.Example `template.staircaseapi.com` | | `logs` | `object[]` | The list of deployment logs. | | `deployment_bundle_id` | `string` | Deployment bundle ID.Example `ee537ce2-a80e-4ca6-b87b-25056677c10x` | | `deployment_status` | `string` | Deployment status.Example `SUCCEEDED` | | `created_at` | `string` | Deployment start invocation date.Example `2021-09-21T00:27:57.112734+00:00` | | `component_name` | `string` | Component name.Example `Connector` | | `page` | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested deployment logs not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Deployment history not found` | `GET` `/subscriptions/environments` #### List Environments `getSubscribedEnvironments` #### List Environments Retrieves a list of subscribed environments. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 400 application/json400 text/html403404 application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Subscribed environments not found ``` { "message": "Subscribed environments not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `3` | Limit the count of items returned. | ##### Response `200``application/json` 2 fields Subscribed environments info | Field | Type | Description | | --- | --- | --- | | `environments` | `string[]` | The list of subscribed environments. | | `page` | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Subscribed environments not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Subscribed environments not found` | `GET` `/subscriptions/query` #### List Subscribers of Component `getSubscribedEnvironmentsPerProduct` #### List Subscribers of Component Query Subscribers of Marketplace, subscribed to a particular component. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 400 application/json400 text/html403404 application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `component_name` required | `string` query | `Connector` | Component name from Marketplace | | `next_token` | `string` query | `eyJhZnRlcl9wcm9kdWN0X3R5cGUiOiAiU0VSVklDRSIsICJhZnRlcl9wcm9kdWN0X25hbWUiOiAiQSIsICJhZnRlcl9kb21haW5fbmFtZSI6ICI5OC51d2lueC5raW5kLmNsb3VkIn0=` | Pagination token. | | `limit` | `number` query | `50` | Limit the size of output. Must be greater than or equal to 1 and less than or equal to 100. Default values is 50 | ##### Response `200``application/json` 2 fields Subscribed environments info | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination token. | | `subscribed_domains` | `string[]` | The list of subscribed environments. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `404` `POST` `/listeners/{listener_kind}/subscriptions` #### Listen to Deliveries `create_listener` #### Listen to Deliveries `Listen To Deliveries` essentially creates a new listener, then binds it to a subscriber environment. The listener is a configuration of communication strategies. If the environment, identified by `domain_name` field, does not have a Subscription associated with it, a subscription Listener can't be created for it. The following endpoint is where you can create a subscription: Create Subscription. Show the rest #### Listener kinds ##### `realtime` `realtime` kind of listener solves a strategy whenever delivery of the component occurs. Delivery of the particular component occurs when: - Subscription was created for the subscriber environment - Component has been installed - Dependency of a direct subscribing component has been installed #### Strategy kinds ##### `webhook` `webhook` is the simplest way of notifying a listener. The strategy resolution will result in one-time webhook sent whenever an arbitrary component completes its way to the environment identified by the `domain_name`, it may fail, or it may complete successfully. Note that, Marketplace sends an HTTP webhook using POST verb without any additional headers, such as Authorization, `x-api-key` etc. The structure for the webhook payload is defined below: ``` { "$schema": "", "type": "object", "additionalProperties": true, "examples": [ { "subscription": { "elapsed_time": 495.95, "component_name": "Connector", "domain_name": "twenty-three.staircaseapi.com", "status": "SUCCEEDED", "product_id": "3acd1bb2-ee82-4504-a4fa-9e319811605b" } } ], "properties": { "subscription": { "type": "object", "additionalProperties": true, "properties": { "elapsed_time": { "type": "number", "description": "Represents how much it took to deliver a component." }, "component_name": { "type": "string", "description": "Component name Marketplace used in delivery." }, "domain_name": { "type": "string", "description": "Represents delivery target." }, "status": { "type": "string", "description": "Represents delivery status.", "enum": [ "FAILED", "SUCCEEDED" ] }, "product_id": { "type": "string", "description": "Represents the ID of the product to which the component is linked." } } } } } ``` Please note that the schema can be extended to have new fields. Example of the webhook payload: ``` { "subscription": { "elapsed_time": 495.95, "component_name": "Connector", "domain_name": "twenty-three.staircaseapi.com", "status": "SUCCEEDED", "product_id": "3acd1bb2-ee82-4504-a4fa-9e319811605b" } } ``` #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. #### Subscriber validation Marketplace will validate `domain_name` to `api_key` attachment to verify the claim of the environment ownership. Depending on the ownership validation results, Marketplace can either abort the request or carry on with creating a listener. ##### Request application/json Copy ``` { "domain_name": "example-dot-com.staircaseapi.com", "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "description": "Example dot com environment component updates.", "strategy": { "kind": "webhook", "webhook": { "url": "https://example.com/partners/staircase-marketplace/webhooks/" } } } ``` ##### Response 400403404409422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `listener_kind` required | `string` path | `realtime` | Type of a listener. Can only have `realtime` as a value. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `domain_name` | `string` | Subscriber environment.Example `best.staircaseapi.com` | | `description` | `string` | Description must fit into 120 characters.Example `Example description.` | | `strategy` | `object` | Strategy used for notifying the downstream. | | `kind`required | `string` | Communication kind.`webhook`Example `webhook` | | `webhook`required | `object` | Webhook object represents receiving url, to which the webhook is sent. | | `url`required | `string (uri)` | Must be a valid URL with HTTPS scheme.Example `https://google.com/staircase/marketplace/webhooks` | | `api_key`required | `string` | API key of the subscriber. Is used for validation.Example `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``409``422` `DELETE` `/listeners/{listener_kind}/subscriptions/{domain_name}` #### Remove Listener `remove_listener` #### Remove Listener Removes listener for a given subscriber identified by `domain_name`. To use `Subscriber validation`, you need to provide an API key in query parameters. #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. #### Subscriber validation Marketplace will validate `domain_name` to `api_key` attachment to verify the claim of the environment ownership. Depending on the ownership validation results, Marketplace can either abort the request or carry on with deleting a listener. ##### Response 400403404422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `listener_kind` required | `string` path | `realtime` | Type of a listener. Can only have `realtime` as a value. | | `api_key` required | `string (uuid)` query | `` | API key, which belongs to an environment identified by `domain_name`. | | `domain_name` required | `string` path | `template.staircaseapi.com` | Domain name | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``422` `GET` `/listeners/{listener_kind}/subscriptions/{domain_name}` #### Get Listener `get_listener` #### Get Listener Retrieves the information about the listener, such as strategy and listener kind. If the `api_key` declared in query parameters does not belong to a `domain_name` from path parameters, response parts such as webhook URL will be censored and have a string value of `value__hidden`. #### Open endpoint This endpoint is open. Endpoint is open, when you can omit request authorization via `x-api-key` header. #### Subscriber validation Marketplace will validate `domain_name` to `api_key` attachment to verify the claim of the environment ownership. Depending on the ownership validation results, Marketplace can either obfuscate some parts of the response or return the full information about the listener. ##### Response 200 Basic example of the response200 Example with obfuscation400403404 application/json Copy The listener has been retrieved successfully. ``` { "listener": { "strategy": { "kind": "webhook", "webhook": { "url": "https://webhooks.staircaseapi.com/abc-webhooks" } }, "description": "Marketplace deliveries monitoring channel." } } ``` application/json Copy The listener has been retrieved successfully. ``` { "listener": { "strategy": { "kind": "webhook", "webhook": { "url": "value__hidden" } }, "description": "Marketplace deliveries monitoring channel." } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `listener_kind` required | `string` path | `realtime` | Type of a listener. Can only have `realtime` as a value. | | `api_key` required | `string (uuid)` query | `` | API key, which belongs to an environment identified by `domain_name`. | | `domain_name` required | `string` path | `template.staircaseapi.com` | Domain name | ##### Response `200``application/json` 1 fields The listener has been retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `listener`required | `object` | Object representing listener. | | `domain_name` | `string` | Subscriber environment.Example `best.staircaseapi.com` | | `description` | `string` | Description must fit into 120 characters.Example `Example description.` | | `strategy` | `object` | Strategy used for notifying the downstream. | | `kind`required | `string` | Communication kind.`webhook`Example `webhook` | | `webhook`required | `object` | Webhook object represents receiving url, to which the webhook is sent. | | `url`required | `string (uri)` | Must be a valid URL with HTTPS scheme.Example `https://google.com/staircase/marketplace/webhooks` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` ### Ontology `GET` `/ontology/families` #### List families `get_families` #### List Families Retrieve a list of families registered in catalog. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy List of families. ``` { "families": [ { "family_name": "Platform", "family_id": "da8bc1af-848-454-bfb-14131e81a518", "description": "Example description", "created_at": "2022-05-25T15:53:11.237890+00:00" } ], "page": { "count": 1, "next_token": "eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN" } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `3` | Limit the count of items returned. Must be greater than or equal to 1 and less than or equal to 100. | ##### Response `200``application/json` 2 fields List of families. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `families`required | `object[]` | Array of families. | | `family_name`required | `object` | Name of the Family.Example `DevOps` | | `family_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `created_at`required | `string` | Date and time of the latest modification or creation operations. String is in ISO 8601 format.Example `2022-05-25T15:53:11.237890+00:00` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/families` #### Create family `create_family` #### Create Family Registers a new family in the ontology, returning an identifier in the response payload. Family is at the highest level of ontology. Family identifier can be used to explore categories registered within the family. #### Naming conventions The name of the family must fit into one word or an acronym. The name is not a unique identifier of the family. Instead, families are referenced by their unique identifiers, i.e., `family_id`. Family ID is assigned by Marketplace at the creation and is returned after successful creation. ##### Request application/json Copy ``` { "family_name": "Platform" } ``` ##### Response 201400403404409 application/json Copy Family was successfully created. ``` { "family_id": "df8f01bb-848-4f54-bfb-14131e81a518" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `family_name`required | `object` | Name of the Family.Example `DevOps` | ##### Response `201``application/json` 1 fields Family was successfully created. | Field | Type | Description | | --- | --- | --- | | `family_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404``409` `GET` `/ontology/families/{family_id}/categories` #### List categories `get_categories` #### List Categories Retrieves a list of categories for a specific Family. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy Return a list of categories. ``` { "family_id": "df8f01bb-848-454-bfb-14131e81a518", "family_name": "Platform", "categories": [ { "category_name": "Integrate", "category_id": "dc8c01bb-848-454-bcb-14131e81c518", "created_at": "2022-05-20T18:16:16.071810+00:00" } ], "page": { "count": 1, "next_token": "eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN" } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `family_id` required | `string (uuid)` path | `df8f01bb-848-454-bfb-14131e81a518` | Family ID. | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `20` | Limit the count of items returned. | ##### Response `200``application/json` 4 fields Return a list of categories. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `family_id`required | `string` | Unique identified of a family. | | `family_name`required | `string` | Name of the family under which categories are located. | | `categories`required | `object[]` | Array of categories | | `category_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `category_name`required | `string` | Name of the category. | | `created_at`required | `string` | Date and time of the latest modification or creation operations. String is in ISO 8601 format.Example `2022-05-25T15:53:11.237890+00:00` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/families/{family_id}/categories` #### Create category `create_category` #### Create Category Registers a new category under the existing family in the ontology. Category is the second-highest level entity in ontology. Category gets linked to the family it has been created under. #### Naming conventions The name of the family must fit into one word or an acronym. The name is not a unique identifier of the category. Instead, categories are referenced by their unique identifiers, i.e., `category_id`. Category ID is assigned by Marketplace at the creation and is returned after successful creation. ##### Request application/json Copy ``` { "category_name": "Integrate" } ``` ##### Response 201400403404409 application/json Copy Category was successfully created. ``` { "category_id": "dc8c01bb-848-454-bfb-14131e81a518" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `family_id` required | `string (uuid)` path | `df8f01bb-848-454-bfb-14131e81a518` | Family ID. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `category_name`required | `object` | Name of the Category.Example `Ship` | ##### Response `201``application/json` 1 fields Category was successfully created. | Field | Type | Description | | --- | --- | --- | | `category_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404``409` `GET` `/ontology/categories/{category_id}/products` #### List Products `get_products_in_category` #### List products Retrieves a list of products registered in the ontology. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy Return a list of products. ``` { "category_id": "dc8c01bb-848-454-bfb-14131e81a518", "category_name": "Integrate", "products": [ { "product_id": "da8b01ba-848-454-bfb-14131e81a518", "product_name": "Connector", "created_at": "2022-05-20T18:19:16.071810+00:00" } ], "page": { "count": 1, "next_token": "eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN" } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `category_id` required | `string (uuid)` path | `dc8c01bb-848-454-bfb-14131e81a518` | Category ID. | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `3` | Limit the count of items returned. Must be greater than or equal to 1 and less than or equal to 100. | ##### Response `200``application/json` 4 fields Return a list of products. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `category_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `category_name`required | `string` | Name of the category under which product is located. | | `products`required | `array` | Array of products | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/categories/{category_id}/products` #### Create Product `create_product` #### Create Product Registers a new product under the existing category in the ontology. Product is the third-highest level entity in ontology. Product gets linked to the category it has been created under. #### Naming conventions The name of the product must fit into one word or an acronym. The name is not a unique identifier of the product. Instead, families are referenced by their unique identifiers, i.e., `product_id`. Product ID is assigned by Marketplace at the creation and is returned after successful creation. ##### Request application/json Copy ``` { "product_name": "Connector" } ``` ##### Response 201400403404409 application/json Copy Product was successfully created. ``` { "product_id": "da8b01ba-848-454-bfb-14131e81a518" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `category_id` required | `string (uuid)` path | `dc8c01bb-848-454-bfb-14131e81a518` | Category ID. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `product_name`required | `object` | Name of the Product.Example `Build` | | `category_id` | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `201``application/json` 1 fields Product was successfully created. | Field | Type | Description | | --- | --- | --- | | `product_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404``409` `DELETE` `/ontology/families/{family_id}` #### Delete Family `delete_family` #### Delete Family Deletes a family from the catalog. This action is permanent and cannot be undone. #### References Note that you cannot delete a family if there are categories registered under the family. ##### Response 400403404409 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `family_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Family ID | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``409` `DELETE` `/ontology/categories/{category_id}` #### Delete Category `delete_category` #### Delete Category Deletes category from the ontology. This action is permanent and cannot be undone. #### References Note that you cannot delete a category if there are products registered under the category. ##### Response 400403404409 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `category_id` required | `string (uuid)` path | `dc8c01bb-848-454-bfb-14131e81a518` | Category ID. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``409` `DELETE` `/ontology/products/{product_id}` #### Delete Product `delete_product` #### Delete Product Deletes product from the ontology. This action is permanent and cannot be undone. #### References Note that you cannot delete a product if there are API entries left registered under the product. ##### Response 400403404409 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID to be removed from the ontology. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``409` `GET` `/ontology/products/{product_id}/managed_metadata` #### List Managed Metadata `get_managed_metadata` #### List Managed Metadata Retrieves a list of managed metadata for a specific product. #### Managed Metadata Managed metadata is maintained by Marketplace individually for different use-cases. Example of such use-case is code assessment regulator's version hash control. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403 application/json Copy Return a list of managed metadata. ``` { "product_id": "eea62230-d9fe-4b37-868a-fd7d75d3cb53", "product_name": "Product", "metadata_history": [ { "metadata": { "version_hash": "version_two" } }, { "metadata": { "version_hash": "version_one" } } ], "page": { "next_token": "cGs9UFJPRFVDVCUyM2VlYTYyMjMwLWQ5ZmUtNGIzNy04NjhhLWZkN2Q3NWQzY2I1MyZzaz1NQU5BR0VEX01FVEFEQVRBJTIzUkVWSVNJT04lMjNyZXZpc2lvbiUzQTAxSEpCVFNBNUNDUkFZR0dGMUs1MjhHQTgw", "count": 2 } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | ##### Response `200``application/json` 4 fields Return a list of managed metadata. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `product_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `product_name`required | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | | `metadata_history`required | `object[]` | — | | `metadata` | `object` | — | | `version_hash` | `string` | Example `version_two` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400` `GET` `/ontology/representation` #### Full Representation Link `ontology_repr` #### Represent Full Ontology Generates URL for the active ontology. Ontology representation describes the whole ontology. The URL is located under a property named `ontology_url` in the response payload. #### Example of Ontology Representation An item within the list of entities of the corresponding entity map provides a link to an upper level entity: - “category” is aware of the family it's created under. Use `family_id` to navigate back to family. - “product” is aware of the category it's created under. Use `category_id` to navigate back to category. - "configuration" is aware of the product it is registered under. Use `product_id` to navigate back to product. - “API” is aware of the product it's registered under. Use `product_id` to navigate back to product. - “component” is aware of the product it's created under. Use `product_id` to navigate back to product - “price” is aware of the API it's created under. Use `product_api_identifier` to navigate back to API. Example: Show the rest ``` { "families": [ { "family_id": "965b4d6b-4c00-4c50-b321-c991d60dbf30", "created_at": "2022-07-14T09:45:38.839462+00:00", "family_name": "DevOps" }, ... ], "categories": [ { "category_id": "19a7d3ac-9203-4a5f-bdc9-df7e7951cb56", "created_at": "2022-07-14T09:45:38.840851+00:00", "category_name": "Delivery" }, ... ], "products": [ { "category_id": "19a7d3ac-9203-4a5f-bdc9-df7e7951cb56", "created_at": "2022-07-14T09:45:38.841529+00:00", "product_name": "Marketplace", "product_id": "01c9df65-4c81-4278-a5b9-501a0e57b4a5" }, ... ], "api": [ { "product_api_name": "DescribeDeliveryAttributes", "product_id": "01c9df65-4c81-4278-a5b9-501a0e57b4a5", "product_api_identifier": "2b4a383c-604d-46b1-a303-b13e038ca6ed", "product_api_type": "function", "product_api_description": "Describe delivery attributes of a certain delivery." }, ... ], "prices": [ { "price_invocation_type": "single_partner", "price_calculation_type": "average_supplier", "price_timing_type": "completion", "price_unit_type": "transaction", "price_amount": 200, "product_api_identifier": "2b4a383c-604d-46b1-a303-b13e038ca6ed", "product_price_identifier": "98190224-9a17-4edc-a285-c1b5ee69a044", "price_revision_identifier": "revision:01G7Y1K08YB53MAVSF14KZHTC5", "price_amount_unit_type": "cent" }, ... ], "components": [ { "component_name": "Connector", "product_id": "6ccd1bb2-ee82-4504-b4ca-9e139811506a", "dependencies": [ "connection-datum", "connection-logger" ] }, ... ] } ``` #### Notice on Consistency Note that the ontology representation is regenerated once at a given rate and can be outdated for the sequential changes and link retrieval request. Marketplace will provide ontology subscription mechanism soon. ##### Response 200400403 application/json Copy The ontology link has been regenerated successfully. And property named `ontology_url` contains it. ``` { "ontology_url": "https://dev-marketplace-bundles-bucket-us-east-1-293107503335.s3.amazonaws.com/ontology-representation/2025-07-14?AWSAccessKeyId=&Signature=L0ML&x-amz-security-token=&Expires=1657812052" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Response `200``application/json` 1 fields The ontology link has been regenerated successfully. And property named `ontology_url` contains it. | Field | Type | Description | | --- | --- | --- | | `ontology_url`required | `string (uri)` | The URL for the ontology.Example `https://dev-marketplace-bundles-bucket-us-east-1-293107503335.s3.amazonaws.com/ontology-representation/2025-07-14?AWSAccessKeyId=&Signature=L0ML&x-amz-security-token=&Expires=1657812052` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400` `GET` `/ontology/representation/raw` #### Full Representation `ontology_repr_json` #### Represent Full Ontology Retrieves cached ontology representation. Ontology representation describes the whole ontology. #### Notice on Consistency Note that the ontology representation is regenerated once at a given rate and can be outdated for the sequential changes and link retrieval request. Marketplace will provide ontology subscription mechanism soon. ##### Response 200400403 application/json Copy The ontology link has been regenerated successfully. And property named `ontology_url` contains it. ``` { "families": [ { "family_name": "DevOps", "created_at": "2022-07-13T03:38:06.744123+00:00", "family_id": "62f5691e-7fd0-4728-ac3c-977dea07f338" } ], "categories": [ { "category_name": "Shipping", "created_at": "2022-07-13T03:38:06.801765+00:00", "family_id": "62f5691e-7fd0-4728-ac3c-977dea07f338", "category_id": "f06e9a78-5eca-441d-a6ae-6ec6a90e703a" } ], "products": [ { "product_name": "Assess", "product_id": "c9eb8899-73b2-4733-86fb-75bd9a1f3170", "category_id": "f06e9a78-5eca-441d-a6ae-6ec6a90e703a", "created_at": "2022-07-13T03:38:06.813104+00:00" } ], "configurations": [], "api": [ { "product_api_invocation_type": "analytics", "product_api_description": "Validates a bundle of source code according to the rules configured", "product_api_type": "function", "product_api_name": "Assess", "product_id": "c9eb8899-73b2-4733-86fb-75bd9a1f3170", "product_api_identifier": "051f6aeb-d1d8-4e0c-80b5-7e59daf68521" } ], "prices": [ { "price_amount_unit_type": "cent", "price_timing_type": "completion", "price_calculation_type": "cost_of_goods_sold", "price_unit_type": "transaction", "price_amount": 5, "price_revision_identifier": "revision:01G9FDNFB2ERX0E58WX2R96TGG", "product_api_identifier": "051f6aeb-d1d8-4e0c-80b5-7e59daf68521", "product_price_identifier": "930e2bc5-5cb5-4210-b0c3-67e4c76548b7" } ], "components": [ { "component_name": "Assess-security-data", "product_id": "c9eb8899-73b2-4733-86fb-75bd9a1f3170", "dependencies": [ "Assess" ] }, { "component_name": "Assess-staircase-data", "product_id": "c9eb8899-73b2-4733-86fb-75bd9a1f3170", "dependencies": [ "Assess" ] }, { "component_name": "Assess-swagger-data", "product_id": "c9eb8899-73b2-4733-86fb-75bd9a1f3170", "dependencies": [ "Assess" ] }, { "component_name": "Assess", "product_id": "c9eb8899-73b2-4733-86fb-75bd9a1f3170", "dependencies": [] } ] } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `200``400` `GET` `/ontology/products` #### List Products With Name Filter `products_by_name` #### List Products With Name Filter Retrieves a list of products registered in the ontology, applying the provided filter for product's name. Each Product matching name is returned. Category ID is included in the product ID for the easier navigation upwards. ##### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy Return a list of products. ``` { "products": [ { "product_id": "da8b01ba-848-454-bfb-14131e81a518", "product_name": "Build", "created_at": "2022-05-20T18:19:16.071810+00:00", "category_id": "dc8c01bb-848-454-bfb-14131e81a518" } ], "page": { "count": 1, "next_token": null } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` query | `Build` | Component name. | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `5` | Limit the count of items returned. | ##### Response `200``application/json` 2 fields Return a list of products. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `products`required | `array` | Array of products | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PATCH` `/ontology/{ontology_entity_typename}/{ontology_entity_id}/metadata` #### Extend Entity Metadata `update_any_metadata` Update Metadata #### Update Metadata Updates the metadata of the given entity. Metadata might consist of operational data, which helps to understand how Product owners manage its operations. - Note: Marketplace appends provided metadata to the existing one, so old fields are kept. ##### Ontology Entities Eligible For Metadata Path parameter `ontology_entity_typename` can be one of the following: - `categories` - `families` - `products` ##### Request ConnectionProductMetadataDevOpsFamilyMetadata application/json Copy ``` { "metadata": { "description": "Wrap upstream API operations for multiple partners using \"Connection State Language\".", "asana_board_id": "23349323054118939", "asana_board_url": "https://app.asana.com/12/23349323054118939", "codex": "https://codex.io/managed/Connector", "documentation": "https://api.staircase.co/docs/Platform/Integrate/Connector", "homepage": "https://api.staircase.co/docs/Platform/Integrate/Connector#root" } } ``` application/json Copy ``` { "metadata": { "description": "DevOps – Family of products, which enables you rapid software integration and delivery, providing extremely rich toolset.", "homepage": "https://api.staircase.co/docs/DevOps#root" } } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ontology_entity_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Entity ID. Can be an ID for the family, product or category. | | `ontology_entity_typename` required | `string` path | `families` | Entity typename. Can be `families`, `products` or `categories`. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `metadata`required | `one of` | Information helpful to understand operations of the product. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `GET` `/ontology/{ontology_entity_typename}/{ontology_entity_id}/metadata` #### Get Entity Metadata `get_any_metadata` Get Metadata #### Get Metadata Retrieves the metadata of the given entity. Metadata might consist of operational data, which helps to understand how Product owners manage its operations. ##### Ontology Entities Eligible For Metadata Path parameter `ontology_entity_typename` can be one of the following: - `categories` - `families` - `products` ##### Response 200400403404 application/json Copy Successfully retrieved Product's Metadata. ``` { "metadata": { "asana_board_id": "23349323054118939", "asana_board_url": "https://app.asana.com/12/23349323054118939", "codex": "https://codex.io/managed/Connector", "documentation": "https://api.staircase.co/docs/Platform/Integrate/Connector", "homepage": "https://api.staircase.co/docs/Platform/Integrate/Connector#root" } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ontology_entity_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Entity ID. Can be an ID for the family, product or category. | | `ontology_entity_typename` required | `string` path | `families` | Entity typename. Can be `families`, `products` or `categories`. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 1 fields Successfully retrieved Product's Metadata. | Field | Type | Description | | --- | --- | --- | | `metadata`required | `one of` | Information helpful to understand operations of the product. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PATCH` `/ontology/families/{family_id}` #### Update Family[new] `update_family` Update Family #### Update Family Updates family identified by its identifier. ##### Request application/json Copy ``` { "family_name": "Mortgage" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `family_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Family ID | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `family_name`required | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `PATCH` `/ontology/categories/{category_id}` #### Update Category[new] `update_category` Update Category #### Update Category Updates category identified by its identifier. ##### Request application/json Copy ``` { "category_name": "Tools" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `category_id` required | `string (uuid)` path | `dc8c01bb-848-454-bfb-14131e81a518` | Category ID. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `category_name` | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | | `family_id` | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `GET` `/ontology/products/{product_id}` #### Get Product[new] `get_product` Get Product #### Get Product Retrieves product identified by its identifier. ##### Response 200400403404 application/json Copy Return a product. ``` { "product_id": "da8b01ba-848-454-bfb-14131e81a518", "product_name": "Connector", "created_at": "2022-05-20T18:19:16.071810+00:00" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID to be removed from the ontology. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 4 fields Return a product. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `category_id`required | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `category_name`required | `string` | Name of the category under which product is located. | | `products`required | `array` | Array of products | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PATCH` `/ontology/products/{product_id}` #### Update Product[new] `update_product` Update Product #### Update Product Updates product identified by its identifier. ##### Request application/json Copy ``` { "product_name": "Connection" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID to be removed from the ontology. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `product_name`required | `object` | Name of the Product.Example `Build` | | `category_id` | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` ### Product `GET` `/ontology/products/{product_id}/api` #### Get Product API With Prices[updated] `join_product_api_with_latest_price` Get Product API With Prices #### Get Product API With Prices Retrieves all registered API entries for a given product. The items in the resulting list are extended with the latest price revision. If the API is not registered with price revision under it, there will be no price information in the item. #### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy Successfully retrieved API and price revisions. ``` { "page": { "count": 1, "next_token": "eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN" }, "product_id": "da8bc1af-848-454-bfb-14131e81a518", "product_name": "Build", "api": [ { "api": { "product_api_name": "CreateArtifactForPackage", "product_api_description": "Creates an artifact for a given package.", "product_api_type": "function", "product_api_identifier": "da8bc1af-848-454-bfb-14131e81a518", "invocation_type": "analytics" }, "price": { "price_amount": 10, "price_amount_unit_type": "cent", "price_calculation_type": "average_supplier", "price_timing_type": "completion", "price_unit_type": "environment", "product_price_identifier": "da8bc1af-848-454-bfb-14131e81a518", "price_revision_identifier": "revision:01G6N30DHYMPRKETP1ACEEXAMP" } } ] } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `5` | Limit the count of items returned. Must be greater than or equal to 1 and less than or equal to 15. If `include_prices` is `false` the limit can have a maximum value of 100. | | `include_prices` | `string` query | `true` | Flag determines if the output should contain prices along with API entries. true by default | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 4 fields Successfully retrieved API and price revisions. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `product_id` | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `product_name` | `object` | Name of the Product.Example `Build` | | `api` | `object[]` | — | | `api` | `object` | — | | `product_api_name` | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | | `product_api_description` | `string` | Brief explanation for an API does. | | `product_api_type` | `string` | The fundamental type of API.`configuration``function``platform`Example `function` | | `product_api_invocation_type` | `string` | What an application endpoint does, when invoked successfully.`aggregated_partner``analytics``environment``notification``operation``proxy``single_partner`Example `analytics` | | `product_api_identifier`required | `string` | Unique identifier for this API.Example `da8bc1af-848-454-bfb-14131e81a518` | | `price` | `object` | — | | `price_amount`required | `number` | Value representing price in predefined unit.Example `10` | | `price_amount_unit_type`required | `string` | Price unit. Must be `cent`.`cent`Example `cent` | | `price_calculation_type`required | `string` | The price is calculated using one of the permitted pricing strategies.`average_supplier``cost_of_goods_sold``equivalent_labor_cost``maturity`Example `average_supplier` | | `price_timing_type`required | `string` | Price is included into billing based on this defined schedule.`completion``monthly`Example `completion` | | `price_unit_type`required | `string` | The unit of the platform where the price evaluation can be determined as relevant.`api_call``datapoint``document``environment``hour``image``page``person``person_hour``pm``pm_hour``product``seat``subscription``transaction`Example `environment` | | `product_price_identifier`required | `object` | Newly assigned price ID.Example `da8bc1af-848-454-bfb-14131e81a518` | | `price_revision_identifier`required | `string` | Revision indicator.Example `revision:01G6N30DHYMPRKETP1ACEEXAMP` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/products/{product_id}/api` #### Register an API `register_an_api` #### Register an API Registers an API for a given product. API is registered under the product. Product is referenced by its ID. APIs can serve as a basis for business value delivery or supervise the latter. API can be referenced by Product ID and API ID pair. Product ID must be the Product ID under which the API has registered. #### API type definition `product_api_type` generalizes the purpose of the API. An API can have three purposes and these are allowed values: Show the rest - `configuration` – APIs that control the behaviors of the other APIs. - `function` – APIs that perform functions. - `platform `– Platform APIs are those which provide the foundation blocks required by other APIs. #### API invocation type definition Staircase evaluates the type of API being invoked in order to determine price. For example, an `aggregated_partner` call will cost more than a `single_partner` call because more partners are being invoked. Usually only mortgage products have `single_partner` and `aggregated_partner` API calls. - `aggregated_partner` – Staircase APIs call multiple partner’s APIs by creating a partner invocation waterfall. - `analytics` – Staircase sends the product results in raw report format to the customer. - `environment` – Staircase APIs call in an environment. - `notification` – Staircase sends a notification to the customer that the product has completed and results are ready to be viewed. - `operation` – Staircase has basic 'function' APIs that preform specific operations, like calling product configuration. - `proxy` – Staircase APIs are proxies of other Staircase products, usually Staircase Platform products. API calls are internal. - `single_partner` – Staircase APIs only call one partner’s APIs when performing product functions such as data extraction or employment verification. ##### Request application/json Copy ``` { "product_api_name": "retrieveImageForGivenRevision", "product_api_type": "function", "product_api_description": "Retrieve an image for a given revision number.", "product_api_invocation_type": "single_partner" } ``` ##### Response 201400403404 application/json Copy Action were associated with the Product successfully. List of URIs follows. ``` { "product_api_identifier": "dc8a01fa-848-454-bfb-14131e81a518" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `product_api_name` | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | | `product_api_description` | `string` | Brief explanation for an API does. | | `product_api_type` | `string` | The fundamental type of API.`configuration``function``platform`Example `function` | | `product_api_invocation_type` | `string` | What an application endpoint does, when invoked successfully.`aggregated_partner``analytics``environment``notification``operation``proxy``single_partner`Example `analytics` | ##### Response `201``application/json` 1 fields Action were associated with the Product successfully. List of URIs follows. | Field | Type | Description | | --- | --- | --- | | `product_api_identifier`required | `string` | Unique identifier for this API.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PATCH` `/ontology/products/{product_id}/api/{api_id}` #### Update an API[new] `update_an_api` Update an API #### Update an API Updates chosen attributes of an API. The update request must introduce with at least one modification. ##### Request application/json Copy ``` { "product_api_name": "retrieveImageRevision", "product_api_type": "platform" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | | `api_id` required | `string (uuid)` path | `dc8a01fe-848-454-bfb-14131e81a518` | API ID | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `product_api_name` | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | | `product_api_description` | `string` | Brief explanation for an API does. | | `product_api_type` | `string` | The fundamental type of API.`configuration``function``platform`Example `function` | | `product_api_invocation_type` | `string` | What an application endpoint does, when invoked successfully.`aggregated_partner``analytics``environment``notification``operation``proxy``single_partner`Example `analytics` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `DELETE` `/ontology/products/{product_id}/api/{api_id}` #### Delete an API `deregister_an_api` Delete API #### Delete API Deletes an API for a given product. API can be deleted only if there is no price associated to it. Once deleted API is never shown in product's API list. ##### Response 400403404409 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy Request conflict. Request is conflicting with the current state of application or previous requests. ``` { "error": { "message": "Conflict.", "reason": "The given entity matches an existing item in the storage, thus cannot be operated on." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | | `api_id` required | `string (uuid)` path | `dc8a01fe-848-454-bfb-14131e81a518` | API ID | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``409` `DELETE` `/ontology/prices/{price_id}` #### Delete Price `delete_price` #### Delete Price Permanently deletes a price. It cannot be undone. Also, immediately clears revision history. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `price_id` required | `string (uuid)` path | `bb8b01bb-848-454-bfb-14131e81a518` | Price ID. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `GET` `/ontology/prices/{price_id}` #### Get The Latest Price Revision `get_latest_price` #### Get The Latest Price Revision Retrieves the details of the latest revision for the Price. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `price_id` required | `string (uuid)` path | `bb8b01bb-848-454-bfb-14131e81a518` | Price ID. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 7 fields Price was successfully deleted. | Field | Type | Description | | --- | --- | --- | | `price_amount`required | `number` | Value representing price in predefined unit.Example `10` | | `price_amount_unit_type`required | `string` | Price unit. Must be `cent`.`cent`Example `cent` | | `price_calculation_type`required | `string` | The price is calculated using one of the permitted pricing strategies.`average_supplier``cost_of_goods_sold``equivalent_labor_cost``maturity`Example `average_supplier` | | `price_timing_type`required | `string` | Price is included into billing based on this defined schedule.`completion``monthly`Example `completion` | | `price_unit_type`required | `string` | The unit of the platform where the price evaluation can be determined as relevant.`api_call``datapoint``document``environment``hour``image``page``person``person_hour``pm``pm_hour``product``seat``subscription``transaction`Example `environment` | | `product_price_identifier`required | `object` | Newly assigned price ID.Example `da8bc1af-848-454-bfb-14131e81a518` | | `price_revision_identifier`required | `string` | Revision indicator.Example `revision:01G6N30DHYMPRKETP1ACEEXAMP` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `GET` `/ontology/products/{product_id}/api/{api_id}` #### Retrieve an API `retrieve_an_api` #### Retrieve API Retrieves an API for a given product. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | | `api_id` required | `string (uuid)` path | `dc8a01fe-848-454-bfb-14131e81a518` | API ID | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 1 fields API was successfully retrieved. | Field | Type | Description | | --- | --- | --- | | `api` | `object` | API information retrieved. | | `product_api_name` | `string` | Canonical name of an entity in the ontology. Name must fit into one word or an acronym.Example `Identity` | | `product_api_description` | `string` | Brief explanation for an API does. | | `product_api_type` | `string` | The fundamental type of API.`configuration``function``platform`Example `function` | | `product_api_invocation_type` | `string` | What an application endpoint does, when invoked successfully.`aggregated_partner``analytics``environment``notification``operation``proxy``single_partner`Example `analytics` | | `product_api_identifier`required | `string` | Unique identifier for this API.Example `da8bc1af-848-454-bfb-14131e81a518` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PUT` `/ontology/products/{product_id}/api/{api_id}/prices` #### Create New Price Revision `create_price_revision` #### Create New Price Revision When you create a new price revision it automatically becomes the latest revision. #### Pricing Description Style and Content Descriptions should address the "what" of the product – what function is the product performing for the customer? It should begin with a verb that describes what function the API performs. For example: "Verify using multiple partners (waterfall)" Show the rest The first letter in the price description is uppercase. The remaining words in the pricing description are lowercase unless the word is an acronym like API, or a proper noun like Staircase. Do not put a period or any other punctuation at the end of the pricing description (the descriptions themselves are not sentences and therefore don’t need it). The `price_unit_type` will be shown as follows to the right of the actual cost, along with the word "per". Do not add `price_unit_type` to the description, for example "price for monthly subscription" is not a preferred description because it lists redundant information rather than tell the customers what functions they’re paying for. If the `price_unit_type` = `transaction`, Site product will add "per transaction" to the right of the actual cost displayed. Examples: - "$1.40 per transaction". If the `price_unit_type` = `subscription`, `environment`, `product` or `user`, the Site product will render the description as "{price_amount (in dollars)} per {price_unit_type}, per month". Examples: - $100 per subscription, per month - $9.99 per environment, per month - $5.00 per product, per month - $3.40 per user, per month ##### Description Conventions - If `product_api_invocation_type` = `aggregated_partner`, `description` = Invoke Product Using Multiple Partners. - If `product_api_invocation_type` = `analytics`, `description` = Generate and Store Analytics for Reporting. - If `product_api_invocation_type` = `environment`, `description` = Unlimited Use of Product APIs in Environment. - If `product_api_invocation_type` = `notification`, `description` = Notify via Email and SMS. - If `product_api_invocation_type` = `operation`, `description` = Invoke a Staircase product API. - If `product_api_invocation_type` = `proxy`, `description` = Invoke a proxy Staircase API. - If `product_api_invocation_type` = `single_partner`, `description` = Invoke a Product Using One Partner. - If `price_unit_type` = `subscription`, `description` should include less than 10 words of details on what function is being performed as part of the subscription. You do not need to include the word “subscription” in the description, as this word should be visible next to the actual price. ##### Mortgage "Partner" Products Example Mortgage products that make partner calls typically have four different types of pricing as listed in the example below. NOTE: The environment cost that these products incur is included in the transaction cost, so there is no need to add an "environment cost" per product. Examples: - Credit - Verify using multiple partners (waterfall). - Credit - Verify using one partner. - Credit - Invoke a proxy Staircase API. - Credit - Notify upon completion via email and SMS. - Employment - Verify using one partner. - Employment - Notify upon completion via email and SMS. - Employment - Invoke a proxy Staircase API. - Employment - Verify using multiple partners (waterfall). - Income - Verify using multiple partners (waterfall). - Income - Verify using one partner. - Income - Notify upon completion via email and SMS. - Income - Invoke a proxy Staircase API. #### Price definition - `price_amount` (Required|Number) – Value representing the cost. If non-integer, the value must have a fixed precision of two digits after the decimal point. The inclusive minimum value is `0.01` and the inclusive maximum is `999999.99` - `price_amount_unit_type` (Required|String) – Value representing the unit of cost. Currently, “cent” is the only allowed value. - `price_calculation_type` (Required|String) – Different machines of calculating Staircase price per transaction. - `price_unit_type` (Required|String) – The unit of the platform where the price evaluation can be determined as relevant. - `price_timing_type` (Required|String) – The price is included into the billing based on this defined schedule. ##### Enumeration variants for fields representing types. ###### price_calculation_type Staircase determines how price per transaction should be calculated based on the average or overall supplier fee, or on the labor costs saved. For pricing related to premium support, Staircase might also consider how large or mature the customer company is. - `average_supplier` – The cost is based on the average supplier fee. - `cost_of_goods_sold` – The cost is based on the overall supplier fee. - `equivalent_labor_cost` – The cost is based on the labor cost the API saves. - `maturity` – The cost is based on how large and mature the customer is. ###### price_unit_type Type of unit that defines which value is used as a measuring location for the calculation. - `environment` – One charge for an environment and all the product APIs it contains. Monthly. - `product` – A monthly charge per product. Company and Marketplace are likely to have a “Per Product” monthly charge. - `seat` – One charge per subscriber, for functions like premium support. No limit to the number of transactions a subscriber can run in a given month. - `subscription` – A monthly charge per product. Company and Marketplace are likely to have a “Per Product” monthly charge. - `transaction` – One charge per API call (upon completion of transaction). - `user` – A monthly charge per user. Setup and possibly PreApproval are likely to have a “Per User” monthly charge, where there is no limit to the number of product transactions a user can run in a given month. - `api_call` – One charge per API call. - `document` – One charge per document. - `hour` – One charge per hour. - `image` – One charge per image. - `page` – One charge per page. - `person` – One charge per person. - `person_hour` – One charge per person hour. - `pm` – One charge per product manager. - `pm_hour` – One charge per product manager hour. - `datapoint` – One charge per data point retrieved from the document. ###### price_timing_type Depending on the `price_unit_type`, Staircase will charge upon `completion` or on a `monthly` basis. ###### Allowed values are: - `completion` – Charged upon completion. - `monthly` – Charged monthly. ###### Price Unit Types Charged Upon Completion. Per: - `transaction` - `api_call` - `document` - `hour` - `image` - `page` - `person` - `person_hour` - `pm` - `pm_hour` - `datapoint` ###### Price Unit Types Charged On a Monthly Basis. Per: - `environment` - `product` - `seat` - `subscription` - `user` ##### Request application/json Copy ``` { "price_amount": 10, "price_amount_unit_type": "cent", "price_calculation_type": "average_supplier", "price_timing_type": "completion", "price_unit_type": "environment" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | | `api_id` required | `string (uuid)` path | `dc8a01fe-848-454-bfb-14131e81a518` | API ID | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `price_amount`required | `number` | Value representing price in predefined unit.Example `10` | | `price_amount_unit_type`required | `string` | Price unit. Must be `cent`.`cent`Example `cent` | | `price_calculation_type`required | `string` | The price is calculated using one of the permitted pricing strategies.`average_supplier``cost_of_goods_sold``equivalent_labor_cost``maturity`Example `average_supplier` | | `price_timing_type`required | `string` | Price is included into billing based on this defined schedule.`completion``monthly`Example `completion` | | `price_unit_type`required | `string` | The unit of the platform where the price evaluation can be determined as relevant.`api_call``datapoint``document``environment``hour``image``page``person``person_hour``pm``pm_hour``product``seat``subscription``transaction`Example `environment` | ##### Response `200``application/json` 2 fields Action were associated with the Product successfully. List of URIs follows. | Field | Type | Description | | --- | --- | --- | | `product_price_identifier`required | `object` | Newly assigned price ID.Example `da8bc1af-848-454-bfb-14131e81a518` | | `price_revision_identifier`required | `string` | Revision indicator.Example `revision:01G6N30DHYMPRKETP1ACEEXAMP` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/products/{product_id}/many_api` #### Create Many Product Api With Prices `create_many_api_with_prices` #### Create Many Product Api With Prices This endpoint allows you to register multiple API entries with prices for your product in one call. In a single request, you can define up to 15 API with price definition merged into it. Marketplace will automatically handle creation of the API and Price for you. If any of the following statements are true, you cannot use this endpoint: - Provided product has at least one API associated with it. - There are more than 15 items in a request payload. You must use the following endpoints Register an API then Create New Price Revision. ##### Request application/json Copy ``` [ { "api": { "product_api_name": "DistributeConfiguration", "product_api_type": "function", "product_api_description": "Distribute given configuration across all subscribed receivers." }, "price": { "price_amount": 10, "price_amount_unit_type": "cent", "price_calculation_type": "average_supplier", "price_unit_type": "transaction", "price_timing_type": "completion" } } ] ``` ##### Response 200400403404 application/json Copy Prices and API entries were successfully registered. List of URIs follows. ``` [ { "api": { "product_api_identifier": "da8bc1af-848-454-bfb-14131e81a518" }, "price": { "product_price_identifier": "da8ac1ab-848-454-bfb-14131e81a518", "price_revision_identifier": "revision:01G6N30DHYMPRKETP1ACEEXAMP" } } ] ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID. | ##### Response `200``application/json` 2 fields Prices and API entries were successfully registered. List of URIs follows. | Field | Type | Description | | --- | --- | --- | | `api`required | `object` | API with the identifier. | | `product_api_identifier`required | `string` | Unique identifier for this API.Example `da8bc1af-848-454-bfb-14131e81a518` | | `price`required | `object` | Price definition. | | `product_price_identifier`required | `object` | Newly assigned price ID.Example `da8bc1af-848-454-bfb-14131e81a518` | | `price_revision_identifier`required | `string` | Revision indicator.Example `revision:01G6N30DHYMPRKETP1ACEEXAMP` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `GET` `/ontology/products/{product_id}/components` #### Get Product Components `list_all_product_components` #### Get Product Components Retrieves all linked Components for a given Product. #### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy Successfully retrieved Components ``` { "product_id": "d126f045-4f0d-4129-b1fb-c0e511d878e5", "product_name": "Test", "page": { "next_token": null, "count": 2 }, "components": [ "Build", "Deploy" ] } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `3` | Limit the count of items returned. | ##### Response `200``application/json` 4 fields Successfully retrieved Components | Field | Type | Description | | --- | --- | --- | | `product_id` | `string (uuid)` | Canonical schema for the IDs used in the Ontology.Example `da8bc1af-848-454-bfb-14131e81a518` | | `product_name` | `object` | Name of the Product.Example `Build` | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `components` | `array` | — | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `POST` `/ontology/products/{product_id}/components` #### Link Components to Product `link_components_to_product` #### Link Components to Product Links given Components to the given product. Product is referenced by its ID. Component Link can be referenced by Product ID and Component Name pair. Product ID should be the one to which the Component was linked. #### Component Name Component Name should be registered in Marketplace, otherwise the request will not be fulfilled. #### Components Number Limit This endpoint accepts at most 15 components ##### Request application/json Copy ``` { "component_names": [ "Build" ] } ``` ##### Response 201400403404 application/json Copy Components were linked to the Product successfully. ``` { "components": [ "Build" ] } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `component_names`required | `array` | Array of Component Names to be linked to the product | ##### Response `201``application/json` 1 fields Components were linked to the Product successfully. | Field | Type | Description | | --- | --- | --- | | `components` | `array` | Array of linked component names | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/products/{product_id}/components/{component_name}` #### Unlink Component from Product `unlink_components_from_product` #### Unlink Component from Product Unlinks given Component from the given product. Product is referenced by its ID. Component should be previously linked to Product ID. Once unlinked, Component is no more shown in the component list of the product. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8b01ba-848-454-bfb-14131e81a518` | Product ID | | `component_name` required | `string` path | `Build` | Component Name | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` ### Component `GET` `/{component_registry}` #### List Components `listComponents__componentsRepository` Retrieves a list of components from a particular registry. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. Show the rest #### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200 Service Components List200 Data Configurations List400 application/json400 text/html403 application/json Copy Collection with list of permitted components. ``` { "products": [ { "name": "Build", "description": "DevOps service for building artifacts." }, { "name": "Deploy", "description": "DevOps service for service deployment." } ], "page": { "next_token": null, "count": 2 } } ``` application/json Copy Collection with list of permitted components. ``` { "products": [ { "name": "Assess-data", "description": "Data configuration for assessment product" }, { "name": "AUS-data", "description": "Data configuration for AUS product" } ], "page": { "next_token": null, "count": 2 } } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `cGs9RU5WSVJPTk1FTlQmc2s9RE9NQUlOJTIzYjAyMTVmNmY=` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `15` | Limits the count of items returned | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 1 fields Collection with list of permitted components. | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | `POST` `/{component_registry}` #### Register Components `registerManyComponents__componentsRepository` Registers many components into the component registry of Marketplace. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. ##### Request Service ComponentsData Components application/json Copy ``` { "products": [ { "name": "Build", "description": "DevOps service for building artifacts." }, { "name": "Deploy", "description": "DevOps service for service deployment." } ] } ``` application/json Copy ``` { "data": [ { "name": "Assess-data", "description": "Data configuration for assessment product" }, { "name": "AUS-data", "description": "Data configuration for AUS product" } ] } ``` ##### Response 201 Registered Service Components201 Registered Data Components400 application/json400 text/html403409 application/json Copy Components registry has been updated. ``` { "products": [ { "name": "Build", "description": "DevOps service for building artifacts." }, { "name": "Deploy", "description": "DevOps service for service deployment." } ] } ``` application/json Copy Components registry has been updated. ``` { "data": [ { "name": "Assess-data", "description": "Data configuration for assessment product" }, { "name": "AUS-data", "description": "Data configuration for AUS product" } ] } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource already exists ``` { "message": "Registry already contains components." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `409``application/json` 1 fields Resource already exists | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error messageExample `Registry already contains components.` | ##### Other responses `201` `PATCH` `/{component_registry}` #### Register Component `registerComponent__componentsRepository` Registers a component into the component registry of Marketplace. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. ##### Request Service ComponentData Component application/json Copy ``` { "products": [ { "name": "Build", "description": "DevOps service for building artifacts." }, { "name": "Deploy", "description": "DevOps service for service deployment." } ] } ``` application/json Copy ``` { "data": [ { "name": "Assess-data", "description": "Data configuration for assessment product" }, { "name": "AUS-data", "description": "Data configuration for AUS product" } ] } ``` ##### Response 201 Registered Service Components201 Registered Data Components400 application/json400 text/html403409 application/json Copy Components registry has been updated. ``` { "products": [ { "name": "Build", "description": "DevOps service for building artifacts." }, { "name": "Deploy", "description": "DevOps service for service deployment." } ] } ``` application/json Copy Components registry has been updated. ``` { "data": [ { "name": "Assess-data", "description": "Data configuration for assessment product" }, { "name": "AUS-data", "description": "Data configuration for AUS product" } ] } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource already exists ``` { "message": "Product ontology already exists" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `201``409` `GET` `/{component_registry}/{name}` #### Retrieve Component `retrieveComponent__componentsRepository` Retrieves component details such as description, dependencies, created and updated dates. The response contains the URL to the latest bundle which can be used for deployment. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. ##### Response 200400 application/json400 text/html403404 application/json Copy Component has been retrieved. ``` { "name": "Marketplace", "bundle_url": "https://builder-api-dev-codebuilddevbucket-r016i20zh5wi.s3.amazonaws.com/marketplace-main/build/ef5844e1-885d-423b-9ead-97bac72a181c/build.zip?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1610711553", "description": "Description", "dependencies": [ "Build", "Deploy" ], "update_at": "2021-01-20T12:54:53.961736+00:00", "bundle_status": "Valid", "created_at": "2021-01-05T10:52:31.689233+00:00" } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Name of product | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 8 fields Component has been retrieved. | Field | Type | Description | | --- | --- | --- | | `name` | `string` | ASCII StringExample `Marketplace` | | `description` | `string` | Component description.Example `DevOps service for building artifacts.` | | `bundle_url` | `string (uri)` | Temporary URL to access resource. Needs to return 200 status on get request, to be saved.Example `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | | `dependencies` | `string[]` | The list of component's dependencies. | | `bundle_status` | `string` | Bundle status.Example `Valid` | | `bundle_meta` | `object` | Bundle meta information. | | `update_at` | `string` | Component updated date.Example `2021-01-09T21:36:47.785596+00:00` | | `created_at` | `string` | Component updated date.Example `2021-01-09T21:36:47.785596+00:00` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | `PUT` `/{component_registry}/{name}` #### Update Component `updateComponent__componentsRepository` #### Update Component Uploads new bundle for a component that has already been registered in Marketplace. ##### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. Show the rest #### Dependency Management Dependencies are the mechanism of informing the Marketplace if your component depends on another component in the marketplace. It's important to understand that Marketplace Dependency Manager is not a common one. We're not talking about dependency managers, which operate on a library, package, or system level like `pip` or `cargo` do. Marketplace operates on components as dependencies of other components. ##### Types of dependencies | Type | Description | | --- | --- | | Deploy-time | Deploy-time dependency is the one, which your component requires during the deployment. Before delivering a component, Marketplace will attempt to deliver its `deploy-time` dependencies first. | | Runtime | Runtime dependency is the one, which your component requires during the runtime phase. The delivery of runtime dependencies and components can be optimized by delivering a component and its dependencies in parallel. | Service components can define `deploy-time` dependencies (defined under `deploy_time_dependencies` field). Defining dependencies (under `dependencies` field) for data configuration components implies that they're deploy-time, hence explicit `deploy-time` (under `deploy_time_dependencies` field) dependencies are prohibited. ###### Dependency resolution Whenever Marketplace receives a component update, Marketplace performs a shallow dependency resolution to determine the validity of your specification. During this process, Marketplace checks if there are any circular dependencies among deploy-time dependencies of your components, and if there are – you will get an error. Suppose that the component named “Assess” has the component named “Build” as a deploy-time dependency, and the “Build” attempted to introduce a new deploy-time dependency on the “Assess” component. This will cause an error when maintainers of “Build” try to update their component, introducing a new dependency. Error payload example: ``` { "error": { "message": "Invalid dependency specification. Cycle detected.", "reason": "Cycle: Assess -> Build -> Assess" } } ``` Marketplace still allows circular dependencies for service components, but dependency type cannot be `deploy-time`. ##### Dependency validation Marketplace will validate the presence and relevance of Assess signature for direct dependencies of your component. If the latest assessment rules have not passed for the component or its dependencies – Marketplace will cancel the publication. Component's dependencies are allowed to have either latest of second latest `version_hash`. Error payload example of dependency validation failure: ``` { "error": { "message": "Dependencies of Component(`Credit`) are outdated.", "reason": [ "Component(`Connector`) a dependency of Component(`Credit`) was not signed with the latest or the second latest Assessment version hash.", "Component(`Language`) a dependency of Component(`Credit`) was not signed with the latest or the second latest Assessment version hash." ], "_additional_documentation": [ "" ] } } ``` To summarize, Marketplace has the following restrictions on dependencies: - Runtime and deploy-time dependencies cannot have intersections. This means that you cannot define a component both as a runtime and deploy-time dependency. - Component cannot depend on itself. - Component cannot depend on component which does not have bundles. - Component cannot depend on component which does not exist. - Component which is a data configuration cannot have deploy-time dependencies. - Component and its dependencies cannot have conflicts (cycles). - Component cannot have dependencies with outdated signature of Assessor's `version_hash`. It must be equal to second latest or latest available to Marketplace. Use List Component Bundles endpoint to get the second latest and the latest bundle of Assessor. Example: ``` curl -X GET --location "https://.staircaseapi.com/marketplace/products/Assess/bundles?limit=2" \ -H "x-api-key: " ``` The version hash can be located by the following JSONPath: `$.bundles[*].bundle_meta.service-assessor.version_hash`. #### Product linking If the instance of Marketplace has products defined in its ontology, components must be linked to those products. Use Get Product Components endpoint to get components of a product, specified by product's unique ID in `product_id` path parameter. Example: ``` curl -X GET --location "https://.staircaseapi.com/marketplace/ontology/products/{product_id}/components" \ -H "x-api-key: " ``` Use Link Components to Product endpoint to link components to a product, specified by product's unique ID in `product_id` path parameter. Example: ``` curl -X POST --location https://.staircaseapi.com/marketplace/ontology/products//components -H 'x-api-key: ' --data '{"component_names":["{component_name"]}' ``` #### Review Process The new component configuration will be available in Marketplace only after a Review Process is completed. This process is started automatically. The Review Process status can be monitored using the `review_id` from the response. #### Delivery Once the review process is finished successfully, the next phase begins – update propagation. Update propagation consists of: - Recursive dependency resolution – every dependency of the component gets introduced to the subscriber. - Deployment order – determined after resolving dependencies, according to dependency specifications of resolved components. All the dependencies of the component are also components. ##### Request application/json Copy ``` { "bundle_url": "https://example.com/new_bundle.zip", "description": "New cool product.", "dependencies": [ "Build", "Deploy" ] } ``` ##### Response 400 application/json400 text/html403404409422 application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` application/json Copy Resource already exists ``` { "message": "Product ontology already exists" } ``` application/json Copy Unprocessable entity ``` { "message": "Bundle URL is not valid" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Component name | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `bundle_url`required | `string` | The URL of package artifact.Example `https://example.com/new_bundle.zip` | | `description` | `string` | Short description of product. | | `dependencies` | `string[]` | The list of component's dependencies. | | `deploy_time_dependencies` | `string[]` | The list of component's deploy-time dependencies. | ##### Response `202``application/json` 3 fields New bundle accepted. | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Component name.Example `Build` | | `review_id`required | `string` | Review process ID.Example `01FG21HJ227J4RJZCJDN08KRPZ` | | `bundle_status`required | `string` | Status of the review process.`UPLOADING_IN_PROGRESS`Example `UPLOADING_IN_PROGRESS` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Unprocessable entity error messageExample `Bundle URL is not valid` | ##### Other responses `409` `POST` `/{component_registry}/{name}/rollback` #### Rollback Component `rollbackComponent__componentsRepository` #### Rollback Component Reverts the component version to the previous one. This will initiate the update of the component with the previous bundle. ##### Response 400 application/json400 text/html403404409422 application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` application/json Copy Resource already exists ``` { "message": "Product ontology already exists" } ``` application/json Copy Unprocessable entity ``` { "message": "Bundle URL is not valid" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Component name | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 3 fields Revert process started. | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Component name.Example `Build` | | `review_id`required | `string` | Review process ID.Example `01FG21HJ227J4RJZCJDN08KRPZ` | | `bundle_status`required | `string` | Status of the review process.`UPLOADING_IN_PROGRESS`Example `UPLOADING_IN_PROGRESS` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Unprocessable entity error messageExample `Bundle URL is not valid` | ##### Other responses `409` `DELETE` `/{component_registry}/{name}` #### Delete Component `deleteComponent__componentsRepository` Delete a component from components registry. Note that, in order to delete a component, you must delete all the bundles associated to it. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. ##### Response 200400 application/json400 text/html403404 application/json Copy Success delete. ``` { "name": "Build" } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Component name | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 1 fields Success delete. | Field | Type | Description | | --- | --- | --- | | `name` | `string` | The name of productExample `Build` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | `GET` `/{component_registry}/{name}/bundles` #### List Component Bundles `listComponentBundles__componentsRepository` Retrieves a list of bundles associated with the product. Each bundle contains a unique ID, URL, metadata, description and dependencies. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. Show the rest #### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400 application/json400 text/html403404 application/json Copy 200 response ``` { "bundles": [ { "bundle_status": "Valid", "bundle_id": "01F2H820J56Y2FWEQCNFTYXC33", "dependencies": [], "bundle_url": "https://dev-marketplace-bundles-bucket-us-east-1-764911209783.s3.amazonaws.com/SERVICE/Health/01F2H820J56Y2FWEQCNFTYXC33?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1617654330", "description": "", "bundle_meta": { "service-assessor": { "id": "devops-code-assessor:0d5b6e9c-e7d8-48f8-970e-a82661a1c8b6", "issuer": "https://documentation.staircaseapi.com/code-assessor", "status": "SUCCEEDED", "timestamp": 1617633647.7666585, "version": "1.0.0" }, "service-builder": { "bundle_type": "SERVICE", "id": "b22de381-a28d-4b3f-bae4-62b7d53b50a8", "issuer": "https://documentation.staircaseapi.com/infra-builder", "status": "SUCCEEDED", "timestamp": 1617633835.1134853, "version": "1.1" }, "service-code": { "commit_hash": "c47eca3d7005b26be4c3ddd3bf164e35dc5e4afe", "id": "2d17ef8e-355c-4ffb-b933-532881a16e0b", "issuer": "https://documentation.staircaseapi.com/code", "status": "SUCCEEDED", "timestamp": 1617633512.3986268, "version": "1.1" } }, "uploaded_at": "2021-04-05T14:47:47.013899+00:00" } ], "page": [ { "count": 1, "next_token": null } ] } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Name of product | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `limit` | `integer` query | `3` | Limit the count of items returned. | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 2 fields 200 response | Field | Type | Description | | --- | --- | --- | | `bundles` | `object[]` | The list of bundles. | | `dependencies` | `string[]` | The list of component's dependencies. | | `bundle_status` | `string` | Bundle status.Example `Valid` | | `bundle_url` | `string` | Bundle URL.Example `https://example.com/new_bundle.zip` | | `bundle_id` | `string` | Bundle ID.Example `01FG21HJ227J4RJZCJDN08KRPZ` | | `description` | `string` | Bundle description.Example `My new bundle.` | | `bundle_meta` | `object` | Bundle meta information. | | `uploaded_at` | `string` | Component updated date.Example `2021-01-09T21:36:47.785596+00:00` | | `page` | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | `GET` `/{component_registry}/{name}/bundles/{bundle_id}` #### Retrieve Component Bundle `getComponentBundle__componentsRepository` Retrieves component's bundle information which contains a unique ID, URL, metadata, description and dependencies. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. ##### Response 400 application/json400 text/html403404 application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Component name | | `bundle_id` required | `string` path | `01FG21HJ227J4RJZCJDN08KRPZ` | Bundle ID | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 7 fields Success response. | Field | Type | Description | | --- | --- | --- | | `description` | `string` | Component description.Example `My product description.` | | `bundle_url` | `string (uri)` | Temporary URL to access resource. Needs to return 200 status on get request, to be saved.Example `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | | `dependencies` | `string[]` | The list of component's dependencies. | | `bundle_status` | `string` | Bundle status.Example `Valid` | | `bundle_meta` | `object` | Bundle meta. | | `bundle_id` | `string` | Bundle ID.Example `01FG21HJ227J4RJZCJDN08KRPZ` | | `uploaded_at` | `string` | Component updated date.Example `2021-01-09T21:36:47.785596+00:00` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | `DELETE` `/{component_registry}/{name}/bundles/{bundle_id}` #### Remove Component Bundle `removeComponentBundle__componentsRepository` Removes component bundle from Marketplace. #### Component registry There are two types of component registries in Marketplace: - `data` – for data configurations. Data configurations consist of static data annotations. They typically include Connection flows, Language mappings, and Language rules. Data configuration is then passed on into its target product like Connection, Language, Orchestration etc. Note that, after being deployed, data configurations cannot have runtime, thus do not have state. - `products` – for service configurations. Service configurations can have more advanced structure. They normally consist of templates with a diversity of resource definitions like AWS Lambda Functions, Amazon Sagemaker. Note that, after being deployed, a service's resources may have the state and thus services are considered to be stateful. So, `component_registry` path parameter can either be `products` or `data`. ##### Response 200400 application/json400 text/html403404 application/json Copy Success delete. ``` { "bundle_id": "01F494GQZQPSEGQ8EWRXYG8SBX" } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `name` required | `string` path | `Build` | Component name | | `bundle_id` required | `string` path | `01FG21HJ227J4RJZCJDN08KRPZ` | Bundle ID | | `component_registry` required | `string` path | `products` | Components registry. Can be 'products' or 'data'. | | `x-api-key` required | `string` header | `` | Environment API Key. | ##### Response `200``application/json` 1 fields Success delete. | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string` | The bundle IDExample `01F494GQZQPSEGQ8EWRXYG8SBX` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | `GET` `/reviews/{review_id}` #### Retrieve Review Status `getReviewStatus` Get information about the review of the bundle that has been uploaded. ##### Response 200400 application/json400 text/html403404 application/json Copy Success response. ``` { "status": "SUCCEEDED", "review_details": { "deploy_logs": "Component has been deployed successfully." } } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Component not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `review_id` required | `string` path | `01FG21HJ227J4RJZCJDN08KRPZ` | Review ID | ##### Response `200``application/json` 2 fields Success response. | Field | Type | Description | | --- | --- | --- | | `status`required | `string` | Review status.`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT`Example `SUCCEEDED` | | `review_details` | `object` | Review details. | | `deploy_logs` | `string` | Deploy logs from 'Review environment'. | | `marketplace_logs` | `object` | Marketplace logs. | | `comply_logs` | `object` | Compliance logs. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not found error messageExample `Component not found` | ### Configuration `POST` `/ontology/products/{product_id}/configurations` #### Create Product Configuration `create_configuration` This endpoint creates Product Configuration linked to different Companies referenced to via respective `company_id` values. #### Properties User is expected to set arbitrary description for the configuration to facilitate clarity. `configured_product_id` is a Product that is being configured in the Configuration. Product has to be registered in Marketplace ontology. Show the rest `configuration_product_api_id` allows to specify the API of the Product the configuration belongs to, enabling higher granularity of the configurations, distinguishing between sub-parts of the same Product. `company_ids` is a collection of `company_id` values that current configuration is assumed to be associated with. `company_id` references Staircase Company registered in Company product. #### External Marketplace Product Reference User can reference products registered on external Marketplace instances by providing the environment information in `configured_product_id` property, as described in the request body schema below. For example, assume you have a product registered on some "my-env.staircaseapi.com" environment. To reference it, you can pass the below to the `configured_product_id` property: ``` "configured_product_id": { "environment": { "host": "my-env.staircaseapi.com", "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "value": "" } ``` Note that, once supplied with environment information, `configured_product_api_id` is also verified on the given Marketplace instance. #### External Company Product Reference User can reference companies registered on external Company instances by providing the environment information in `company_ids` property, as described in the request body schema below. Follows the same pattern with `configured_product_id` example above. #### owned_by_company For Staircase marketplace, the `owned_by_company` property is required to be set to the ID of the company that owns the configuration. ID can be retrieved from the codex post. For external Marketplace instances, the `owned_by_company` property is required but not validated. ##### Request ExampleExternal MP ProductExternal CompanyConfiguration Product Api application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "configuration_description": "Credit configuration for Credit Verify Flow.", "configured_product_id": "da8bc1af-848-454-bfb-14131e81a518", "company_ids": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ] } ``` application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "configuration_description": "Credit configuration for Credit Verify Flow.", "configured_product_id": { "environment": { "host": "my-env.staircaseapi.com", "api_key": "xxxx" }, "value": "da8bc1af-848-454-bfb-14131e81a518" }, "company_ids": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ] } ``` application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "configuration_description": "Credit configuration for Credit Verify Flow.", "configured_product_id": { "environment": { "host": "my-env.staircaseapi.com", "api_key": "xxxx" }, "value": "da8bc1af-848-454-bfb-14131e81a518" }, "company_ids": { "environment": { "host": "my-env.staircaseapi.com", "api_key": "xxxx" }, "value": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ] } } ``` application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "configuration_description": "Credit configuration for Credit Verify Flow.", "configured_product_id": "da8bc1af-848-454-bfb-14131e81a518", "company_ids": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ], "configuration_product_api_id": "9cab06c2-6bd0-4333-93d6-81987e586a42" } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `owned_by_company`required | `string` | Company ID that owns the configuration. | | `configuration_description`required | `string` | Arbitrary description for the configuration. Limited by 300 symbols. | | `configuration_product_api_id` | `string` | API of the Product the configuration belongs to. | | `configured_product_id`required | `one of` | Allows referencing either local or external MP product | | `configured_product_api_id` | `string` | Product API that is being configured | | `company_ids`required | `one of` | Allows referencing either local or external Company product | ##### Response `201``application/json` 1 fields Product Configuration has been successfully created. | Field | Type | Description | | --- | --- | --- | | `configuration_id` | `string` | Configuration ID that references created Configuration. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `GET` `/ontology/products/{product_id}/configurations` #### Retrieve Product Configurations `retrieve_configurations` Allows to retrieve all Product Configurations created in the environment. `configured_product_id` query value can be specified to filter and retrieve only configurations where specific Product is being configured. #### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 200400403404 application/json Copy Product Configurations have been retrieved successfully. ``` { "configurations": [ { "configuration_description": "first_configuration", "configured_product_id": "da8bc1af-848-454-bfb-14131e81a518", "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "company_ids": [ "01GJXYCAJ6YSJM8MFM3SPKE5HZ", "01GJXYCAJ6YSJM8MFM3SPGP5HS" ], "configuration_id": "3d25a250-795b-44db-9cfb-09260fbc9170", "configured_product_api_id": "7a4fbde5-7452-4099-8af7-ea9e648c89a7" }, { "configuration_description": "second_configuration", "configured_product_id": "da8bc1af-848-454-bfb-14131e81a518", "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "company_ids": [ "01GJXYCAJ6YSJM8MFM3SPKEPOS" ], "configuration_id": "02beaf9c-0e1e-408a-8f71-6bb58f0b29d4", "configured_product_api_id": "7a4fbde5-7452-4099-8af7-ea9e648c89a7" } ], "page": { "count": 2, "next_token": null } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | | `limit` | `integer` query | `10` | Configurations limit | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | | `configured_product_id` | `string` query | `da8bc1af-848-454-bfb-14131e81a518` | Product that was configured by Configuration | ##### Response `200``application/json` 2 fields Product Configurations have been retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `configurations` | `array` | Collection of retrieved Configurations | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/products/{product_id}/configurations/{configuration_id}` #### Delete Product Configuration `delete_configuration` This endpoint deletes Product Configuration referenced by its `configuration_id`. ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | | `configuration_id` required | `string` path | `da8bc1af-848-454-bfb-14131e81a518` | Configuration ID | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` `GET` `/ontology/products/{product_id}/configurations/{configuration_id}` #### Retrieve Product Configuration `retrieve_configuration` This endpoint retrieves Product Configuration referenced by its `configuration_id`. ##### Response 200400403404 application/json Copy Product Configuration has been successfully retrieved. ``` { "configuration_description": "first_configuration", "configured_product_id": "da8bc1af-848-454-bfb-14131e81a518", "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "company_ids": [ "01GJXYCAJ6YSJM8MFM3SPKE5HZ", "01GJXYCAJ6YSJM8MFM3SPGP5HS" ], "configuration_id": "3d25a250-795b-44db-9cfb-09260fbc9170", "configured_product_api_id": "7a4fbde5-7452-4099-8af7-ea9e648c89a7" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | | `configuration_id` required | `string` path | `da8bc1af-848-454-bfb-14131e81a518` | Configuration ID | ##### Response `200``application/json` 1 fields Product Configuration has been successfully retrieved. | Field | Type | Description | | --- | --- | --- | | `configuration` | `object` | Contains Configuration information | | `owned_by_company` | `string` | Company ID that owns the ConfigurationExample `01J063B3X8GEPPGKJV72Q62N26` | | `configuration_description`required | `string` | Arbitrary configuration description | | `configuration_product_api_id` | `string` | API of the Product the configuration belongs to. | | `configured_product_id`required | `string` | Product configured by Configuration | | `configured_product_api_id` | `string` | Product API configured by Configuration | | `company_ids`required | `string[]` | Collection of `company_id` values | | `configuration_id`required | `string` | Configuration ID used to reference this Configuration | | `configured_product_host` | `string` | Host environment where the configured Product is registered. | | `company_host` | `string` | Host environment referenced by the Companies attached to Configuration. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `PATCH` `/ontology/products/{product_id}/configurations/{configuration_id}` #### Extend Product Configuration `extend_configuration` This endpoint enables users to add Company(s) to the given Configuration or to update other properties of it. Configuration is referenced by `configuration_id` in the path. Company(s) to be added must be registered in local Staircase Company product. See the request schema for referencing Companies from the external Staircase Company product. #### Warning If `company_ids` are to be updated and the given environment does not match already attached companies' environment, the request is rejected. #### owned_by_company For Staircase marketplace, the `owned_by_company` property is required to be set to the ID of the company that owns the configuration. ID can be retrieved from the codex post. For external Marketplace instances, the `owned_by_company` property is required but not validated. ##### Request ExampleExternal CompanyExternal MP Product application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "company_ids": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ] } ``` application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "company_ids": { "environment": { "host": "my-env.staircaseapi.com", "api_key": "xxxx" }, "value": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ] } } ``` application/json Copy ``` { "owned_by_company": "01J063B3X8GEPPGKJV72Q62N26", "configured_product_id": { "environment": { "host": "my-env.staircaseapi.com", "api_key": "xxxx" }, "value": "da8bc1af-848-454-bfb-14131e81a518" } } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | | `configuration_id` required | `string` path | `da8bc1af-848-454-bfb-14131e81a518` | Configuration ID | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `owned_by_company` | `string` | Company ID that owns the configuration.Example `01J063B3X8GEPPGKJV72Q62N26` | | `configured_product_id` | `one of` | Allows referencing either local or external MP product | | `configured_product_api_id` | `string` | Configured Product API ID. Should be given in pair with `configured_product_id`. | | `company_ids` | `one of` | Allows referencing either local or external Company product | | `description` | `string` | Arbitrary configuration description to replace prior one. | | `configuration_product_api_id` | `string` | API of the Product the configuration belongs to. | ##### Response `200``application/json` 1 fields Product Configuration has been successfully extended. | Field | Type | Description | | --- | --- | --- | | `configuration` | `object` | Contains Configuration information | | `owned_by_company` | `string` | Company ID that owns the ConfigurationExample `01J063B3X8GEPPGKJV72Q62N26` | | `configuration_description`required | `string` | Arbitrary configuration description | | `configuration_product_api_id` | `string` | API of the Product the configuration belongs to. | | `configured_product_id`required | `string` | Product configured by Configuration | | `configured_product_api_id` | `string` | Product API configured by Configuration | | `company_ids`required | `string[]` | Collection of `company_id` values | | `configuration_id`required | `string` | Configuration ID used to reference this Configuration | | `configured_product_host` | `string` | Host environment where the configured Product is registered. | | `company_host` | `string` | Host environment referenced by the Companies attached to Configuration. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `GET` `/ontology/configurations` #### List Configurations by Company `list_configurations_by_company` This endpoint retrieves Configurations registered under all Ontology Products filtering by `company_id`. Allows understanding and tracing how and where is Staircase integrating with Partners registered in Company product. #### Pagination by token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `limit` | `integer` query | `10` | Configurations limit | | `company_id` | `string` query | `01GJYN5EY5YACHCH071C9KBTR9` | Company ID registered in Company Product | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Token used for paginating the request. Refer to the description of this endpoint to read more. | ##### Response `200``application/json` 2 fields Configurations have been retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `configurations` | `object[]` | Collection of retrieved Configurations | | `product_id` | `string (uuid)` | Product ID | | `configuration_id` | `string` | Configuration ID used to reference this Configuration | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `400``404` `DELETE` `/ontology/products/{product_id}/configurations/{configuration_id}/companies` #### Delete Company(s) from Configuration[new] `delete_company_from_configuration` Delete Product Configuration This endpoint deletes given `company_ids` from the Product Configuration referenced by `configuration_id`. At least 1 Company should be attached to Configuration, so requests to delete all companies are rejected. ##### Request application/json Copy ``` { "company_ids": [ "b31aa2d4-bebf-4b4c-b7a2-a42237a1f489" ] } ``` ##### Response 400403404 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string (uuid)` path | `da8bc1af-848-454-bfb-14131e81a518` | Product ID | | `configuration_id` required | `string` path | `da8bc1af-848-454-bfb-14131e81a518` | Configuration ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `company_ids`required | `string[]` | Collection of `company_id` values | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404` ### Marketplace Instance `PUT` `/settings` #### Update Settings `updateConfiguration` Custom Settings Configures settings for the instance of Marketplace. | Configuration attribute | Attribute type | Description | Default | | --- | --- | --- | --- | | `review_api_key` | API key | Review API key is used for the review process done as a part of publication acceptance. Review process details are not disclosed. If not present publication functionality is not available. | Nothing | | `self_cleaning_review_api_key` | API key | Second Review API key is used for the review process done as a part of publication acceptance. Optional. The Marketplace will own this environment and perform environment cleaning daily. Cleaning will delete all the data and components deployed on this environment. This environment should not be used for anything except the review process. | Nothing | | `site_api_key` | API key | Site API key is used for the bundle distribution into Site product located in different location, where bundle's documentation is presented. If not present distribution is cancelled. | Nothing | | `env_administrator_domain_name` | Domain name | Environment administrator is used to operate deliveries into subscriber environments. | Local environment | | `env_administrator_api_key` | API key | Environment administrator is used to operate deliveries into subscriber environments. | Local environment | | `comply_auth_domain_name` | Domain name | Used for authentication user through `Comply Authentication`. | Nothing | | `code_assessment_regulator` | Regulator | Used for code assessment regulator. | Nothing | In order to get your own Marketplace instance running, you will have to provide the following required settings: Show the rest - `review_api_key` – this will affect publications and review process. - `env_administrator_domain_name` - this will affect delivery and settings validation. - `env_administrator_api_key` - this will affect delivery and settings validation. It is important to note that Environment administrator is a regulatory authority, which can only be located in one environment. You can check the status of your settings at Check Status. #### Regulators Regulators are products that are used for variety of purposes, including code assessment, compliance, and security. The main use-case for regulators is regulator's version hash validation. Currently, Marketplace is able to integrate with the following regulators: ##### Assess Assess product is a code assessment tool that is used to assess the quality, best-practise conformance, and security of the code that is being published to Marketplace. Marketplace will store the history of changes to `version_hash` produced in Assess products' signature. Whenever a component of a product gets published, Marketplace will check the `version_hash` of the component, and compare it to the latest valid `version_hash` stored in Marketplace. Note: Component's dependencies will also be validated. Dependencies must have the latest and previously latest version hash. ###### Updating `version_hash` Whenever a component linked to Assess product gets published, Marketplace will look for changes in the `version_hash`. If the `version_hash` has changed, Marketplace will store it as the latest valid `version_hash`. If the Assess regulator is not defined, Marketplace will not check the `version_hash` of the publishing component. ##### Registering Regulator - Register a new product in ontology, if not registered already ##### Secondary review. In order to have a secondary review, you need to provide `self_cleaning_review_api_key`. This key will be used for the review process done as a part of publication acceptance. The Marketplace will own this environment and perform environment cleaning daily. Cleaning will delete all the data and components deployed on this environment. This environment should not be used for anything except the review process. Purpose of this environment is to have a clean environment for the review process to validate that the component can be deployed into the fresh environment. ##### Request application/json Copy ``` { "review_api_key": "03660bf2-535a-4639-8df2-24322c1d7233", "env_administrator_api_key": "38ad8edc-1e77-4d73-aff7-c38adb05d78e", "env_administrator_domain_name": "template.staircaseapi.com", "site_api_key": "16a75805-acd5-4dca-9ed9-f267a05b330b" } ``` ##### Response 200400 application/json400 text/html403422 application/json Copy Configuration successfully updated. ``` { "message": "configuration successfully updated" } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `review_api_key` | `string` | API key for Review environment.Example `03660bf2-535a-4639-8df2-24322c1d7233` | | `self_cleaning_review_api_key` | `string` | API key for secondary review environment. Optional.Example `cf9e3809-0ca5-4f16-90f4-92fe612211e9` | | `env_administrator_api_key` | `string` | API key for Environment Administrator environment.Example `38ad8edc-1e77-4d73-aff7-c38adb05d78e` | | `env_administrator_domain_name` | `string` | Domain name of Environment Administrator environment.Example `template.staircaseapi.com` | | `site_api_key` | `string` | API key for Site environment.Example `16a75805-acd5-4dca-9ed9-f267a05b330b` | | `comply_auth_domain_name` | `string` | Environment domain name, where the "Comply" product runs.Example `no-tr.auth-gateway.staircaseapi.com` | | `code_assessment_regulator` | `object` | Code assessment regulator. | | `regulator_product_identifier`required | `string` | Product identifier of regulator.Example `dbcf20b7-0ea6-4bc5-898c-65f51e2d4686` | ##### Response `200``application/json` 1 fields Configuration successfully updated. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration updating status.Example `Configuration successfully updated` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `422` `GET` `/settings/status` #### Check Status `checkInstanceStatus` Retrieves the status of the Marketplace installed on your environment. Endpoint validates settings and returns the statuses. | Settings status | Marketplace operation | When non-operational | | --- | --- | --- | | `site_publication` | Site publication | Bundles are not published into Site, and hence documentation is not updated | | `component_publication` | Bundle distribution | Marketplace cannot review new component bundles | | `secondary_review_environment_status` | Bundle distribution | Marketplace cleans secondary review environment daily. During the cleaning, publications are not possible. | | `code_assessment_regulator` | Code assessment regulator | Marketplace cannot validate component's `version_hash` | #### FAQ ##### What do I have to do if my `site_publication` is non-operational? Site publications are not a required part of Marketplace publication channel, so it won't affect bundle publication. However, if you're expecting to see documentation updates, we recommend you to configure `site_api_key` via Update Settings Show the rest ##### What do I have to do if my `component_publication` is non-operational? Component publication is at the core of continuous delivery in Marketplace. If non-operational, it does not review component updates, which will block continuous delivery of the component. Note that Marketplace might still be able to deliver previously uploaded component bundles. ##### Response 200400 application/json400 text/html403422 application/json Copy Status information container. ``` { "status": { "site_publication": { "is_operational": true }, "component_publication": { "is_operational": true } } } ``` application/json Copy Request data failed validation ``` { "message": "Missing data for required field" } ``` text/html Copy Request data failed validation ```

400 Bad Request

``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Response `200``application/json` 1 fields Status information container. | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Collection of resources and their statuses. | | `site_publication`required | `object` | Status container. | | `is_operational`required | `boolean` | Flag determines if the resource is operational.Example `true` | | `component_publication`required | `object` | Status container. | | `is_operational`required | `boolean` | Flag determines if the resource is operational.Example `true` | | `code_assessment_regulator` | `object` | Status container. | | `is_operational`required | `boolean` | Flag determines if the resource is operational.Example `true` | | `secondary_review_environment_status` | `string` | Secondary review environment status.`Operational``NotSet``CleaningInProgress``EnvironmentBroken`Example `Operational` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Bad request error messageExample `Missing data for required field` | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `422` `GET` `/settings/schema` #### Retrieve Settings Schema[new] `retrieveSettingsSchema` Retrieve Settings Schema Retrieves the relevant Marketplace Settings schema. Example response schema: ``` { "$schema": "", "definitions": { "ConfigureMarketplaceSchema": { "type": "object", "properties": { "comply_auth_domain_name": { "title": "comply_auth_domain_name", "type": "string", "description": "Environment domain name, where the \"Comply\" product runs.", "pattern": "(^[a-zA-Z0-9]+([a-zA-Z0-9-]+\\.[a-zA-Z0-9-]+){1,61})*[a-zA-Z0-9]+\\.[a-zA-Z]{2,}$" }, "env_administrator_api_key": { "title": "env_administrator_api_key", "type": "string", "description"Show the rest;: "API key for Environment Administrator environment.", "minLength": 1 }, "env_administrator_domain_name": { "title": "env_administrator_domain_name", "type": "string", "description": "Domain name of Environment Administrator environment.", "pattern": "(^[a-zA-Z0-9]+([a-zA-Z0-9-]+\\.[a-zA-Z0-9-]+){1,61})*[a-zA-Z0-9]+\\.[a-zA-Z]{2,}$" }, "quicksight_api_key": { "title": "quicksight_api_key", "type": "string", "minLength": 1 }, "review_api_key": { "title": "review_api_key", "type": "string", "description": "API key for Review environment.", "minLength": 1 }, "site_api_key": { "title": "site_api_key", "type": "string", "description": "API key for Site environment.", "minLength": 1 } }, "additionalProperties": false } }, "$ref": "#/definitions/ConfigureMarketplaceSchema" } ``` ##### Response application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `200` ## Errors `400``403``404``409``422` ## More in Distribution - Previous product: Host - Next product: Setup --- # Setup # Setup Self-service account and environment creation, between a user interface and the platform's own APIs. Creating an account and its first environment touches several products in a fixed order — identity, environment provisioning, catalogue installation and key issuance. This product carries that sequence so a front end can present it as one step. Per-vendor credential onboarding follows the same shape: each vendor integration exposes an endpoint to store a lender's credentials and another to describe the schema those credentials must satisfy, so the form can be rendered from the schema rather than hand-built per vendor. ## Operations ### Setup `POST` `/setupAccount` #### Setup Account `setup-account` Setup new account. Create new account and send an email ##### Request application/json Copy An example of a payload. ``` { "first_name": "John", "last_name": "Doe", "email": "john.doe@company.com", "company_name": "company", "company_industry": "Mortgage Broker", "company_size": "1-50", "address": "STREET", "zip_code": "00000", "state": "CA", "password": "XXXXX" } ``` ##### Response 200400401403500502 application/json Copy OK. ``` { "transaction_id": "aaaa-bbb-xccccc" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | ##### Request body`application/json` 10 fields | Field | Type | Description | | --- | --- | --- | | `first_name`required | `string` | First nameExample `John` | | `last_name`required | `string` | Last nameExample `Doe` | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `company_name`required | `string` | Company nameExample `company` | | `company_industry`required | `string` | Category of companyExample `Mortgage Broker` | | `company_size`required | `string` | Number employees in the companyExample `1-50` | | `address`required | `string` | AddressExample `STREET` | | `zip_code`required | `string` | Zip CodeExample `00000` | | `state`required | `string` | StateExample `CA` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/refresh_token` #### Refresh Token `Refresh-token` Returns new token when access_token expires ##### Request application/json Copy An example of a payload. ``` { "refresh_token": "" } ``` ##### Response 200400401403500502 application/json Copy OK. ``` { "id_token": "xxxxxx", "refresh_token": "", "token_type": "yyyyyy" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `refresh_token`required | `string` | Token to refreshExample `` | ##### Response `200``application/json` 3 fields OK. | Field | Type | Description | | --- | --- | --- | | `id_token` | `string` | The ID token. | | `refresh_token` | `string` | The refresh token. | | `token_type` | `string` | The token type. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/sign_in` #### Sign In `sign-in` Sign in. Sign in the credentials ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response 200400401403500502 application/json Copy OK. ``` { "id_token": "xxxxxx", "refresh_token": "", "token_type": "yyyyyy" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 3 fields OK. | Field | Type | Description | | --- | --- | --- | | `id_token` | `string` | The ID token. | | `refresh_token` | `string` | The refresh token. | | `token_type` | `string` | The token type. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/check_email_availability/{email}` #### Check Email Availability `check-Email-Availability` Checks email registered incognito pool ##### Response 200400401403500502 application/json Copy OK. ``` { "status": "AVAILABLE" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `email` required | `string` path | `john.doe@company.com` | Email of account | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of account | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/retrieve_all_products` #### Get all products `get-all-products` Get all products from marketplace ##### Response 200400401403500502 application/json Copy OK. ``` { "products": [ { "name": "Account Management", "description": "", "status": "NOT_DEPLOY" } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `products` | `object[]` | List of products | | `name` | `string` | Product name | | `description` | `string` | Description of product | | `status` | `string` | Status of deploy of product (NOT_DEPLOY, IN_QUEUE; FAILED, SUCCESS) | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/admin_retrieve_transaction_status` #### Get environment creation status `admin_retrieve_transaction_status` ##### Response 200400401403500502 application/json Copy OK. ``` { "status": "DEPLOYING_INFRASTRUCTURE_PRODUCTS" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of environment | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/submit_customer_api_key` #### Send email `submit-customer-api-key` Submit API key received by email ##### Request application/json Copy An example of a payload. ``` { "api_key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Response 200400401403500502 application/json Copy OK. ``` { "body": "Task success sent" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `api_key`required | `string` | API key of environmentExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `body` | `string` | Response of endpoint | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/submit_product_deploy_options` #### Save product selected `submit-product-deploy-options` Save product selected of environment created in the front-end side ##### Request application/json Copy An example of a payload. ``` { "products_selected": [ "Code", "Assess" ] } ``` ##### Response 200400401403500502 application/json Copy OK. ``` { "body": "Task success sent" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Content-Type` required | `string` header | `application/json` | The content type. | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `products_selected`required | `string[]` | Products selected | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `body` | `string` | Response of endpoint | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/user-info` #### Get information about authenticated user `user-info` ##### Response 200400401403500502 application/json Copy OK. ``` { "UserAttributes": { "sub": "xxxxass-xxx-xxxx-xxxx-xxxxxxxxx", "email_verified": "true", "company_name": "Staircase", "email_confirmed": "False", "api_key_submitted": "True", "last_name": "Doe", "setup_id": "xxxxass-xxx-xxxx-xxxx-xxxxxxxxx", "api_key": "", "first_name": "John", "account_id": "xxxxass-xxx-xxxx-xxxx-xxxxxxxxx", "email": "john.doe@staircase.co", "company_status": "SETUP_COMPLETED", "environment_fqdn": "setup-xxx-xxxxxx.staircaseapi.com" }, "LosAttributes": [ { "provider": "Encompass", "credentials": { "clientId": "xxxxx", "instanceId": "xxxxx", "username": "xxxxx" }, "isAdmin": true, "adminEmail": "", "adminPhone": "" } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Response `200``application/json` 2 fields OK. | Field | Type | Description | | --- | --- | --- | | `UserAttributes`required | `object` | Information of user | | `sub`required | `string` | ID of user incognito | | `email_verified`required | `string` | Email is verified incognito | | `company_name`required | `string` | Company name of user | | `email_confirmed`required | `string` | Email was confirmed incognito | | `api_key_submitted`required | `string` | If the API key was submitted | | `last_name`required | `string` | Last name | | `setup_id`required | `string` | ID the user in step functions | | `api_key`required | `string` | API key of environment related with the user | | `first_name`required | `string` | First name | | `account_id`required | `string` | ID of user in account product | | `email`required | `string` | Email of user | | `company_status`required | `string` | Status in the flow of setup | | `environment_fqdn`required | `string` | Domain of environment related with the user | | `LosAttributes` | `object[]` | List of LOS Providers | | `provider`required | `string` | Provider name | | `isAdmin`required | `boolean` | Status if the user is admin | | `adminEmail` | `string` | The admin email if the user is not Admin | | `adminPhone` | `string` | The admin phone if the user is not Admin | | `credentials`required | `object` | Credentials of LOS Configuration | | `clientId` | `string` | Client ID of LOS Credentials | | `instanceId` | `string` | Instance ID of LOS Credentials | | `username` | `string` | Username of LOS Credentials | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/submit_los_configuration/{provider_name}` #### Create new LOS configuration `submit_LOS_configuration` ##### Request application/json Copy An example of a payload. ``` { "credentials": { "clientId": "xxxxx", "instanceId": "xxxxx", "username": "xxxxx" }, "isAdmin": true, "adminEmail": "", "adminPhone": "" } ``` ##### Response 201400401403500502 application/json Copy OK. ``` { "message": "The credential was stored successfully" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `provider_name` required | `string` path | `Encompass` | Provider name (NoProvider, Encompass) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `isAdmin`required | `boolean` | Status if the user is admin | | `adminEmail` | `string` | The admin email if the user is not Admin | | `adminPhone` | `string` | The admin phone if the user is not Admin | | `credentials`required | `object` | Credentials of LOS Configuration | | `clientId` | `string` | Client ID of LOS Credentials | | `instanceId` | `string` | Instance ID of LOS Credentials | | `username` | `string` | Username of LOS Credentials | ##### Response `201``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Created description. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/sms-templates/{product}` #### Create new SMS template by product `create-sms-templates` ##### Request application/json Copy An example of a payload. ``` { "text_body": "xxxxxxxx xxxx xxxxxx" } ``` ##### Response 201400401403500502 application/json Copy Created. ``` { "text_body": "xxxxxxxx xxxx xxxxxx", "name": "sms_template" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `product` required | `string` path | `Employment` | Product name (Employment, Income) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `text_body`required | `string` | Content of template | ##### Response `201``application/json` 2 fields Created. | Field | Type | Description | | --- | --- | --- | | `text_body`required | `string` | Content of template | | `name`required | `string` | Template name | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/sms-templates/{product}` #### Retrieve SMS template by product `retrieve-sms-templates` ##### Response 200400401403500502 application/json Copy Created. ``` { "text_body": "xxxxxxxx xxxx xxxxxx", "name": "sms_template" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `product` required | `string` path | `Employment` | Product name (Employment, Income) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Response `200``application/json` 2 fields Created. | Field | Type | Description | | --- | --- | --- | | `text_body`required | `string` | Content of template | | `name`required | `string` | Template name | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/email-templates/{product}` #### Create new email template by product `create-email-templates` ##### Request application/json Copy An example of a payload. ``` { "html_part": " \n", "subject_part": "xxxx xxxxx", "logo_data": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABA4AAAQcCAYAAAAVwNnQAAA" } ``` ##### Response 201400401403500502 application/json Copy Created. ``` { "html_part": " \n", "subject_part": "xxxx xxxxx", "product_name": "Income" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `product` required | `string` path | `Employment` | Product name (Employment, Income) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `html_part`required | `string` | Content of template | | `subject_part`required | `string` | Subject of template | | `logo_data` | `string` | Logo of template in Base64 encode | ##### Response `201``application/json` 3 fields Created. | Field | Type | Description | | --- | --- | --- | | `html_part`required | `string` | Content of template | | `subject_part`required | `string` | Subject of template | | `product_name`required | `string` | Product Name | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/email-templates/{product}` #### Retrieve email template by product `retrieve-email-templates` ##### Response 200400401403500502 application/json Copy Created. ``` { "template": { "text_body": "xxxxxxxx xxxx xxxxxx", "name": "sms_template", "logo_image": "xxxxxxxxxxxxxxxxx" } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `product` required | `string` path | `Employment` | Product name (Employment, Income) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Response `200``application/json` 1 fields Created. | Field | Type | Description | | --- | --- | --- | | `template`required | `object` | Information about the template | | `text_body` | `string` | Content of template | | `name` | `string` | Template name | | `logo_image` | `string` | URL of logo | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/vendor/{vendor}/credentials` #### Create credentials by vendor `create-vendor-credentials` ##### Request application/json Copy An example of a payload. ``` { "username": "xxxxxxxx", "password": "", "title_provider_orderings": { "default_ordering": [ "fidelity", "first_american", "stewart" ] } } ``` ##### Response 200400401403422500502 application/json Copy Setup API Triggered Successfully ``` { "message": "Credentials are saved" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "Invalid request body", "error": "[object has missing required properties ([\"client_secret\"])]" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `vendor` required | `string` path | `ernst` | Vendor name (ernst) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `username` | `string` | Username of credential | | `password` | `string` | Password of credential | | `title_provider_orderings`required | `object` | An object to set default title fees' provider list for states, counties and cities | | `default_ordering` | `string[]` | Root default ordering for title fees' provider | | `states` | `object[]` | States | | `state_code` | `string` | State code | | `default_ordering` | `string[]` | Default title provider ordering for the state | | `counties` | `object[]` | Counties | | `county_name` | `string` | County name | | `default_ordering` | `string[]` | Default title provider ordering for the county | | `cities` | `object[]` | Cities | ##### Response `200``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | | `error` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/vendor/{vendor}/credentials` #### Retrieve credentials by vendor `retrieve-vendor-credentials` ##### Response 200400401403500502 application/json Copy An example of a payload. ``` { "username": "xxxxxxxx", "password": "", "title_provider_orderings": { "default_ordering": [ "fidelity", "first_american", "stewart" ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `vendor` required | `string` path | `ernst` | Vendor name (ernst) | | `Authorization` required | `string` header | `` | Setup authorization token | ##### Response `200``application/json` 3 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `username` | `string` | Username of credential | | `password` | `string` | Password of credential | | `title_provider_orderings`required | `object` | An object to set default title fees' provider list for states, counties and cities | | `default_ordering` | `string[]` | Root default ordering for title fees' provider | | `states` | `object[]` | States | | `state_code` | `string` | State code | | `default_ordering` | `string[]` | Default title provider ordering for the state | | `counties` | `object[]` | Counties | | `county_name` | `string` | County name | | `default_ordering` | `string[]` | Default title provider ordering for the county | | `cities` | `object[]` | Cities | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `POST` `/send-invitation` #### Send an invitation to new customers `send-invitation-customer` ##### Request application/json Copy An example of a payload. ``` { "company_id": "xxxxxxxx", "email": "joedoe@test.co", "first_name": "Joe", "last_name": "Doe" } ``` ##### Response 200400401403500502 application/json Copy Created. ``` { "message": "OK" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Unauthorized validation ``` { "message": "{'data': ['Unauthorized.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy While acting as a gateway or proxy, received an invalid response from the upstream server. ``` { "message": "The product has encountered an bad gateway error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `company_id`required | `string` | The company identifier | | `email`required | `string` | Customer email | | `first_name`required | `string` | Customer name | | `last_name` | `string` | Last Name of customer | ##### Response `200``application/json` 1 fields Created. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `401``application/json` 1 fields Unauthorized validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `502``application/json` 1 fields While acting as a gateway or proxy, received an invalid response from the upstream server. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ## Canonical model - `address` - `address` ## Property data it reads - address ## Errors `400``401``403``404``422``500``502` ## More in Distribution - Previous product: Marketplace --- # Shipping # Shipping The pipeline: repository operations, assessment, build, deployment, compliance and the orchestration that runs them in order. How does code get from a repository to a running service? Each stage is a product with its own API, and the sequence is a separate product that runs them. Keeping the stages independently callable is what lets one run alone — assessing a repository without deploying it is a normal operation rather than a special mode. ## Products In the order the value chain runs. 1. Assess has a recorded specification 1. Build has a recorded specification 1. Code has a recorded specification 1. Comply has a recorded specification 1. Deploy has a recorded specification 1. Health has a recorded specification 1. Pipeline has a recorded specification ## How the chain fits together The assessment stage carries one rule that shapes everything downstream: every endpoint declared in a deployment manifest had to appear in the API definition, checked on every build, blocking the build where it did not. A service's contract surface therefore lives at a canonical path in the repository rather than in a document beside it. --- # Assess # Assess A rules engine over infrastructure definitions, fetched at run time, with a version hash that blocks publication against a stale rule set. Assess runs before anything is built. The service definition is checked against a rule set covering the deployment manifest, the API definition, and the security, distribution, identity and logging conventions every service is required to follow. The rules are fetched at run time rather than vendored into each repository, so tightening a rule is one edit at the source and the next build everywhere picks it up. ## How it works One rule carries the most weight. Named `EndpointDocumentationNotExists`, it asserts that every endpoint declared in the deployment manifest also appears in the API definition — checked on every build, blocking the build where it did not hold. No endpoint could be released undocumented, so the API definitions stayed at their canonical paths and each service's contract surface is readable off its repository. Publication is gated on a version hash over the joined rule hashes. Three naming rules are excluded from the join, and their absence in any form makes every generated hash differ — the note on record says the hash is deliberately broken in that case, to stop a broken version publishing. When a component linked to Assess publishes, the catalogue reads the bundle's hash, compares it against the last one recorded, and updates the hash required for publication when it differs. A build against a stale rule set therefore fails at publication rather than shipping quietly. ## Operations ### Assess `POST` `/assessments` #### Create Assessment `new-assessment` Assess validates a bundle of source code (Identified by a source_url) according to the rules configured for Assess. Assess returns an assessment_id in the response body. To retrieve the results of the validation, call Retrieve Assessment Status with the assessment_id. ##### Request application/json Copy ``` { "source_url": "https://code-dev-0258.s3.amazonaws.com/code-assessor/1506dbf2/source.zip?AWSAccessKeyId=2323" } ``` ##### Response application/json Copy 200 response ``` { "assessment_id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `source_url`required | `string` | URL to project source code. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `assessment_id` | `string` | Assessment id, used for get assessment status | ##### Other responses `400``401``403``404` `GET` `/assessments/{assessment_id}` #### Retrieve Assessment Status `assessment-status` Retrieve Assessment Status retrieves the results of the validation performed by Assess for the given assessment_id. ##### Response 200 Succeeded response200 Failed response application/json Copy 200 response ``` { "assessment_id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "logs": "[Container]2021/01/29 19:44:20 Waiting for agent ping [Container]", "metadata": { "service-assessor": { "id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "issuer": "https://api.staircaseapi.com/code_assessor", "status": "SUCCEEDED", "timestamp": 1611949487.728646, "version": "1.0.0" }, "service-code": { "commit_hash": "5a8d1bbd276306e73ad5fcb1c45dfe3bb2e6c5c2", "id": "1506dbf2-ea7b-4b76-9f51-2ebb0ac49af1", "issuer": "https://api.staircaseapi.com/code", "status": "SUCCEEDED", "timestamp": 1611948276.2954555, "version": 1.1 } }, "source_url": "https://code-assessor-oybto4.s3.amazonaws.com/assessments/devops-code-assessor-a51a-56d91d7ed7df/build.zip?AWSAccessKeyId=2525&Signature=TyI1LC0", "status": "SUCCEEDED", "warnings": [ { "errors": [ { "message": "Run pipeline was expected", "path": "jobs.Pipeline.name" } ], "file": ".github/workflows/pipeline.yml", "message": "Your pipeline configuration is not compliant", "rule_code": "pipeline" } ] } ``` application/json Copy 200 response ``` { "errors": [ { "errors": [ { "message": "'ServiceApiKeyID' is a required property", "path": "resources.Resources.ApiUsagePlanCustom.Properties" }, { "message": "'UsagePlanName' is a required property", "path": "resources.Resources.ApiUsagePlanCustom.Properties" } ], "file": "./serverless.yml", "message": "Your UsagePlan is not compliant", "rule_code": "usagePlan" }, { "errors": [ { "message": "'LoggingBucket' is a required property", "path": "resources.Resources" } ], "file": "./serverless.yml", "message": "Your loggingBucket S3 is not compliant", "rule_code": "loggingBucket" } ], "assessment_id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "logs": "[Container]2021/01/29 19:44:20 Waiting for agent ping [Container]", "metadata": { "service-assessor": { "id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "issuer": "https://api.staircaseapi.com/code_assessor", "status": "SUCCEEDED", "timestamp": 1611949487.728646, "version": "1.0.0" }, "service-code": { "commit_hash": "5a8d1bbd276306e73ad5fcb1c45dfe3bb2e6c5c2", "id": "1506dbf2-ea7b-4b76-9f51-2ebb0ac49af1", "issuer": "https://api.staircaseapi.com/code", "status": "SUCCEEDED", "timestamp": 1611948276.2954555, "version": 1.1 }, "status": "FAILED" }, "warnings": [ { "errors": [ { "message": "Run pipeline was expected", "path": "jobs.Pipeline.name" } ], "file": ".github/workflows/pipeline.yml", "message": "Your pipeline configuration is not compliant", "rule_code": "pipeline" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `assessment_id` required | `string` path | `devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg` | id of assessment | ##### Response `200``application/json` 6 fields 200 response | Field | Type | Description | | --- | --- | --- | | `errors` | `object` | Contains errors on failed assessment | | `errors` | `object[]` | Errors array | | `message` | `string` | Error message | | `path` | `string` | Path of the property or location issue in your file | | `file` | `string` | Assessed file | | `message` | `string` | Error message | | `rule_code` | `string` | Rule code | | `source_url` | `string` | Presigned URL with the assessed bundle and including metadata in the header for Assess and other products. This metadata is in use as a signature of successful assessment. | | `status` | `string` | Status of assessment`FAILED``FAULT``IN_PROGRESS``NOT_FOUND``STOPPED``SUCCEEDED``TIMED_OUT` | | `metadata` | `object` | Assessment metadata plus metadata included in the assessment presigned URL coming from other products | | `logs` | `string` | Contains log on failed assessment | | `warnings` | `object` | Contains warnings on assessment | | `errors` | `object[]` | Errors array | | `message` | `string` | Error message | | `path` | `string` | Path of the property or location issue in your file | | `file` | `string` | Assessed file | | `message` | `string` | Error message | | `rule_code` | `string` | Rule code | ##### Other responses `400``401``403``404` `POST` `/assessments/overview` #### Create Overview Assessment `new-overview-assessment` Create Assessment Overview Assess Overview validates an input of overview in String format according to the rules configured for Assess. Assess returns an assessment_id in the response body. To retrieve the results of the validation, call Retrieve Assessment Status with the assessment_id. ##### Request application/json Copy ``` { "overview": "
Overview html template
", "dictionary": [ "source_url", "x-api-key" ] } ``` ##### Response application/json Copy 200 response ``` { "assessment_id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `overview` | `string` | Overview in string format | | `dictionary` | `string[]` | Words to omit in spell check | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `assessment_id` | `string` | Assessment id, used for get assessment status | ##### Other responses `400``401``403``404` `POST` `/assessments/swagger` #### Create Assessment Swagger `new-assessment-swagger` Assess Swagger validates an input of swagger in JSON format according to the rules configured for Assess. Assess returns an assessment_id in the response body. To retrieve the results of the validation, call Retrieve Assessment Status with the assessment_id. ##### Request application/json Copy ``` { "swagger": { "info": { "title": "Assess", "x-product-category": "Ship", "x-product-family": "DevOps", "x-product-name": "Assess" } }, "dictionary": [ "source_url", "x-api-key" ] } ``` ##### Response application/json Copy 200 response ``` { "assessment_id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `swagger` | `object` | Swagger in JSON format | | `dictionary` | `string[]` | Words to omit in spell check | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `assessment_id` | `string` | Assessment id, used for get assessment status | ##### Other responses `400``401``403``404` `GET` `/version-hash` #### Retrieve Version Hash `get-version-hash` Retrieve Version Hash retrieves the assessment version hash currently available in an environment. ##### Response application/json Copy 200 response ``` { "version_hash": "5a8d1bbd276306e73ad5fcb1c45dfe3bb2e6c5c2" } ``` ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `version_hash`required | `string` | Version hash of the latest commit of the Assess repository | ### Assessment Rules `GET` `/rules-category` #### Retrieve List of Assessment Rules `get-rules` Retrieve List of Assessment Rules retrieves a list of all assessments rules configured for Assess. ##### Response application/json Copy 200 response ``` [ { "code": "usagePlan", "description": "Usage Plan assessment rules" }, { "code": "swagger", "description": "Swagger assessment rules" } ] ``` ##### Response `200``application/json` 2 fields 200 response | Field | Type | Description | | --- | --- | --- | | `code`required | `string` | Code of the rule | | `description`required | `string` | Description of the rule | ##### Other responses `400``401``403``404` `GET` `/rule/{code}` #### Retrieve Assessment Rule `get-rule` Retrieve Assessment Rule retrieves an assessment rule for a given code. A list of code are returned by the service Retrieve List of Assessment Rules. ##### Response application/json Copy 200 response ``` { "type": "object", "description": "Usage Plan assessment rules", "required": [ "handler" ], "properties": { "handler": { "const": "handler" } } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `code` required | `string` path | `usagePlan` | Rule code from the service Retrieve the list of all assessment rules | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type of the schema | | `description` | `string` | Description of the schema | | `required` | `string[]` | Mandatory schema parameters | | `properties` | `object` | Schema characteristics | ##### Other responses `400``401``403``404` `POST` `/rule` #### Update Assessment Rule `post-rule` Update Assessment Rule updates an assessment rule configured for Assess. Assessment rules are configured in JSON format, as defined in List of available actions: - insert_product_names: Add new product names. - remove_product_names: Delete product names. - update_server_url_pattern: Set server URL pattern using regular expression. - insert_schema_rule: Add a new rule in the schema. - remove_schema_rule: Delete a rule by name. - remove_schema: Delete a schema. - replace_all_schemas: Replace all schema action allows changing or add multiple rules at the same time by just replacing the complete schema. Important considerations: Show the rest - This feature only allows updating swaggerProductName, serviceProductName, serverlessProductName and swaggerBase schema rules. - You can get the rule code by the service Retrieve List of Assessment Rules. - You can see the complete schema by the service Retrieve Assessment Rule. ##### Request Insert product namesRemove product namesUpdate server url patternInsert schema ruleRemove schema ruleReplace all schema application/json Copy ``` { "rule_name": [ "swaggerProductName", "serviceProductName", "serverlessProductName" ], "action": "_insert_product_names", "product_names": [ "Account", "Test" ] } ``` application/json Copy ``` { "rule_name": [ "swaggerProductName", "serviceProductName", "serverlessProductName" ], "action": "_remove_product_names", "product_names": [ "Account", "Test" ] } ``` application/json Copy ``` { "rule_name": [ "swagger" ], "action": "_update_server_url_pattern", "server_url_pattern": "^https://documentation.staircaseapi.com/?[-_a-zA-Z0-9/]+$" } ``` application/json Copy ``` { "rule_name": [ "swagger" ], "action": "_insert_schema_rule", "schema": { "api": { "type": "object", "required": [ "handler" ], "properties": { "handler": { "const": "handler" } } } } } ``` application/json Copy ``` { "rule_name": [ "swagger" ], "action": "_remove_schema_rule", "schema_rule_name": "api" } ``` application/json Copy ``` { "rule_name": [ "swagger" ], "action": "_replace_all_schema", "schema": { "type": "object", "required": [ "handler" ], "properties": { "handler": { "const": "handler" } } } } ``` ##### Response application/json Copy 200 response ``` { "status": "SUCCEEDED" } ``` ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `rule_name`required | `string[]` | Schema name | | `action`required | `string` | Action to execute on the rule | | `product_names` | `string[]` | Product names to insert or delete | | `server_url_pattern` | `string` | Regular expression to validate the server URL | | `schema_rule_name` | `string` | Schema rule name to insert or delete | | `schema` | `object` | Schema of the rule defined in this format | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | SUCCEEDED | ##### Other responses `400``401``403``404` ## Errors `400``401``403``404` ## More in Shipping - Next product: Build --- # Build # Build One build contract producing five bundle types, so a conversational agent, a front end, a vendor mapping and a service all move through the same pipeline. Three files describe a unit of work: what it is, what it exposes, and how it deploys. From those, the build produces one of five bundle types — a service, a data bundle, a front end, a front-end configuration, or a chat bundle. The bundle is the deployable unit everywhere downstream. Deploy takes it, Marketplace publishes it, and Environment installs it. ## How it works Making a vendor mapping and a React front end the same kind of artifact is what lets one pipeline cover every unit of work. A vendor configuration is not code in the usual sense, but it versions, tests and deploys like everything else, and a separate release path for it would have been a second pipeline to keep correct. ## Operations ### Product `POST` `/builds` #### Build Product `buildProduct` Build a deployable artifact for a product. The artifact must be provided via a URL. A callback will be sent to the URL specified in `callback_url` property. #### `Build Hash` The builder generates a unique hash value for each build. This value is available in build metadata which can be accessed using the product information endpoint. Also, this value passes by a Deployer if the AWS CloudFormation parameter definition exists in product `serverless.yml`. This parameter can be referenced as an environment variable as follows. Show the rest Product serverless.yml: ``` provider: environment: BUILD_HASH: Ref: BuildHash ... resources: Parameters: BuildHash: Type: String Description: This info will be generated by the Builder and passed by Deployer. It contains a product build hash. Default: "null" ``` #### `architecture` By default, X86_64 architecture is used to build dependencies. Switch to ARM64 using the 64-bit ARM architecture for the AWS Graviton2 processor. It is possible to use only one architecture per build. #### `node_version` You can configure Node version to use to package your dependencies. Please note, that `node_version` = 14 works only with `architecture` = X86_64 and `compute_instance_size` = SMALL. `node_version` 18 and 20 works only with `architecture` = ARM64 and `compute_instance_size` = SMALL. #### `compute_instance_size` You can configure how much memory and disk space your build can take up. `compute_instance_size` is dependent on `architecture`. The following table describes mapping of allowed architectures to compute instance sizes. | Architecture | Compute instance size | Memory | Disk space | vCPUs | | --- | --- | --- | --- | --- | | ARM64 | SMALL | 4 GB | 50 GB | 2 | | ARM64 | LARGE | 16 GB | 50 GB | 8 | | X86_64 | SMALL | 3 GB | 64 GB | 2 | ##### Request application/json Copy ``` { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } ``` ##### Response 201400 application/json Copy Build created ``` { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 8 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | Usually a hash of the commit but can be any UUID. | | `source_url`required | `string (uri)` | Presigned URL to source code. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for build status | | `serverless_version` | `string` | Serverless version, that is used in build process to update serverless framework version.`2.x``3.x`Example `3.x` | | `log_level` | `string` | Log level, that is used in build process. Can be used with \"DEBUG\" value for Build product debugging.`DEBUG``INFO`Example `INFO` | | `architecture` | `string` | Architecture used to build your bundle dependencies.`ARM64``X86_64`Example `X86_64` | | `node_version` | `string` | Node version used to package your dependencies. 14 version works only with X86_64, small instance.`12``14``18``20`Example `12` | | `compute_instance_size` | `string` | Compute instance size defines the computational instance used during the build.`LARGE``SMALL`Example `SMALL` | ##### Response `201``application/json` 1 fields Build created | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build_id which can be used for tracking build status. Usually it is a UUID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | `GET` `/builds/{build_id}` #### Retrieve Product Build Status `getBuildStatus` Retrieve Service Build Status retrieves metadata generated by the build. - Metadata is available only for builds that succeed (status==SUCCEEDED). - The artifact_url key in the response body contains the URL to the artifact that was built. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new artifact_url. - The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service are considered service metadata. - Regardless of status response contains build execution logs ##### Response 200400 application/json Copy 200 response ``` { "build_id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-485-8e8-abfdfd3b0a76/build.zip?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1623405346", "logs": [ "[Container] 2021/06/11 08:26:14 Waiting for agent ping\n", "[Container] 2021/06/11 08:26:17 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 Phase is DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 CODEBUILD_SRC_DIR=/codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2021/06/11 08:26:17 No commands found for phase name: post_build\n", "[Container] 2021/06/11 08:26:17 Processing environment variables\n", "[Container] 2021/06/11 08:26:17 Moving to directory /codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 Registering with agent\n", "[Container] 2021/06/11 08:26:17 Phases found in YAML: 2\n", "[Container] 2021/06/11 08:26:17 BUILD: 1 commands\n", "[Container] 2021/06/11 08:26:17 POST_BUILD: 0 commands\n", "[Container] 2021/06/11 08:26:17 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase INSTALL\n", "[Container] 2021/06/11 08:26:17 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase PRE_BUILD\n", "[Container] 2021/06/11 08:26:17 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase BUILD\n", "[Container] 2021/06/11 08:26:17 Running command python3.8 /opt/build.py --env $STAIRCASE_ENV --source $SOURCE_URL --id $BUNDLE_ID --host $HOST --api_key $X_API_KEY --bundle_type $BUNDLE_TYPE\n", "npm WARN builder-api@1.0.0 No repository field.", "Serverless: Excluding development dependencies...", "Serverless: Injecting required Python packages to package...", "Serverless: Updated AWS resource tags..", "Health response code 403. Body b'\\nAccessDeniedInvalid date (should be seconds since epoch): 1623403526code-health-checker/metric/7ac245b7-2f93-485-8e8-abfdfd3b0a76P9ZDFS9GZNB3NYDJol1TYDYI/NgoC5uaxDld7Cii9sbSO4e+d+FK7G+FZJ2NwpZ40JgylLT60DiuSAwdQUQLbkNA1pc='", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Entering phase POST_BUILD\n", "[Container] 2021/06/11 08:27:06 Running command if [ $CALLBACK_URL != \"null\" ]; then", " if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " else\n", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " fi\n", "fi", "\n", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Expanding base directory path: .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding .\n", "[Container] 2021/06/11 08:27:06 Expanding file paths for base directory .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding /output.json\n", "[Container] 2021/06/11 08:27:06 Found 1 file(s)\n", "[Container] 2021/06/11 08:27:06 Phase complete: UPLOAD_ARTIFACTS State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n" ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `build_id` required | `string` path | `7ac245b7-2f93-485-8e8-abfdfd3b0a76` | Unique build ID which was returned when build was started | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build ID which was returned when build was started | | `status` | `string` | Build status (IN_PROGRESS, FAILED, SUCCEEDED) | | `artifacts_url` | `string (url)` | Artifact URL if build was successfully completed | | `logs` | `string[]` | Build Logs which can be used for build problem investigation | | `metadata` | `object` | Metadata generated by build | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | ##### Response `404``application/json` 1 fields Build not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ### Chat Bundle `POST` `/chat` #### Build Chat Bundle `buildChatBundle` Build Frontend Bundle Build a deployable artifact for a chat bundle. The artifact must be provided via a URL. A callback will be sent to the URL specified in `callback_url` property. ##### Request application/json Copy ``` { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } ``` ##### Response 201400 application/json Copy Build created ``` { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | Usually a hash of the commit but can be any UUID. | | `source_url`required | `string (uri)` | Presigned URL to source code. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for build status | | `env_variables` | `string` | Env variables, that is used in build process. | ##### Response `201``application/json` 1 fields Build created | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build_id which can be used for tracking build status. Usually it is a UUID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | `GET` `/chat/{build_id}` #### Retrieve Chat Bundle Build Status `getChatBundleStatus` Get build status for Chat bundles retrieves metadata generated by the build. - Metadata is available only for builds that succeed (status==SUCCEEDED). - The artifact_url key in the response body contains the URL to the artifact that was built. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new artifact_url. - The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service are considered service metadata. - Regardless of status response contains build execution logs ##### Response 200400 application/json Copy 200 response ``` { "build_id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-485-8e8-abfdfd3b0a76/build.zip?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1623405346", "logs": [ "[Container] 2021/06/11 08:26:14 Waiting for agent ping\n", "[Container] 2021/06/11 08:26:17 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 Phase is DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 CODEBUILD_SRC_DIR=/codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2021/06/11 08:26:17 No commands found for phase name: post_build\n", "[Container] 2021/06/11 08:26:17 Processing environment variables\n", "[Container] 2021/06/11 08:26:17 Moving to directory /codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 Registering with agent\n", "[Container] 2021/06/11 08:26:17 Phases found in YAML: 2\n", "[Container] 2021/06/11 08:26:17 BUILD: 1 commands\n", "[Container] 2021/06/11 08:26:17 POST_BUILD: 0 commands\n", "[Container] 2021/06/11 08:26:17 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase INSTALL\n", "[Container] 2021/06/11 08:26:17 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase PRE_BUILD\n", "[Container] 2021/06/11 08:26:17 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase BUILD\n", "[Container] 2021/06/11 08:26:17 Running command python3.8 /opt/build.py --env $STAIRCASE_ENV --source $SOURCE_URL --id $BUNDLE_ID --host $HOST --api_key $X_API_KEY --bundle_type $BUNDLE_TYPE\n", "npm WARN builder-api@1.0.0 No repository field.", "Serverless: Excluding development dependencies...", "Serverless: Injecting required Python packages to package...", "Serverless: Updated AWS resource tags..", "Health response code 403. Body b'\\nAccessDeniedInvalid date (should be seconds since epoch): 1623403526code-health-checker/metric/7ac245b7-2f93-485-8e8-abfdfd3b0a76P9ZDFS9GZNB3NYDJol1TYDYI/NgoC5uaxDld7Cii9sbSO4e+d+FK7G+FZJ2NwpZ40JgylLT60DiuSAwdQUQLbkNA1pc='", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Entering phase POST_BUILD\n", "[Container] 2021/06/11 08:27:06 Running command if [ $CALLBACK_URL != \"null\" ]; then", " if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " else\n", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " fi\n", "fi", "\n", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Expanding base directory path: .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding .\n", "[Container] 2021/06/11 08:27:06 Expanding file paths for base directory .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding /output.json\n", "[Container] 2021/06/11 08:27:06 Found 1 file(s)\n", "[Container] 2021/06/11 08:27:06 Phase complete: UPLOAD_ARTIFACTS State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n" ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `build_id` required | `string` path | `7ac245b7-2f93-485-8e8-abfdfd3b0a76` | Unique build ID which was returned when build was started | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build ID which was returned when build was started | | `status` | `string` | Build status (IN_PROGRESS, FAILED, SUCCEEDED) | | `artifacts_url` | `string (url)` | Artifact URL if build was successfully completed | | `logs` | `string[]` | Build Logs which can be used for build problem investigation | | `metadata` | `object` | Metadata generated by build | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | ##### Response `404``application/json` 1 fields Build not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ### Data Bundle `POST` `/data` #### Build Data Bundle `buildDataBundle` Build a deployable artifact for a data bundle. The artifact must be provided via a URL. A callback will be sent to the URL specified in `callback_url` property. Build allows data bundle handlers to invoke IAM authorized endpoints by adding API execution policy. ##### Request application/json Copy ``` { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } ``` ##### Response 201400 application/json Copy Build created ``` { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | Usually a hash of the commit but can be any UUID. | | `source_url`required | `string (uri)` | Presigned URL to source code. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for build status | | `custom_parameters` | `string` | Custom parameters, that is used in deployment process. Passed parameter is available in data bundler handler event object with key name 'CUSTOM_PARAMETERS'. Custom parameters have 4 KB size limit. | | `serverless_version` | `string` | Serverless version, that is used in build process to update serverless framework version.`2.x``3.x`Example `3.x` | ##### Response `201``application/json` 1 fields Build created | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build_id which can be used for tracking build status. Usually it is a UUID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | `GET` `/data/{build_id}` #### Retrieve Data Bundle Build Status `getDataBundleStatus` Get build status for data bundles retrieves metadata generated by the build. - Metadata is available only for builds that succeed (status==SUCCEEDED). - The artifact_url key in the response body contains the URL to the artifact that was built. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new artifact_url. - The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service are considered service metadata. - Regardless of status response contains build execution logs ##### Response 200400 application/json Copy 200 response ``` { "build_id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-485-8e8-abfdfd3b0a76/build.zip?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1623405346", "logs": [ "[Container] 2021/06/11 08:26:14 Waiting for agent ping\n", "[Container] 2021/06/11 08:26:17 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 Phase is DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 CODEBUILD_SRC_DIR=/codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2021/06/11 08:26:17 No commands found for phase name: post_build\n", "[Container] 2021/06/11 08:26:17 Processing environment variables\n", "[Container] 2021/06/11 08:26:17 Moving to directory /codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 Registering with agent\n", "[Container] 2021/06/11 08:26:17 Phases found in YAML: 2\n", "[Container] 2021/06/11 08:26:17 BUILD: 1 commands\n", "[Container] 2021/06/11 08:26:17 POST_BUILD: 0 commands\n", "[Container] 2021/06/11 08:26:17 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase INSTALL\n", "[Container] 2021/06/11 08:26:17 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase PRE_BUILD\n", "[Container] 2021/06/11 08:26:17 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase BUILD\n", "[Container] 2021/06/11 08:26:17 Running command python3.8 /opt/build.py --env $STAIRCASE_ENV --source $SOURCE_URL --id $BUNDLE_ID --host $HOST --api_key $X_API_KEY --bundle_type $BUNDLE_TYPE\n", "npm WARN builder-api@1.0.0 No repository field.", "Serverless: Excluding development dependencies...", "Serverless: Injecting required Python packages to package...", "Serverless: Updated AWS resource tags..", "Health response code 403. Body b'\\nAccessDeniedInvalid date (should be seconds since epoch): 1623403526code-health-checker/metric/7ac245b7-2f93-485-8e8-abfdfd3b0a76P9ZDFS9GZNB3NYDJol1TYDYI/NgoC5uaxDld7Cii9sbSO4e+d+FK7G+FZJ2NwpZ40JgylLT60DiuSAwdQUQLbkNA1pc='", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Entering phase POST_BUILD\n", "[Container] 2021/06/11 08:27:06 Running command if [ $CALLBACK_URL != \"null\" ]; then", " if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " else\n", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " fi\n", "fi", "\n", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Expanding base directory path: .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding .\n", "[Container] 2021/06/11 08:27:06 Expanding file paths for base directory .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding /output.json\n", "[Container] 2021/06/11 08:27:06 Found 1 file(s)\n", "[Container] 2021/06/11 08:27:06 Phase complete: UPLOAD_ARTIFACTS State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n" ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `build_id` required | `string` path | `7ac245b7-2f93-485-8e8-abfdfd3b0a76` | Unique build ID which was returned when build was started | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build ID which was returned when build was started | | `status` | `string` | Build status (IN_PROGRESS, FAILED, SUCCEEDED) | | `artifacts_url` | `string (url)` | Artifact URL if build was successfully completed | | `logs` | `string[]` | Build Logs which can be used for build problem investigation | | `metadata` | `object` | Metadata generated by build | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | ##### Response `404``application/json` 1 fields Build not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ### Frontend Bundle `POST` `/frontend` #### Build Frontend Bundle `buildFrontendBundle` Build a deployable artifact for a frontend bundle. The artifact must be provided via a URL. A callback will be sent to the URL specified in `callback_url` property. ##### Request application/json Copy ``` { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } ``` ##### Response 201400 application/json Copy Build created ``` { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | Usually a hash of the commit but can be any UUID. | | `source_url`required | `string (uri)` | Presigned URL to source code. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for build status | | `env_variables` | `string` | Env variables, that is used in build process. | ##### Response `201``application/json` 1 fields Build created | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build_id which can be used for tracking build status. Usually it is a UUID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | `GET` `/frontend/{build_id}` #### Retrieve Frontend Bundle Build Status `getFrontendBundleStatus` Get build status for fronend bundles retrieves metadata generated by the build. - Metadata is available only for builds that succeed (status==SUCCEEDED). - The artifact_url key in the response body contains the URL to the artifact that was built. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new artifact_url. - The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service are considered service metadata. - Regardless of status response contains build execution logs ##### Response 200400 application/json Copy 200 response ``` { "build_id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-485-8e8-abfdfd3b0a76/build.zip?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1623405346", "logs": [ "[Container] 2021/06/11 08:26:14 Waiting for agent ping\n", "[Container] 2021/06/11 08:26:17 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 Phase is DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 CODEBUILD_SRC_DIR=/codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2021/06/11 08:26:17 No commands found for phase name: post_build\n", "[Container] 2021/06/11 08:26:17 Processing environment variables\n", "[Container] 2021/06/11 08:26:17 Moving to directory /codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 Registering with agent\n", "[Container] 2021/06/11 08:26:17 Phases found in YAML: 2\n", "[Container] 2021/06/11 08:26:17 BUILD: 1 commands\n", "[Container] 2021/06/11 08:26:17 POST_BUILD: 0 commands\n", "[Container] 2021/06/11 08:26:17 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase INSTALL\n", "[Container] 2021/06/11 08:26:17 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase PRE_BUILD\n", "[Container] 2021/06/11 08:26:17 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase BUILD\n", "[Container] 2021/06/11 08:26:17 Running command python3.8 /opt/build.py --env $STAIRCASE_ENV --source $SOURCE_URL --id $BUNDLE_ID --host $HOST --api_key $X_API_KEY --bundle_type $BUNDLE_TYPE\n", "npm WARN builder-api@1.0.0 No repository field.", "Serverless: Excluding development dependencies...", "Serverless: Injecting required Python packages to package...", "Serverless: Updated AWS resource tags..", "Health response code 403. Body b'\\nAccessDeniedInvalid date (should be seconds since epoch): 1623403526code-health-checker/metric/7ac245b7-2f93-485-8e8-abfdfd3b0a76P9ZDFS9GZNB3NYDJol1TYDYI/NgoC5uaxDld7Cii9sbSO4e+d+FK7G+FZJ2NwpZ40JgylLT60DiuSAwdQUQLbkNA1pc='", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Entering phase POST_BUILD\n", "[Container] 2021/06/11 08:27:06 Running command if [ $CALLBACK_URL != \"null\" ]; then", " if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " else\n", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " fi\n", "fi", "\n", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Expanding base directory path: .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding .\n", "[Container] 2021/06/11 08:27:06 Expanding file paths for base directory .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding /output.json\n", "[Container] 2021/06/11 08:27:06 Found 1 file(s)\n", "[Container] 2021/06/11 08:27:06 Phase complete: UPLOAD_ARTIFACTS State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n" ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `build_id` required | `string` path | `7ac245b7-2f93-485-8e8-abfdfd3b0a76` | Unique build ID which was returned when build was started | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build ID which was returned when build was started | | `status` | `string` | Build status (IN_PROGRESS, FAILED, SUCCEEDED) | | `artifacts_url` | `string (url)` | Artifact URL if build was successfully completed | | `logs` | `string[]` | Build Logs which can be used for build problem investigation | | `metadata` | `object` | Metadata generated by build | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | ##### Response `404``application/json` 1 fields Build not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ### Frontend Config Bundle `POST` `/frontend-config` #### Build Frontend Config Bundle `buildFrontendConfigBundle` Build a deployable artifact for a frontend config bundle. The artifact must be provided via a URL. A callback will be sent to the URL specified in `callback_url` property. ##### Request application/json Copy ``` { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } ``` ##### Response 201400 application/json Copy Build created ``` { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | Usually a hash of the commit but can be any UUID. | | `source_url`required | `string (uri)` | Presigned URL to source code. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for build status | | `env_variables` | `string` | Env variables, that is used in build process. | ##### Response `201``application/json` 1 fields Build created | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build_id which can be used for tracking build status. Usually it is a UUID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | `GET` `/frontend-config/{build_id}` #### Retrieve Frontend Config Bundle Build Status `getFrontendConfigBundleStatus` Get build status for Frontend Config bundles retrieves metadata generated by the build. - Metadata is available only for builds that succeed (status==SUCCEEDED). - The artifact_url key in the response body contains the URL to the artifact that was built. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new artifact_url. - The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service are considered service metadata. - Regardless of status response contains build execution logs ##### Response 200400 application/json Copy 200 response ``` { "build_id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-485-8e8-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-485-8e8-abfdfd3b0a76/build.zip?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1623405346", "logs": [ "[Container] 2021/06/11 08:26:14 Waiting for agent ping\n", "[Container] 2021/06/11 08:26:17 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 Phase is DOWNLOAD_SOURCE\n", "[Container] 2021/06/11 08:26:17 CODEBUILD_SRC_DIR=/codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2021/06/11 08:26:17 No commands found for phase name: post_build\n", "[Container] 2021/06/11 08:26:17 Processing environment variables\n", "[Container] 2021/06/11 08:26:17 Moving to directory /codebuild/output/src212027353/src\n", "[Container] 2021/06/11 08:26:17 Registering with agent\n", "[Container] 2021/06/11 08:26:17 Phases found in YAML: 2\n", "[Container] 2021/06/11 08:26:17 BUILD: 1 commands\n", "[Container] 2021/06/11 08:26:17 POST_BUILD: 0 commands\n", "[Container] 2021/06/11 08:26:17 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase INSTALL\n", "[Container] 2021/06/11 08:26:17 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase PRE_BUILD\n", "[Container] 2021/06/11 08:26:17 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:26:17 Phase context status code: Message: \n", "[Container] 2021/06/11 08:26:17 Entering phase BUILD\n", "[Container] 2021/06/11 08:26:17 Running command python3.8 /opt/build.py --env $STAIRCASE_ENV --source $SOURCE_URL --id $BUNDLE_ID --host $HOST --api_key $X_API_KEY --bundle_type $BUNDLE_TYPE\n", "npm WARN builder-api@1.0.0 No repository field.", "Serverless: Excluding development dependencies...", "Serverless: Injecting required Python packages to package...", "Serverless: Updated AWS resource tags..", "Health response code 403. Body b'\\nAccessDeniedInvalid date (should be seconds since epoch): 1623403526code-health-checker/metric/7ac245b7-2f93-485-8e8-abfdfd3b0a76P9ZDFS9GZNB3NYDJol1TYDYI/NgoC5uaxDld7Cii9sbSO4e+d+FK7G+FZJ2NwpZ40JgylLT60DiuSAwdQUQLbkNA1pc='", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Entering phase POST_BUILD\n", "[Container] 2021/06/11 08:27:06 Running command if [ $CALLBACK_URL != \"null\" ]; then", " if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " else\n", " curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'", " fi\n", "fi", "\n", "\n", "[Container] 2021/06/11 08:27:06 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n", "[Container] 2021/06/11 08:27:06 Expanding base directory path: .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding .\n", "[Container] 2021/06/11 08:27:06 Expanding file paths for base directory .\n", "[Container] 2021/06/11 08:27:06 Assembling file list\n", "[Container] 2021/06/11 08:27:06 Expanding /output.json\n", "[Container] 2021/06/11 08:27:06 Found 1 file(s)\n", "[Container] 2021/06/11 08:27:06 Phase complete: UPLOAD_ARTIFACTS State: SUCCEEDED\n", "[Container] 2021/06/11 08:27:06 Phase context status code: Message: \n" ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `build_id` required | `string` path | `7ac245b7-2f93-485-8e8-abfdfd3b0a76` | Unique build ID which was returned when build was started | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `build_id` | `string (uuid)` | Unique build ID which was returned when build was started | | `status` | `string` | Build status (IN_PROGRESS, FAILED, SUCCEEDED) | | `artifacts_url` | `string (url)` | Artifact URL if build was successfully completed | | `logs` | `string[]` | Build Logs which can be used for build problem investigation | | `metadata` | `object` | Metadata generated by build | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message in string or object format | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message in string format | | `url` | `string (url)` | URL with link to page with information how this issue can be resolved | ##### Response `404``application/json` 1 fields Build not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ## Errors `400``403``404` ## More in Shipping - Previous product: Assess - Next product: Code --- # Code # Code Repository operations as an API: clone, branch, commit, pull request and secret handling, as the first pipeline stage. The pipeline starts by acting on the repository, and it does that through an API rather than through shell steps embedded in a build definition. Cloning at a pinned commit, opening a branch, committing generated output and raising a pull request are all calls. That is what makes generation practical. A configuration bundle produced by a generator can be committed and proposed by the same pipeline that will build it. ## Operations ### Branch `POST` `/branches` #### Retrieve List of Branches per Repository `getBranch` List the name of branches in a repository This service retrieves a list of names of branches in a given repository and project. #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez" } ``` ##### Response 202400401403404405 application/json Copy List the branches of a given repository ``` { "branches": [ "master", "developer", "qa" ], "default_branch": "master" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name or account not found. ``` { "message": "Not found. Either repository_name, branch or commits are not found" } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository | | `github_account`required | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. settings/Personal access token/New/Enable SSO. | ##### Response `202``application/json` 2 fields List the branches of a given repository | Field | Type | Description | | --- | --- | --- | | `branches` | `string[]` | List of branches of repository | | `default_branch` | `string` | Default branch of repository | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name or account not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Clone `POST` `/clone` #### Clone Repository `cloneRepository` Clone code This service clones code for a given repository and branch. The service returns a bundle_id that can be used to check the status and result of the request. The cloned code is persisted as a .zip file in the Staircase persistence layer. #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "branch": "master", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez" } ``` ##### Response 202400401403404405 application/json Copy Clone job started ``` { "bundle_id": "979a6aa8-4f2-400d-9451-80ee1e127485" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name or branch is not found. ``` { "message": "Not found. Either repository_name or branch is not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository to be cloned | | `branch` | `string` | Name of GitHub branch | | `commit_sha` | `string` | Commit SHA | | `github_account` | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. Go to settings/Personal access token/New/Enable SSO. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for code status | ##### Response `202``application/json` 1 fields Clone job started | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | Bundle id of the cloned project | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name or branch is not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `GET` `/clone/{bundle_id}` #### Retrieve Clone Status `cloneBundle` This service retrieves the status of a Clone Code request for a given bundle_id. Status = IN_PROGRESS, SUCCEEDED, or FAILED. Continue to ping this service until you receive a status = SUCCEEDED. Retrieve Clone Status returns a source URL. The source URL is a presigned URL for the new cloned code package. Provide the source URL as a parameter to the Build Bundle service. ##### Response 200400403404405 application/json Copy Clone status ``` { "bundle_id": "979a6aa8-4f2-400d-9451-80ee1e127485", "clone_status": "SUCCEEDED", "commit_hash": "80a6e06179b267f0f4da68a2e1707d17b8f77fb2", "source_url": "https://code-dev-025.s3.amazonaws.com/service-builder-api/979a6aa8/source.zip", "metadata": { "service-code": { "commit_hash": "979a6aa8-4f2-400d-9451-80ee1e127485", "id": "d898b987-eda3-4b75-b7e7-bea8ae39674c", "issuer": "https://api.staircaseapi.com/code", "status": "SUCCEEDED", "timestamp": 1611603369.1289215, "version": 1.1, "repository_name": "StaircaseAPI/code" } } } ``` application/json Copy Bad syntax ``` { "message": "Bad syntax" } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Clone job not found. ``` { "message": "Clone job not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `bundle_id` required | `string` path | `979a6aa8-4f2-400d-9451-80ee1e127485` | bundle id of the cloned project | ##### Response `200``application/json` 5 fields Clone status | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | ID returned by **Clone Code** | | `clone_status` | `string` | IN_PROGRESS, FAILED, or SUCCEEDED`FAILED``IN_PROGRESS``SUCCEEDED` | | `commit_hash` | `string (uuid)` | The branch last commit hash when clone was completed. | | `metadata` | `object` | Metadata included in presigned URL with the clone status information | | `source_url` | `string (uri)` | Presigned URL for the new cloned code package and metadata with information about the clone. | ##### Response `400``application/json` 1 fields Bad syntax | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Clone job not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Repository `POST` `/repos` #### Create repository `createRepository` This service creates repository in given organization. #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez", "private": true, "visibility": "private", "gitignore_template": "Python", "description": "Repository description" } ``` ##### Response 202400401403404405 application/json Copy Repository created ``` { "status": "Succeeded", "repo_url": "https://" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name or account not found. ``` { "message": "Not found. Either repository_name, branches or secret" } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository | | `github_account`required | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. settings/Personal access token/New/Enable SSO. | | `private` | `string` | Whether the GitHub repository is private | | `visibility` | `string` | Visibility level of the GitHub repository | | `description` | `string` | Description of the GitHub Repository | | `gitignore_template` | `string` | Template name for git ignore file. For more information please visit GitHub git ignore collection pageExample `Python` | ##### Response `202``application/json` 2 fields Repository created | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the pull request creation | | `repo_url` | `string` | Created repository URL | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name or account not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Secret `POST` `/secret` #### Create or Update Repository Secret `updateSecret` Create or update a secret This service create or update a secret in a given repository #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez", "secret_name": "newsecret", "secret_value": "0d1357" } ``` ##### Response 202400401403404405 application/json Copy The secret was updated or created ``` { "message": "Succeeded" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name or account not found. ``` { "message": "Not found. Either repository_name, branches or secret" } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository | | `github_account` | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. Go to settings/Personal access token/New/Enable SSO. | | `secret_name` | `string` | The name of the secret | | `secret_value` | `string` | The value of the secret | ##### Response `202``application/json` 1 fields The secret was updated or created | Field | Type | Description | | --- | --- | --- | | `message` | `string` | status | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name or account not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `POST` `/remove-secret` #### Delete Repository Secret `removeSecret` Delete a secret This service deletes a secret in a given repository #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez", "secret_name": "newsecret" } ``` ##### Response 202400401403404405 application/json Copy The secret was deleted ``` { "message": "Succeeded" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name or account not found. ``` { "message": "Not found. Either repository_name, branches or secret" } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository to be cloned | | `github_account`required | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. settings/Personal access token/New/Enable SSO. | | `secret_name`required | `string` | The name of the secret | ##### Response `202``application/json` 1 fields The secret was deleted | Field | Type | Description | | --- | --- | --- | | `message` | `string` | status | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name or account not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Commit `POST` `/commits` #### Retrieve List of Commits per Branch `getCommit` List of a branch commit history This service retrieves a list of the last of 14 days commits history from a given repository and branch, start date and end date can be given, the difference between the two cannot surpass 14 days. The service returns a list of commits objects with a maximum of 30 . By default, it will return a list of the last 14 days of commits with a maximum response of 30. Next_token can be used to retrieve the next 30 commits until is null. #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "branch": "master", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez", "start_date": "2021-01-05", "end_date": "2021-01-15", "next_token": 1 } ``` ##### Response 202400401403404405 application/json Copy Clone job started ``` { "commits": [ { "comments": "First commit", "author": "bezos", "date": "2021-01-29T16:55:51Z" }, { "comments": "Second commit", "author": "jeff", "date": "2021-01-29T16:25:51Z" } ], "next_token": 0 } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name, branch or commits are not found. ``` { "message": "Not found. Either repository_name, branch or commits are not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository | | `branch` | `string` | Name of GitHub branch | | `github_account`required | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. Go to settings/Personal access token/New/Enable SSO. | | `start_date` | `string` | Minimum date in time that will be returned in this format "YYYY-MM-DD" | | `end_date` | `string` | Maximum date in time that will be returned in this format "YYYY-MM-DD" | | `next_token` | `integer` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | ##### Response `202``application/json` 3 fields Clone job started | Field | Type | Description | | --- | --- | --- | | `commits` | `object[]` | List of commits of branch. | | `comment` | `string` | Comment | | `author` | `string` | Author name | | `date` | `string` | Date | | `pagination` | `integer` | Pagination number | | `totalSize` | `integer` | Total number of commits in the branch | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name, branch or commits are not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `POST` `/commits/change` #### Commit changes to new branch `commitChange` This service commits changes provided in zip file by creating new branch from main branch. Zip file should contain git ignore file. #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez", "new_branch": "feature-branch", "user_email": "user@email.com", "user_name": "User Name", "zip_url": "https://bucket.s3.amazonaws.com/repo.zip?AWSAccessKeyId=&Signature=" } ``` ##### Response 202400401403404405 application/json Copy Commit operation job started ``` { "operation_id": "704db6f3-c534-4c4b-b7dd-d4fa52d60e71" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name, branch or commits are not found. ``` { "message": "Not found. Either repository_name, branch or commits are not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 9 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository | | `github_account`required | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. Go to settings/Personal access token/New/Enable SSO. | | `new_branch`required | `string` | Name of branch that will be created | | `commit_message` | `string` | Commit message for changes | | `user_email`required | `string` | Git user email. The email address used in the author identity when creating commit. | | `user_name`required | `string` | Git username. The human-readable name used in the author identity when creating commit. | | `zip_url`required | `string` | Pre-signed URL that will be used for getting repository zip file. | | `callback_url` | `string (uri)` | Callback URL where are you waiting for commit status | ##### Response `202``application/json` 1 fields Commit operation job started | Field | Type | Description | | --- | --- | --- | | `operation_id` | `string` | Operation ID of started asynchronous job. | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name, branch or commits are not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `GET` `/commits/change/{operation_id}` #### Retrieve Commit Changes Status `getCommitChangeStatus` Retrieve Commit Change Status This service retrieves the status of a Commit Change request for a given operation_id. Status = REQUEST_MADE, IN_PROGRESS, SUCCEEDED, or FAILED. ##### Response 200400403404405 application/json Copy Clone status ``` { "status": "SUCCEEDED" } ``` application/json Copy Bad syntax ``` { "message": "Bad syntax" } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Commit change operation not found. ``` { "message": "Commit change operation not found." } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `operation_id` required | `string` path | `979a6aa8-4f2-400d-9451-80ee1e127485` | operation id of the started commit change job | ##### Response `200``application/json` 1 fields Clone status | Field | Type | Description | | --- | --- | --- | | `status` | `string` | REQUEST_MADE, IN_PROGRESS, FAILED, or SUCCEEDED`FAILED``IN_PROGRESS``REQUEST_MADE``SUCCEEDED` | ##### Response `400``application/json` 1 fields Bad syntax | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Commit change operation not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Pull Request `POST` `/pull-request` #### Create Pull Request `pullRequest` Create pull request This service creates pull request. Reviewers field is optional for adding reviewer to pull request. Author of the pull request can not be added as a reviewer. #### Warning `project_name` can still be used instead of `repository_name` but is to be deprecated in the future. ##### Request application/json Copy ``` { "repository_name": "code", "github_account": "staircaseapi", "github_token": "a50d135781d8c9ca26884ab0a858205d74f726ez", "head": "head", "base": "base", "title": "title", "body": "body" } ``` ##### Response 202400401403404405 application/json Copy Pull request created ``` { "message": "Succeeded" } ``` application/json Copy Bad request syntax or missed a required field ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Unauthorized, Bad credentials. ``` { "message": "Unauthorized, Bad credentials." } ``` application/json Copy Bad request syntax or forbidden request ``` { "message": "Bad request syntax or missed a required field" } ``` application/json Copy Not found. Either repository_name or account not found. ``` { "message": "Not found. Either repository_name, branches or secret" } ``` application/json Copy Method not allowed. ``` { "message": "The method is not allowed for the requested URL" } ``` ##### Request body`application/json` 8 fields | Field | Type | Description | | --- | --- | --- | | `repository_name`required | `string` | Name of the GitHub repository | | `github_account`required | `string` | GitHub account name | | `github_token`required | `string` | GitHub token. settings/Personal access token/New/Enable SSO. | | `head`required | `string` | The name of the branch where your changes are implemented. | | `base`required | `string` | The name of the branch you want the changes pulled into. | | `title`required | `string` | The title of the new pull request | | `body` | `string` | The contents of the pull request | | `reviewers` | `string[]` | List of reviewers for pull request | ##### Response `202``application/json` 2 fields Pull request created | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the pull request creation | | `pr_url` | `string` | Created pull request URL | ##### Response `400``application/json` 1 fields Bad request syntax or missed a required field | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `401``application/json` 1 fields Unauthorized, Bad credentials. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Bad request syntax or forbidden request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. Either repository_name or account not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `405``application/json` 1 fields Method not allowed. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Operations `POST` `/` #### Post operation `post-operation` Description ##### Request application/json Copy ``` { "test": "test" } ``` ##### Response application/json Copy 200 response ``` { "assessment_id": "devops-code-assessor:9dff4dc3-f700-4fc8-a51a-56d91d7ed7df" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `test1` required | `string` header | `Test1` | Authorization key | | `x-api-key` required | `string` header | `Test1` | Authorization key | | `test` | `string` header | `Test` | test key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `test` | `object[]` | Errors array | | `message` | `string` | Error message | | `path` | `string` | Description | | `errors` | `object` | Contains errors on failed assessment | | `errors` | `object` | Errors1 | | `errors2` | `string` | Errors2 | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `assessment_id` | `string` | Assessment id, used for get assessment status | ##### Other responses `204``400` ## Errors `400``401``403``404``405``422` ## More in Shipping - Previous product: Build - Next product: Comply --- # Comply # Comply Compliance evidence generated by the pipeline that ships the code: control status against named standards, and a secure workspace for remote access. Comply checks source code and infrastructure against committed control sets — `NIST`, `PCI`, `SOC 2` and `HIPAA` among them — and reports misconfigurations and violations in near real time rather than at review time. Findings are broadcast into Health, so a configuration that drifts out of policy surfaces in the same place an operator is already watching, and can be corrected there. ## How it works It also provides the secure workspace an engineer outside the United States works from to reach the cloud console and the product APIs, and it is the path that issues temporary maintenance credentials after the environment owner approves the request. Evidence is generated continuously because the alternative measures a moment. A control verified once a year has an unknown state between verifications, and that gap is exactly where drift lives. Comply is callable on its own as well as being a pipeline stage, which is what lets an environment be assessed without a deployment. ## Operations ### Audit `POST` `/audit/vanta_role` #### Create Vanta Role `create-vanta-role` Create vanta role Create vanta role creates a role to integrate your environment with vanta.com, an application for security audit. This service output an arn role that can be used inside vanta application to give vanta access to audit your environment. This service assumes that you have a vanta account, and you are aware of the external_id and account_id associated with that account. ##### Request application/json Copy ``` { "external_id": "BA51515716F989E", "account_id": "956993596393" } ``` ##### Response application/json Copy 200 response ``` { "vanta_role_arn": "arn:aws:iam::891306488523:role/vanta-auditor-202d30c9-06ce-4de0-889a-a17721d670d0" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `external_id`required | `string` | External id from vanta.com | | `account_id`required | `string` | Account id from vanta.com | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `vanta_role_arn` | `string` | Vanta role arn which can be added to vanta to start auditing your environment | ##### Other responses `400``401``403``404` `DELETE` `/audit/vanta_role/{role_name}` #### Delete Vanta Role `delete-vanta-role` Delete vanta role Delete vanta role deletes an existing role for vanta.com by name, you can get the role name by using the service Retrieve Vanta Roles ##### Response application/json Copy 200 response ``` { "status": "SUCCEEDED" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `role_name` required | `string` path | `vanta-auditor-addg9e54-53dd-48aa-bad1-82762a05ab44` | Role name for vanta.com | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Response status | ##### Other responses `400``401``403``404` `GET` `/audit/vanta_roles` #### Retrieve Vanta Roles `retrieve-vanta-role` Retrieve vanta roles retrieves a list of roles created to integrate your environment with vanta.com ##### Response application/json Copy 200 response ``` { "vanta_roles": [ { "role_name": "vanta-auditor-ee373866-5447-435f-b4e0-43390de1392a", "vanta_role_arn": "arn:aws:iam::791306477523:role/vanta-auditor/vanta-auditor-ee373866-5447-435f-b4e0-43390de1392a", "account_id": "956993596390", "external_id": "BA51515716F989F" } ] } ``` ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `vanta_roles` | `object[]` | Vanta roles | | `role_name` | `string` | Auto-generated role name | | `vanta_role_arn` | `string` | Vanta role arn which can be added to vanta.com | | `account_id` | `string` | Account id from vanta.com | | `external_id` | `string` | External id from vanta.com | ##### Other responses `400``401``403``404` `PUT` `/audit/cloudtrail` #### Set Cloudtrail Status `set-cloudtrail-status` Set cloudtrail status Set cloudtrail status enables and disables the generation of the cloudtrail logs which are necessary to meet security requirements for vanta.com ##### Request Disabling cloudtrailEnabling cloudtrail application/json Copy ``` { "cloudtrail_enabled": "false" } ``` application/json Copy ``` { "cloudtrail_enabled": "true" } ``` ##### Response application/json Copy 200 response ``` { "status": "SUCCEEDED" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `cloudtrail_enabled`required | `string` | Cloudtrail logs status | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Response status | ##### Other responses `400``401``403``404` ### Workspace `GET` `/bundles` #### Retrieve Bundles `get-workspace-bundles` Retrieve workspaces bundles Retrieves a list that describes the available WorkSpace bundles. ##### Response application/json Copy 200 response ``` { "Bundles": [ { "BundleID": "ws-8kvnwmhz4", "Name": "Bundle name", "Description": "Description" } ] } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `123456` | The token to use to retrieve the next page of results. This value is null when there are no more results to return. | | `owner` | `string` query | `123456` | To describe the bundles provided by Amazon Web Services, specify AMAZON. To describe the bundles that belong to your account, don't specify a value. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `Bundles` | `object[]` | Array of workspaces Bundles information | ##### Other responses `400``401``403``404``422` `POST` `/bundles` #### Create Bundles `create-bundles` Create bundles 'Create image Creates the specified WorkSpace bundle. For more information about creating WorkSpace bundles, see Create a Custom WorkSpaces Image and Bundle.' ##### Request application/json Copy ``` { "name": "DefaultBundle", "description": "Default Bundle", "image_id": "wsb-gk1wpk43z", "compute_type": "STANDARD", "user_storage": "5", "root_storage": "5" } ``` ##### Response application/json Copy 200 response ``` { "message": "The bundle is being created." } ``` ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | The name of the bundle. | | `description`required | `string` | The description of the bundle. | | `image_id`required | `string` | The identifier of the image that is used to create the bundle. | | `compute_type`required | `string` | Describes the computed type of the bundle. | | `user_storage`required | `string` | The size of the user volume. | | `root_storage`required | `string` | The size of the root volume. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The status message about the creation | ##### Other responses `400``401``403``404``422` `PUT` `/default-bundle` #### Update Default Bundle `update-default-bundle` Update default bundle 'Update default bundle Updates the default bundle that will be used when creating workspaces' ##### Request application/json Copy ``` { "budnle_id": "wsb-gk1wpk43z" } ``` ##### Response application/json Copy 200 response ``` { "message": "Succeeded" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id`required | `string` | The identifier of the bundle for the WorkSpace. You can use DescribeWorkspaceBundles to list the available bundles. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The status message about the creation | ##### Other responses `400``401``403``404``422` `GET` `/images` #### Retrieve Images `get-workspace-images` Retrieve workspaces images Retrieves a list that describes one or more images. ##### Response application/json Copy 200 response ``` { "Images": [ { "ImageID": "ws-8kvnwmhz4", "Name": "Image name", "Description": "Description" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `123456` | The token to use to retrieve the next page of results. This value is null when there are no more results to return. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `Images` | `object[]` | Array of workspaces images information | ##### Other responses `400``401``403``404``422` `POST` `/images` #### Create Image `create-image` Create image Creates a new updated WorkSpace image based on the specified source image. ##### Request application/json Copy ``` { "bundle_id": "wsb-gk1wpk43z", "name": "DefaultImage", "description": "Default image" } ``` ##### Response application/json Copy 200 response ``` { "message": "The image is being created." } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string` | The identifier of the bundle for the WorkSpace. You can use DescribeWorkspaceBundles to list the available bundles. | | `description` | `string` | A description of whether updates for the WorkSpace image are available. | | `name`required | `string` | The name of the new updated WorkSpace image. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The status message about the creation | ##### Other responses `400``401``403``404``422` `POST` `/workspace` #### Create Workspace `create-workspace` Create workspace creates a workspace for the user provided. ##### Request Create a default workspaceCreate a custom workspace application/json Copy ``` { "given_name": "Given Name", "surname": "Surname" } ``` application/json Copy ``` { "bundle_id": "wsb-gk1wpk43z", "given_name": "Given Name", "surname": "Surname" } ``` ##### Response 200422 application/json Copy 200 response ``` { "message": "The workspace is being created. The user will receive and email with instructions and information about the workspace." } ``` application/json Copy Unprocessable Entity ``` { "message": "The entity can not be processed." } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string` | The identifier of the bundle for the WorkSpace. You can use DescribeWorkspaceBundles to list the available bundles. | | `given_name`required | `string` | The given name of the user the workspace will be created for. | | `surname`required | `string` | The surname of the user the workspace will be created for. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The status message about the creation of the workspace | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `message`required | `string` | Error description. | ##### Other responses `400``401``403``404` `DELETE` `/workspace/{workspace_id}` #### Delete Workspace `delete-workspace` Delete workspace deletes a workspace and its associated user. ##### Response 200422 Not existent422 Missing id422 Rippling synchronization422 Deletion disabled422 application/json application/json Copy 200 response ``` { "message": "Workspace deletion has started." } ``` application/json Copy Unprocessable Entity ``` { "message": "The workpsace does not exist." } ``` application/json Copy Unprocessable Entity ``` { "message": "Workspace id must be provided." } ``` application/json Copy Unprocessable Entity ``` { "message": "This workspace can only be deleted via Rippling automated synchronization." } ``` application/json Copy Unprocessable Entity ``` { "message": "Workspace creation/deletion is disabled." } ``` application/json Copy Unprocessable Entity ``` { "message": "The entity can not be processed." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `workspace_id` required | `string` path | `ws-cv8hqyrjr` | Id of the workspace that will be deleted. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The status message | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `message`required | `string` | Error description. | ##### Other responses `400``401``403``404` `PUT` `/workspace/{workspace_id}` #### Update Workspace `update-workspace` Update workspace Update a workspace compute type. Compute type payload attribute can have the following values: - VALUE [1 CPU, 2 GB Memory, 80|10 GB root|user storage] - STANDARD [2 CPU, 4 GB Memory, 80|50 GB root|user storage] - PERFORMANCE [2 CPU, 7.5 GB Memory, 80|100 GB root|user storage] - POWER [4 CPU, 16 GB Memory, 175|100 GB root|user storage] - POWERPRO [8 CPU, 32 GB Memory, 175|100 GB root|user storage] - GRAPHICS [8 CPU, 15 GB Memory, 100|100 GB root|user storage] - GRAPHICSPRO [16 CPU, 122 GB Memory, 100|100 GB root|user storage] ##### Request application/json Copy ``` { "compute_type": "VALUE" } ``` ##### Response application/json Copy 200 response ``` { "message": "Workspace update has started." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `workspace_id` required | `string` path | `ws-cv8hqyrjr` | Id of the workspace that will be updated. | | `Authorization` required | `string` header | `` | Authorization token. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `compute_type` | `string` | Compute type. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The status message | ##### Other responses `400``401``403``404` `POST` `/workspace/reset-password` #### Reset Password `reset-workspace-password` Reset Password set new password using authorized credentials ##### Request application/json Copy ``` { "token": "123" } ``` ##### Response application/json Copy 200 response ``` { "message": "Succeeded." } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `new_password` | `string` | New password. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message describing process. | ##### Other responses `400``401``403``404``422` `GET` `/workspaces` #### Retrieve Workspaces `get-workspace` Retrieve workspaces returns a list of workspaces. ##### Response 200422 application/json Copy 200 response ``` { "Workspaces": { "WorkspaceId": "ws-8kvnwmhz4", "DirectoryId": "d-90675e3e71", "UserName": "efrain.coello", "IpAddress": "10.1.0.137", "State": "STOPPED", "BundleId": "wsb-gk1wpk43z", "SubnetId": "subnet-034c07dc6446907de", "ComputerName": "WSAMZN-4M9H1COV" } } ``` application/json Copy Unprocessable Entity ``` { "message": "The entity can not be processed." } ``` ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `Workspaces` | `object[]` | Array of workspaces information | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessable entity error. | | `message`required | `string` | Error description. | ##### Other responses `400``401``403``404` `POST` `/compliance_metrics` #### Trigger Rippling Synchronization `trigger-rippling-sync` Trigger rippling synchronization starts the synchronization with Rippling. The token is validated against Rippling. If the token is valid the synchronization is triggered but, the token is not saved for the scheduled synchronization calls. ##### Request application/json Copy ``` { "rippling_token": "73ghdygye737YTY73euyetdyydu73587ksjeifhyYGDJ" } ``` ##### Response 200400 application/json Copy 200 response ``` { "message": "Successfully started rippling synchronization." } ``` application/json Copy Bad Request ``` { "message": "Rippling token provided is invalid." } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `rippling_token`required | `string` | Rippling token that should match the token used for the Rippling synchronization | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response status | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error description. | ##### Other responses `401``403``404` ### Compliance `POST` `/compliance` #### Create Compliance `new-compliance` Comply looks for security violations based on security rules of comply for a given product. Comply returns an compliance_id in the response body. To retrieve the results of the security validation, call Retrieve Compliance Status with the compliance_id. Requirements to pass comply. 1. The name of your project in asana must be the same as the product ontology. 2 Get your asana token here ``````. 1. Add the custom field "Github" to your asana project. 1. Add the link to your pull request in asana task custom field "Github" field. 1. The task must be in the column "In progress" of asana. ##### Request application/json Copy ``` { "source_url": "https://code-dev-0258.s3.amazonaws.com/code-comply/1506dbf2/source.zip?AWSAccessKeyId=2323", "product_name": "Comply" } ``` ##### Response application/json Copy 200 response ``` { "compliance_id": "9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `asana_token` required | `string` header | `1/1199400791141010:f1d4b85a291da54a88e14813a91d4b97` | Authorization Asana Token | | `github_token` required | `string` header | `e50d125791d8c9ca25774ab0a758205d74f726ed` | GitHub Token | | `comply_client_id` | `string` header | `6779ef20e75817b79602` | Client credential generated by comply authentication | | `comply_client_secret` | `string` header | `269d98e4922fb3895e9ae2108cbb5064` | Client credential generated by comply authentication | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `source_url`required | `string` | URL to project source code. | | `product_name`required | `string` | Product Name. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `compliance_id` | `string` | Compliance id, used for get compliance status | ##### Other responses `400``401``403``404` `GET` `/compliance_metrics` #### Retrieve Compliance Metrics Generation `get-compliance-metrics` Retrieve compliance metrics generation status Retrieve compliance metrics generation status shows whether compliance metrics are being sent to health product or not. ##### Response application/json Copy 200 response ``` { "message": "Sending compliance metrics is enabled." } ``` ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response status | ##### Other responses `400``401``403``404` `GET` `/compliance/{compliance_id}` #### Retrieve Compliance Status `compliance-status` Retrieve Compliance Status retrieves the results of the security validation and SOC2 process compliance status such as Change request process performed by Comply for the given compliance_id. ##### Response 200 Succeeded response200 Failed response application/json Copy 200 response ``` { "compliance_id": "9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "metadata": { "service-comply": { "id": "9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "issuer": "https://api.staircaseapi.com/comply", "status": "SUCCEEDED", "severity_label": "LOW", "timestamp": 1611949487.728646, "version": "1.0.0" }, "service-code": { "commit_hash": "5a8d1bbd276306e73ad5fcb1c45dfe3bb2e6c5c2", "id": "1506dbf2-ea7b-4b76-9f51-2ebb0ac49af1", "issuer": "https://api.staircaseapi.com/code", "status": "SUCCEEDED", "timestamp": 1611948276.2954555, "version": 1.1 } }, "source_url": "https://code-comply-oybto4.s3.amazonaws.com/comply/devops-code-comply-a51a-56d91d7ed7df/build.zip?AWSAccessKeyId=2525&Signature=TyI1LC0", "status": "SUCCEEDED", "warnings": { "security_violations": [ { "resource_id": "arn:aws:lambda:us-east-1:791306477523:function:code-assessor-dev-apiGatewayLogHandler", "resource_type": "AwsLambdaFunction", "severity": "LOW", "standar": "PCI-DSS", "remediation": "https://docs.aws.amazon.com/console/securityhub/PCI.Lambda.2/remediation", "description": "PCI.Lambda.2 Lambda functions should be in a VPC", "resource_name": "code-assessor-dev-apigatewayloghandler", "stack_name": "code-assessor-dev", "product_name": "Assess" } ] } } ``` application/json Copy 200 response ``` { "compliance_id": "9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "errors": { "process_violations": [ { "process": "Change request process", "message": "Section Accepted not found" } ] }, "metadata": { "service-comply": { "id": "9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg", "issuer": "https://api.staircaseapi.com/comply", "status": "FAILED", "severity_label": "HIGH", "timestamp": 1611949487.728646, "version": "1.0.0" }, "service-code": { "commit_hash": "5a8d1bbd276306e73ad5fcb1c45dfe3bb2e6c5c2", "id": "1506dbf2-ea7b-4b76-9f51-2ebb0ac49af1", "issuer": "https://api.staircaseapi.com/code", "status": "SUCCEEDED", "timestamp": 1611948276.2954555, "version": 1.1 } }, "status": "FAILED", "source_url": "https://code-comply-oybto4.s3.amazonaws.com/comply/devops-code-comply-a51a-56d91d7ed7df/build.zip?AWSAccessKeyId=2525&Signature=TyI1LC0", "warnings": { "security_violations": [ { "resource_id": "arn:aws:lambda:us-east-1:791306477523:function:code-assessor-dev-insertRule", "resource_type": "AwsLambdaFunction", "severity": "MEDIUM", "standar": "AWS-Foundational-Security-Best-Practices", "remediation": "https://docs.aws.amazon.com/console/securityhub/Lambda.4/remediation", "description": "Lambda.4 Lambda functions should have a dead-letter queue configured", "resource_name": "code-assessor-dev-insertrule", "stack_name": "code-assessor-dev", "product_name": "Assess" } ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `compliance_id` required | `string` path | `9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg` | id of Compliance | ##### Response `200``application/json` 6 fields 200 response | Field | Type | Description | | --- | --- | --- | | `compliance_id` | `string` | Compliance id | | `errors` | `object` | Compliance errors | | `security_violations` | `object` | Contains security violations | | `source_url` | `string` | Presigned URL metadata in the header for Comply and other products. This metadata is in use as a signature of successful compliance. | | `status` | `string` | Status of compliance`COMPLIANT``FAILED``FAULT``IN_PROGRESS``NON_COMPLIANT``STOPPED``SUCCEEDED``TIMED_OUT` | | `metadata` | `object` | Compliance metadata plus metadata included in the compliance presigned URL coming from other products | | `service-comply` | `object` | Compliance metadata | | `id` | `string` | Compliance id | | `issuer` | `string` | Compliance issuer | | `status` | `string` | Compliance status`COMPLIANT``FAILED``FAULT``IN_PROGRESS``NON_COMPLIANT``STOPPED``SUCCEEDED``TIMED_OUT` | | `severity_label` | `string` | Compliance severity label`CRITICAL``HIGH``INFORMATIONAL``LOW``MEDIUM` | | `timestamp` | `object` | Compliance timestamp | | `version` | `object` | Compliance version | | `warnings` | `object` | Compliance warnings | | `process_violations` | `object` | Compliance process violations | ##### Other responses `400``401``403``404` `PUT` `/compliance_metrics` #### Set Compliance Metrics Generation `put-compliance-metrics` Set compliance metrics generation Set compliance metrics generation enables or disables the generation of compliance metrics sent to the health API. ##### Request Disabling reportEnabling report application/json Copy ``` { "compliance_metrics_enabled": "false" } ``` application/json Copy ``` { "compliance_metrics_enabled": "true" } ``` ##### Response application/json Copy 200 response ``` { "message": "Sending compliance metrics is enabled." } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `compliance_metrics_enabled`required | `string` | Compliance metrics generation status | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response status | ##### Other responses `400``401``403``404` ### Identity `GET` `/configurations` #### Retrieve configuration data `get-configuration-data` Retrieve configuration data retrieves data to configure an identity provider ##### Response application/json Copy 200 response ``` { "acs_url": "https://staircase.com/saml2/idpresponse", "identity_id": "urn:amazon:cognito:sp:us-east-1_bAcc5ljlp", "login_url": "https://staircase.com/login?client_id=1236&response_type=token&scope=email+openid&redirect_uri=https://staircase.com/callback" } ``` ##### Response `200``application/json` 3 fields 200 response | Field | Type | Description | | --- | --- | --- | | `acs_url` | `string` | ACS URL | | `identity_id` | `string` | Identity id | | `login_url` | `string` | Login URL | ##### Other responses `400``401``403``404` `POST` `/identity_providers` #### Set identity provider `set-identity-provider` Set identity provider Sets identity data using provider metadata** ##### Request application/json Copy ``` { "metadata": "Metadata" } ``` ##### Response application/json Copy 200 response ``` { "status": "SUCCEEDED" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `metadata`required | `string` | Provider Metadata | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status process | ##### Other responses `400``401``403``404` `DELETE` `/identity_providers` #### Remove identity provider `remove-identity-provider` Remove identity provider deletes identity provider settings ##### Response application/json Copy 200 response ``` { "status": "SUCCEEDED" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `123` | Authorization Token | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status process | ##### Other responses `400``401``403``404` `POST` `/users_access` #### Set user access `set-user-access` Set user access Sets temporary access to specific environments** ##### Request application/json Copy ``` { "email": "example@staircase.co", "expiration": 1441, "environment_domain": "example.com" } ``` ##### Response application/json Copy 200 response ``` { "status": "SUCCEEDED" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `123` | Authorization Token | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | User email | | `expiration` | `integer` | Expiration minutes | | `environment_domain` | `string` | Environment domain | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status process | ##### Other responses `400``401``403``404` ### SOC2 `POST` `/soc2/offboarding` #### Create Offboarding Data `new-soc2-offboarding-data` Create offboarding data Comply looks into controls required for SOC2 compliance. One of these controls is around on-boarding and off-boarding. As part of this control, there must be tasks for new employees to onboard and get access to different systems such as GitHub, G Suite. Comply integrates with Rippling HR tool and Asana task management tool to retrieve the list of employees and to make sure that there is an offboarding task for them. This endpoint can be used by auditors to make sure that Staircase is following required SOC2 controls. Comply returns an offboarding_data_id in the response body. To retrieve the results of the security validation, call Retrieve offboarding Status with the offboarding_data_id. ##### Request application/json Copy ``` { "date_from": "2021-12-01", "admin_name": "Test Name" } ``` ##### Response application/json Copy 200 response ``` { "offboarding_data_id": "9dff4dc3-g700-4fc8-a51a-56d91d7ed7df" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `asana_token` required | `string` header | `1/1199400791141010:f1d4b85a291da54a88e14813a91d4b97` | Authorization Asana Token | | `rippling_token` required | `string` header | `byqVc9P6Woq0gUI01OMovA3o1wzymReZt3rBvwJTHpzaPwhKzW1fU4zzHkPcC3fe` | Authorization rippling Token | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `date_from`required | `string` | Date From. | | `admin_name` | `string` | User admin name from asana | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `offboarding_data_id` | `string` | Offboarding data id, used for get offboarding data | ##### Other responses `400``401``403``404` `GET` `/soc2/offboarding/{offboarding_data_id}` #### Retrieve Offboarding Data `get-soc2-offboarding-data` Get offboarding data Retrieve offboarding data retrieves the results of SOC2 offboarding process for a given offboarding_data_id. ##### Response 200 Succeeded response200 Failed response application/json Copy 200 response ``` { "status": "COMPLIANT", "offboarding_data_id": "91ae0517-c3b9-4709-9f4c-55cb7ac231cd", "offboarding_process": { "offboarding_tasks": [ { "employee_name": "Employee Name", "asana_task": "https://app.asana.com/0/252455/252455588" } ], "missing_tasks": [] } } ``` application/json Copy 200 response ``` { "status": "FAILED", "offboarding_data_id": "91ae0517-c3b9-4709-9f4c-55cb7ac231cd", "offboarding_process": [], "errors": [ { "message": "rippling_token not authorized" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `offboarding_data_id` required | `string` path | `9dff4dc3-f700-4fc8-a51a-56d91d7ed7dg` | Offboarding data id | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `offboarding_data_id` | `string` | Offboarding data id | | `errors` | `object` | Errors | | `status` | `string` | Status of compliance`COMPLIANT``FAILED``FAULT``IN_PROGRESS``NON_COMPLIANT``STOPPED``SUCCEEDED``TIMED_OUT` | | `offboarding_process` | `object` | Offboarding process data | ##### Other responses `400``401``403``404` `POST` `/soc2/onboarding` #### Create Onboarding Data `new-soc2-onboarding-data` Create onboarding data Comply looks into controls required for SOC2 compliance. One of these controls is around on-boarding and off-boarding. As part of this control, there must be tasks for new employees to onboard and get access to different systems such as GitHub, G Suite. Comply integrates with Rippling HR tool and Asana task management tool to retrieve the list of employees and to make sure that there is an onboarding task for them. This endpoint can be used by auditors to make sure that Staircase is following required SOC2 controls. Comply returns an onboarding_data_id in the response body. To retrieve the results of the security validation, call Retrieve Onboarding Status with the onboarding_data_id. ##### Request application/json Copy ``` { "date_from": "2021-12-01" } ``` ##### Response application/json Copy 200 response ``` { "onboarding_data_id": "9dfg4dc3-f700-4fc8-a51a-56d91d7ed7df" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `asana_token` required | `string` header | `1/1199400791141010:f1d4b85a291da54a88e14813a91d4b97` | Authorization Asana Token | | `rippling_token` required | `string` header | `byqVc9P6Woq0gUI01OMovA3o1wzymReZt3rBvwJTHpzaPwhKzW1fU4zzHkPcC3fe` | Authorization rippling Token | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `date_from`required | `string` | Date From. | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `onboarding_data_id` | `string` | Onboarding data id, used for get onboarding data | ##### Other responses `400``401``403``404` `GET` `/soc2/onboarding/{onboarding_data_id}` #### Retrieve Onboarding Data `get-soc2-onboarding-data` Get onboarding data Retrieve onboarding data retrieves the results of SOC2 onboarding process for a given onboarding_data_id. ##### Response 200 Succeeded response200 Failed response application/json Copy 200 response ``` { "status": "COMPLIANT", "onboarding_data_id": "91ae0517-c3b9-4709-9f4c-55cb7ac231cd", "onboarding_process": { "onboarding_tasks": [ { "employee_name": "Employee Name", "asana_task": "https://app.asana.com/0/252455/252455588" } ], "missing_tasks": [] } } ``` application/json Copy 200 response ``` { "status": "FAILED", "onboarding_data_id": "91ae0517-c3b9-4709-9f4c-55cb7ac231cd", "onboarding_process": [], "errors": [ { "message": "rippling_token not authorized" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `onboarding_data_id` required | `string` path | `9dff4dc3-g700-4fc8-a51a-56d91d7ed7df` | Onboarding data id | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `onboarding_data_id` | `string` | Onboarding data id | | `errors` | `object` | Errors | | `status` | `string` | Status of compliance`COMPLIANT``FAILED``FAULT``IN_PROGRESS``NON_COMPLIANT``STOPPED``SUCCEEDED``TIMED_OUT` | | `onboarding_process` | `object` | Onboarding process data | ##### Other responses `400``401``403``404` ### Machine to Machine `DELETE` `/app_client/{product_name}` #### Delete app client `delete-app-client` Delete app client Delete app client for product, To be able to use this API you must have "admin" or "product_engineer" profile ##### Response application/json Copy 200 response ``` { "message": "SUCCEEDED" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Test` | Product Name | | `Authorization` required | `string` header | `123` | Authorization Token | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status process | ##### Other responses `400``401``403``404` `GET` `/app_client/{product_name}` #### Get app client `get-app-client` Get app client Get app client for product, To be able to use this API you must have "admin" or "product_engineer" profile ##### Response application/json Copy 200 response ``` { "client_id": "client-id", "client_secret": "" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Test` | Product Name | | `Authorization` required | `string` header | `123` | Authorization Token | ##### Response `200``application/json` 2 fields 200 response | Field | Type | Description | | --- | --- | --- | | `client_id` | `string` | Client id | | `client_secret` | `string` | Client secret | ##### Other responses `400``401``403``404` `POST` `/app_client/{product_name}` #### Create app client `create-app-client` Create app client Create new app client for product**, To be able to use this API you must have "admin" or "product_engineer" profile ##### Response application/json Copy 200 response ``` { "client_id": "client-id", "client_secret": "" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Test` | Product Name | | `Authorization` required | `string` header | `123` | Authorization Token | ##### Response `200``application/json` 2 fields 200 response | Field | Type | Description | | --- | --- | --- | | `client_id` | `string` | Client id | | `client_secret` | `string` | Client secret | ##### Other responses `400``401``403``404` `POST` `/oauth/validate` #### Validate access token `validate-access-token` Validate access token Validate access token** ##### Response application/json Copy 200 response ``` { "sub": "08b02444-76cf-4644-a058-3e5b623f2620", "identities": "[{\"userId\":\"user@domain.com\",\"providerName\":\"Staircase\",\"providerType\":\"SAML\",\"issuer\":\"https://accounts.google.com/o/saml2?idpid=XXXX22222\",\"primary\":true,\"dateCreated\":1631219658425}]", "email_verified": "false", "profile": "developer", "email": "user@domain.com", "custom:environments_access": "[]", "username": "Staircase_user@domain.com" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Authorization` required | `string` header | `` | Access Token | ##### Other responses `200``400``401``403``404` ## Providers - MeridianLink ## Errors `400``401``403``404``422` ## More in Shipping - Previous product: Code - Next product: Deploy --- # Deploy # Deploy Deploying any bundle to any environment, with retry, skip-if-unchanged, and completion reported to the health surface. A deployment takes a bundle and an environment. It retries on transient failure, cancels cleanly when the platform's code-storage limit is reached rather than half-deploying, and skips entirely when the commit already deployed there. Completion reports to Health, so the record of what is where is a consequence of deploying rather than a separate bookkeeping step. ## How it works The skip is keyed on the commit rather than on a version string. A version can be re-tagged; a commit cannot, so the check answers the actual question — is this exact code already running here. ## Operations ### Foo `POST` `/hello-world` #### Bar `helloWorld` Hello World Dummy hello world endpoint ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | FooExample `Hello, World!` | ### Deployments `POST` `/deployments` #### Deploy Artifact `deployArtifact` #### Deploy Artifact Deploy Artifact deploys a product or configuration artifact_url to a specific environment using only environment token from Environment product to provide information about the environment which is the final target of the deployment. ##### Limitations on Deployment - Deployment which handled by lambda worker supports up to 3 GB artifact size. - Deployment retries deployment up to 5 times if Deployer receives service error or throttling error. - Deployer will cancel deployment if lambda code storage hit %99 percent. The code storage percentage cache TTL is 10 minutes. ##### Legacy deployment - By default, the Deploy uses the new deployment strategy via StepFunctions. If you want to use the legacy deployment strategy via CodeBuild, you can enable it by passing `legacy_deploy` as true in the request body. - The legacy deployment strategy is deprecated and will be removed in the future. - The legacy deployment strategy is slower than the new deployment strategy. ##### Force Deployment Deployer skips product deployment based on the following conditions: Show the rest - The Last deployment should be successful. - The last deployment commit SHA should match the current bundle commit SHA. This indicates there is no code change in the given bundle. Note: This behavior does not apply to configuration bundles. Configuration bundle deployments will be executed on every attempt. This behavior can be changed by forcing the Deployer to execute deployment with the following options: 1. Updating `service.yml` ``` deployment: force_deployment: true ``` 1. Giving `force_deployment` parameter in the request body. Note: Parameter in request body overrides `service.yml` configuration. The deployment process will report to the Health after deployment finished or failed. The following health metric parameters will be sent: product_identifier: Taken from product_identifier field in the frontend bundles. Support for other bundles coming soon. product_api_identifier: always `be5bed79-df72-4a56-b77c-5c12d4e21d8e` status: "SUCCEEDED" or "FAILED" The deployment accepts optional parameter for transaction ID. If not provided, the deployment will create the transaction for the deployment.. The deployment process will persist following data into collection: Deployment status, `Failed` or `Succeeded`. Start time and end time of deployment. Bundle type of the deployment. `Service`, `Chat`, `FrontEnd`, `Data`. Example of the collection: ``` { "metadata": { "fuzzy_searchable": false, "version": 3, "validation": true, "serialise_to_graph": true }, "data": { "bundles": [ { "@type": "bundle", "@id": "bundle_id", "bundle_type": "Service", "base_path": "your-base-path", "has_product": "p_id" } ], "products": [ { "@id": "p_id", "@type": "product", "name": "MyProductName" }, { "@id": "p_id_2", "@type": "product", "name": "Deploy", "product_identifier": "229c0982-b5fe-4d4c-8f9e-80ad38f5d4b8", "has_product_api": "product_api_id" } ], "deployments": [ { "deployment_status_type": "Succeeded", "@type": "deployment", "@id": "depl_id", "has_invocation": "inv_id", "has_bundle": "bundle_id", "start_time": "2024-05-16T05:41:07.868339-04:00", "end_time": "2024-05-16T05:41:07.868339-04:00" } ], "product_apis": [ { "@type": "product_api", "@id": "product_api_id", "name": "Deployment", "product_api_identifier": "a1257a35-5261-4293-9747-2e958c56f53c" } ], "invocations": [ { "@type": "invocation", "invocation_message": "my-deployment-id", "@id": "inv_id", "has_product_api": "product_api_id" } ] } } ``` ##### Request FullExampleMinimalExampleParallelDeploymentExample application/json Copy ``` { "bundle_id": "e00feb67-f6d7-46e4-95a-52375ece86ef", "transaction_id": "01HY0C4V3JS796NF9FXWDDNXT4", "artifacts_url": "https://example.com/artifact.zip", "environment_token": "rWiaN6NN6l0RPrrmM6he3QABhqCAAAAAAGBkJt205xbT9RPaH4kyB2JcGic4f-8vjZCIU7NZE8hVE2Trw6gqsDm0V7OMqST--jJUM3ri24BvyRYrI2EolmyWWKPNGlpVaA7", "callback_url": "https://example.com/call-me-back-please" } ``` application/json Copy ``` { "artifacts_url": "https://example.com/artifact.zip", "environment_token": "rWiaN6NN6l0RPrrmM6he3QABhqCAAAAAAGBkJt205xbT9RPaH4kyB2JcGic4f-8vjZCIU7NZE8hVE2Trw6gqsDm0V7OMqST--jJUM3ri24BvyRYrI2EolmyWWKPNGlpVaA7" } ``` application/json Copy ``` { "environment_token": "env_token", "artifacts_url": "https://example.com/artifact.zip", "callback_url": "https://example.com/call-me-back-please" } ``` ##### Response 200 SuccessfulExample200 SuccessfulParallelDeploymentExample400 application/json Copy Deployment started. ``` { "deploy_id": "devops-deployer-dev:490f5d55-2ea4-47b5-81cb-38a54a01f2af", "bundle_id": "e00feb67-f6d7-46e4-95a-52375ece86ef", "transaction_id": "01HY0C4V3JS796NF9FXWDDNXT4" } ``` application/json Copy Deployment started. ``` { "deploy_id": "948d0a4b-f228-4f88-b6be-b62627e1c2fd", "bundle_id": "1906999e-af6a-41eb-92a4-0f9545abd3b8", "transaction_id": "01HY0C4V3JS796NF9FXWDDNXT4" } ``` application/json Copy Parameter validation error ``` { "artifacts_url": [ "Missing data for required field." ], "environment_token": [ "Missing data for required field." ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 9 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Valid transaction ID from the Persistence product. | | `bundle_id` | `string (uuid)` | Any UUID. | | `environment_token`required | `string` | Token from Environment product. | | `artifacts_url`required | `string (uri)` | Link to the artifacts zip file. Content of artifacts file described in Artifacts content section. Deployer will download artifacts from artifacts_url, and deploy them.Example `https://example.com/artifact.zip` | | `callback_url` | `string (uri)` | (Optional) When deployment is done, POST to this API information about deployment. If a transient error is returned from callback deploy will retry 10 times to call callback using exponential back off algorithm. Transient error means either: a timeout, an FTP 5xx response code or an HTTP 5xx response code.Example `https://example.com/call-me-back-please` | | `log_level` | `string` | Log level, that is used in deployment process. Can be used with \"DEBUG\" value for Deploy product debugging.`DEBUG``INFO`Example `INFO` | | `force_deployment` | `boolean` | This allows Deployer to force execute deployment.Example `true` | | `legacy_deploy` | `boolean` | Use legacy deployment strategy via CodeBuild. This option is deprecated and will be removed in the future.Example `false` | | `configuration` | `object` | This option configures deployment and is only effective when legacy_deploy disabled. | | `limit_check_on_pre_deployment` | `string` | Enables AWS quota and limit check before deployment.Example `true` | | `parallel_module_deployment` | `string` | Allows configuring parallel or sequential module deployment. Sequential deployment is important when module deployment order matters. This option is valid only for legacy_deploy deployment disabled.Example `true` | ##### Response `200``application/json` 3 fields Deployment started. | Field | Type | Description | | --- | --- | --- | | `deploy_id` | `string` | ID of the deployment.Example `devops-deployer-dev:490f5d55-2ea4-47b5-81cb-38a54a01f2af` | | `bundle_id` | `string (uuid)` | Usually a hash of the commit but can be any UUID. | | `transaction_id` | `string` | The transaction ID. | ##### Response `400``application/json` 2 fields Parameter validation error | Field | Type | Description | | --- | --- | --- | | `artifacts_url` | `string[]` | Artifact URL errors | | `environment_token` | `string[]` | Environment token errors | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` `GET` `/deployments/{bundle_id}` #### Retrieve Deployment Status `retrieveDeploymentStatus` Retrieve Deployment Metadata retrieves metadata generated by the deployment. - Metadata is available only for deployments that succeed (deploy_status==SUCCEEDED). - The artifact_url key in the response body contains the URL to the artifact that was deployed. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new artifact_url. - The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service are considered service metadata. ##### Response 200 SuccessfulDeployment200 FailedDeployment200 ParallelDeployment application/json Copy 200 response ``` { "deploy_status": "SUCCEEDED", "metadata": { "target_url": "https://sandbox.api.staircaseapi.com/code-assessor/", "code": { "id": "4ad1c152-4990-45b4-a2ab-f0d31d1fc303", "timestamp": 1611753194.053118, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "31e47b3e883cec9c46c435d57c58565e1f73b3a8", "issuer": "https://deploy.staircaseapi.com/code" }, "builder": { "id": "f128507e-21c1-4dd8-b6bc-7bb0d220eeb8", "timestamp": 1611753314.9771907, "version": "1.1", "status": "SUCCEEDED", "issuer": "https://api.staircaseapi.com/infra-builder" }, "deployer": { "id": "032e2794-7aa8-4e3a-912b-605f5c370913", "timestamp": 1611753374.9128177, "version": "1.1", "status": "SUCCEEDED", "issuer": "https://deploy.staircaseapi.com/infra-deployer/" } }, "artifact_url": "https://deployer-dev-artifcatsbucket-1freahxorpmya.s3.amazonaws.com/build_artifacts/00c5f4ab-d3d4-4cd9-bc9d-eefe8b6b1c26/devops-deployer-dev/artifacts.zip?AWSAccessKeyId=&Signature=&Expires=1611832432", "logs": [ "[Container] 2020/12/14 16:24:03 Waiting for agent ping\n", "[Container] 2020/12/14 16:24:05 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2020/12/14 16:24:06 Phase is DOWNLOAD_SOURCE\n", "[Container] 2020/12/14 16:24:06 CODEBUILD_SRC_DIR=/codebuild/output/src405111012/src\n", "[Container] 2020/12/14 16:24:06 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2020/12/14 16:24:06 No commands found for phase name: install\n", "[Container] 2020/12/14 16:24:06 Processing environment variables\n", "[Container] 2020/12/14 16:24:06 Selecting 'python' runtime version '3.8' based on manual selections...\n", "[Container] 2020/12/14 16:24:06 Running command echo \"Installing Python version 3.8 ...\"\n", "Installing Python version 3.8 ...\n", "\n", "[Container] 2020/12/14 16:24:06 Running command pyenv global $PYTHON_38_VERSION\n", "\n", "[Container] 2020/12/14 16:24:07 Moving to directory /codebuild/output/src405111012/src\n", "[Container] 2020/12/14 16:24:07 Registering with agent\n", "[Container] 2020/12/14 16:24:07 Phases found in YAML: 2\n", "[Container] 2020/12/14 16:24:07 INSTALL: 0 commands\n", "[Container] 2020/12/14 16:24:07 BUILD: 6 commands\n", "[Container] 2020/12/14 16:24:07 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2020/12/14 16:24:07 Phase context status code: Message:\n", "[Container] 2020/12/14 16:24:07 Entering phase INSTALL\n", "[Container] 2020/12/14 16:24:07 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2020/12/14 16:24:07 Phase context status code: Message:\n", "[Container] 2020/12/14 16:24:07 Entering phase PRE_BUILD\n", "[Container] 2020/12/14 16:24:07 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2020/12/14 16:24:07 Phase context status code: Message:\n", "[Container] 2020/12/14 16:24:07 Entering phase BUILD\n", "[Container] 2020/12/14 16:24:07 Running command curl -sS \"\"$HOST\"infra-deployer/deploy.py\" --output deploy.py\n", "\n", "[Container] 2020/12/14 16:24:10 Running command curl -sS $ARTIFACTS_URL --output artifacts.zip\n", "\n", "[Container] 2020/12/14 16:24:11 Running command unzip -qq artifacts.zip -d build_folder\n", "\n", "[Container] 2020/12/14 16:24:11 Running command printf \"$ACCESS_KEY\\n$SECRET_KEY\\nus-east-1\\njson\" > creds.txt\n", "\n", "[Container] 2020/12/14 16:24:11 Running command aws configure < creds.txt\n", "AWS Access Key ID [None]: AWS Secret Access Key [None]: Default region name [None]: Default output format [None]:\n", "[Container] 2020/12/14 16:24:16 Running command python3.8 deploy.py build_folder\n", "2020-12-14 16:24:17,684 Found credentials in shared credentials file: ~/.aws/credentials\n", "2020-12-14 16:24:18,007 Creating bucket 2b7d31ed-7ff3-4da8-9ad9-324f40bf41a0\n", "2020-12-14 16:24:18,323 Bucket created\n", "2020-12-14 16:24:18,324 Uploading artifacts\n", "2020-12-14 16:24:18,574 Artifacts uploaded\n", "2020-12-14 16:24:18,574 Deployment started\n", "2020-12-14 16:25:30,449 Deployed\n", "2020-12-14 16:25:30,449 Removing bucket 2b7d31ed-7ff3-4da8-9ad9-324f40bf41a0\n", "2020-12-14 16:25:31,128 Bucket removed\n", "\n", "[Container] 2020/12/14 16:25:31 Running command if [ \"$CALLBACK_URL\" != \"null\" ]; then\n", "\n if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then\n", "\n curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'\n", "\n else\n", "\n curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'\n", "\n fi\n", "fi\n", "", "\n % Total % Received % Xferd Average Speed Time Time Time Current\n", "\n Dload Upload Total Spent Left Speed\n", "\r 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0\r 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0\r100 75 0 0 100 75 0 247 --:--:-- --:--:-- --:--:-- 246\n", "\n", "[Container] 2020/12/14 16:25:31 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2020/12/14 16:25:31 Phase context status code: Message:\n", "[Container] 2020/12/14 16:25:31 Entering phase POST_BUILD\n", "[Container] 2020/12/14 16:25:31 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2020/12/14 16:25:31 Phase context status code: Message:\n", "[Container] 2020/12/14 16:25:31 Expanding base directory path: .\n", "[Container] 2020/12/14 16:25:31 Assembling file list\n", "[Container] 2020/12/14 16:25:31 Expanding .\n", "[Container] 2020/12/14 16:25:31 Expanding file paths for base directory .\n", "[Container] 2020/12/14 16:25:31 Assembling file list\n", "[Container] 2020/12/14 16:25:31 Expanding deploy_output.json\n", "[Container] 2020/12/14 16:25:31 Found 1 file(s)\n", "[Container] 2020/12/14 16:25:31 Phase complete: UPLOAD_ARTIFACTS State: SUCCEEDED\n", "[Container] 2020/12/14 16:25:31 Phase context status code: Message:\n" ] } ``` application/json Copy 200 response ``` { "deploy_status": "FAILED", "metadata": null, "artifact_url": null, "logs": [ "[Container] 2020/12/14 16:55:13 Waiting for agent ping\n", "[Container] 2020/12/14 16:55:15 Waiting for DOWNLOAD_SOURCE\n", "[Container] 2020/12/14 16:55:16 Phase is DOWNLOAD_SOURCE\n", "[Container] 2020/12/14 16:55:16 CODEBUILD_SRC_DIR=/codebuild/output/src092437202/src\n", "[Container] 2020/12/14 16:55:16 YAML location is /codebuild/readonly/buildspec.yml\n", "[Container] 2020/12/14 16:55:16 No commands found for phase name: install\n", "[Container] 2020/12/14 16:55:16 Processing environment variables\n", "[Container] 2020/12/14 16:55:16 Selecting 'python' runtime version '3.8' based on manual selections...\n", "[Container] 2020/12/14 16:55:16 Running command echo \"Installing Python version 3.8 ...\"\n", "Installing Python version 3.8 ...\n", "\n", "[Container] 2020/12/14 16:55:16 Running command pyenv global $PYTHON_38_VERSION\n", "\n", "[Container] 2020/12/14 16:55:16 Moving to directory /codebuild/output/src092437202/src\n", "[Container] 2020/12/14 16:55:16 Registering with agent\n", "[Container] 2020/12/14 16:55:16 Phases found in YAML: 2\n", "[Container] 2020/12/14 16:55:16 INSTALL: 0 commands\n", "[Container] 2020/12/14 16:55:16 BUILD: 6 commands\n", "[Container] 2020/12/14 16:55:16 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED\n", "[Container] 2020/12/14 16:55:16 Phase context status code: Message:\n", "[Container] 2020/12/14 16:55:16 Entering phase INSTALL\n", "[Container] 2020/12/14 16:55:16 Phase complete: INSTALL State: SUCCEEDED\n", "[Container] 2020/12/14 16:55:16 Phase context status code: Message:\n", "[Container] 2020/12/14 16:55:16 Entering phase PRE_BUILD\n", "[Container] 2020/12/14 16:55:16 Phase complete: PRE_BUILD State: SUCCEEDED\n", "[Container] 2020/12/14 16:55:16 Phase context status code: Message:\n", "[Container] 2020/12/14 16:55:16 Entering phase BUILD\n", "[Container] 2020/12/14 16:55:16 Running command curl -sS \"\"$HOST\"infra-deployer/deploy.py\" --output deploy.py\n", "\n", "[Container] 2020/12/14 16:55:20 Running command curl -sS $ARTIFACTS_URL --output artifacts.zip\n", "\n", "[Container] 2020/12/14 16:55:20 Running command unzip -qq artifacts.zip -d build_folder\n", "[artifacts.zip]\n", "\n End-of-central-directory signature not found. Either this file is not\n", "\n a zipfile, or it constitutes one disk of a multi-part archive. In the\n", "\n latter case the central directory and zipfile comment will be found on\n", "\n the last disk(s) of this archive.\n", "unzip: cannot find zipfile directory in one of artifacts.zip or\n", "\n artifacts.zip.zip, and cannot find artifacts.zip.ZIP, period.\n", "\n", "[Container] 2020/12/14 16:55:20 Command did not exit successfully unzip -qq artifacts.zip -d build_folder exit status 9\n", "[Container] 2020/12/14 16:55:20 Running command if [ \"$CALLBACK_URL\" != \"null\" ]; then\n", "\n if [ \"$CODEBUILD_BUILD_SUCCEEDING\" = \"1\" ]; then\n", "\n curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"SUCCEEDED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'\n", "\n else\n", "\n curl --request POST $CALLBACK_URL --header 'Content-Type: application/json' --data '{\"status\": \"FAILED\",\"bundle_id\": \"'$BUNDLE_ID'\"}'\n", "\n fi\n", "fi\n", "\n", "[Container] 2020/12/14 16:55:20 Phase complete: BUILD State: FAILED\n", "[Container] 2020/12/14 16:55:20 Phase context status code: COMMAND_EXECUTION_ERROR Message: Error while executing command: unzip -qq artifacts.zip -d build_folder. Reason: exit status 9\n", "[Container] 2020/12/14 16:55:20 Entering phase POST_BUILD\n", "[Container] 2020/12/14 16:55:20 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2020/12/14 16:55:20 Phase context status code: Message:\n", "[Container] 2020/12/14 16:55:20 Expanding base directory path: .\n", "[Container] 2020/12/14 16:55:20 Assembling file list\n", "[Container] 2020/12/14 16:55:20 Expanding .\n", "[Container] 2020/12/14 16:55:20 Expanding file paths for base directory .\n", "[Container] 2020/12/14 16:55:20 Assembling file list\n", "[Container] 2020/12/14 16:55:20 Expanding deploy_output.json\n", "[Container] 2020/12/14 16:55:20 Skipping invalid file path deploy_output.json\n", "[Container] 2020/12/14 16:55:20 Phase complete: UPLOAD_ARTIFACTS State: FAILED\n", "[Container] 2020/12/14 16:55:20 Phase context status code: CLIENT_ERROR Message: no matching artifact paths found\n" ] } ``` application/json Copy 200 response ``` { "bundle_id": "225b1744-2b9f-4861-b8b5-55bf4dd0726f", "deploy_id": "fb27c142-5421-4f51-8a5d-bb5078e6e7c6", "metadata": { "assessor": { "id": "877c9b30-8179-4719-855b-2206984a34e2", "timestamp": 1653058579.240083, "version": "1.0.12", "issuer": "https://template.staircaseapi.com/code-assessor", "status": "SUCCEEDED", "applied_rules": 39, "version_hash": "635c7ac814f451e200f8ce55462a576600767300da6539cf77deaa056397c670" }, "code": { "id": "f1321002-9f83-46a7-8eb5-ab8db6f5d197", "timestamp": 1653058526.3055882, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "d8300821be61e603f549747dd0c44350069f1f9f", "issuer": "https://template.staircaseapi.com/code" }, "builder": { "id": "d126a1d2-b222-4ab7-8880-e66737cbb79d", "timestamp": 1653058800.9849484, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://template.staircaseapi.com/infra-builder" }, "deployer": { "id": "fb27c142-5421-4f51-8a5d-bb5078e6e7c6", "timestamp": 1653059651.2567577, "version": "1.1", "status": "SUCCEEDED", "issuer": "https://template.staircaseapi.com/infra-deployer/" } }, "deploy_status": "SUCCEEDED", "bundle_details": [ { "created_at": "2022-05-20:15:14:14", "status": "SUCCEEDED", "finished_at": "2022-05-20:15:14:33", "stack_id": "arn:aws:cloudformation:us-east-1:111122222:stack/deployer-dev/4d607ab0-69f3-11eb-99cd-0ae749a35905", "cf_status": "UPDATE_COMPLETE", "bundle_id": "225b1744-2b9f-4861-b8b5-55bf4dd0726f" }, { "created_at": "2022-05-20:15:13:53", "deploy_id": "fb27c142-5421-4f51-8a5d-bb5078e6e7c6", "status": "REQUEST_MADE", "stack_id": "root", "callback_url": "callback_url", "bundle_id": "225b1744-2b9f-4861-b8b5-55bf4dd0726f" } ] } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `bundle_id` required | `string (uuid)` path | `e00feb67-f6d7-46e4-95a-52375ece86ef` | Usually a hash of the commit but can be any UUID. | ##### Response `200``application/json` 5 fields 200 response | Field | Type | Description | | --- | --- | --- | | `deploy_status` | `string` | Deploy status can be SUCCEEDED'|'FAILED'|'FAULT'|'TIMED_OUT'|'IN_PROGRESS'|'STOPPED.`FAILED``FAULT``IN_PROGRESS``STOPPED``SUCCEEDED``TIMED_OUT` | | `metadata` | `object` | Metadata | | `target_url` | `string (uri)` | Target URLExample `https://sandbox.api.staircaseapi.com/code-assessor/` | | `artifact_url` | `string (uri)` | URL of deployed artifact, with proper metadata in headers. | | `logs` | `string[]` | Logs of deployment. | | `bundle_details` | `object[]` | Bundle deployment details | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `409``application/json` 1 fields Request could not be processed because of conflict in the current state of the resource | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `400``422` `GET` `/deployments/logs/{response_collection_id}` #### Retrieve Deployment Logs `retrieveDeploymentLogs` Retrieve Deployment Logs retrieves logs and stack traces if an exception occurred during deployment. This endpoint is reachable with an API key and health key. #### Limitations: - Logs have 7 days TTL. ##### Response application/json Copy 200 response ``` [ { "response_collection_id": "225b1744-2b9f-4861-b8b5-55bf4dd0726f", "product_api_identifier": "11225b1744-239f-4861-b8b5-55bf4dd072", "transaction_id": "fb27c142-5421-4f51-8a5d-bb5078e6e7c6", "stack_trace": "stack_trace_value", "created_at": "2022-12-01:07:23:07", "expire_at": 1670484187 } ] ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `response_collection_id` required | `string (uuid)` path | `e00feb67-f6d7-46e4-95a-52375ece86ef` | The value of response collection_id. | | `product_api_identifier` | `string` query | `11225b1744-239f-4861-b8b5-55bf4dd072` | Product API identifier | ##### Response `200``application/json` 6 fields 200 response | Field | Type | Description | | --- | --- | --- | | `response_collection_id` | `string` | Response collection identifier. | | `product_api_identifier` | `string` | Product API identifier. | | `transaction_id` | `string` | Transaction identifier | | `stack_trace` | `string` | Execution stack trace | | `created_at` | `string` | Log creation date. | | `expire_at` | `number` | Log expiration specifier. | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `409``application/json` 1 fields Request could not be processed because of conflict in the current state of the resource | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `400``422` ### Operations `GET` `/deployments/{deployId}` #### Get deploy status `Getdeploy` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `deployId` required | `string` path | ID of deploy, looks like 5f0631cd1487f8000897e143 | ##### Other responses `200` `POST` `/deploymentStrategies/blue-green/execute` #### Redeploy `Redeploy` ##### Request application/json Copy ``` { "applicationName": "app", "oldDeployId": "5efb0e03b61e2500082c8292", "revisionLocation": "s3://staircase-poc/GreenDeploy_Linux.zip" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `applicationName`required | `string` | — | | `oldDeployId`required | `string` | — | | `revisionLocation`required | `string` | — | ##### Other responses `200` ## Errors `400``403``404``409``422` ## More in Shipping - Previous product: Comply - Next product: Health --- # Health # Health Per-transaction metrics, cost metrics, and a per-partner performance report carrying vendor success rate and cost. Every invocation reports timing, outcome and cost. The surface serves that back as transaction metrics, cost metrics, custom report templates, and the public status view. The per-partner report carries success rate and cost per vendor, which is the measurement a waterfall ordering is retuned from — the ordering is only as good as the evidence that a vendor is answering. ## How it works Vendor performance was reported from the beginning rather than added once someone asked. That is the difference between a waterfall as an idea and a waterfall that can be tuned: without per-vendor success and cost, the order is a guess that nobody can correct. ## Operations ### Status `POST` `/` #### Update status `updateHealthStatus` Update product status ##### Request application/json Copy ``` { "product_id": "test_product", "product_api_id": "test_api", "environment_fqdn": "test_env.example.com", "available": true } ``` ##### Response 200400 application/json Copy Successfully updated product status ``` { "product_id": "test_product", "status": "operational" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `product_id`required | `string` | Product ID | | `status`required | `string` | Status | ##### Response `200``application/json` 2 fields Successfully updated product status | Field | Type | Description | | --- | --- | --- | | `product_id`required | `string` | Category | | `status`required | `string` | Status`major_outage``operational``partial_outage` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/{product_id}` #### Retrieve status `getHealthStatus` Get product status Get product availability status ##### Response 200400404 application/json Copy Successfully fetched product status ``` { "product_id": "test_product", "status": "operational" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_id` required | `string` path | `01GYWNA8PJX5A41WA48PZNV5Y4` | Product ID | ##### Response `200``application/json` 2 fields Successfully fetched product status | Field | Type | Description | | --- | --- | --- | | `product_id`required | `string` | Category | | `status`required | `string` | Status`major_outage``operational``partial_outage` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Metric Alarm Events `GET` `/alarms/events` #### List Metric Alarm Events `list_metric_alarm_events` This service returns a list of occurred alarm events. NOTE: Alarm events have one week retention period. Events that passed the retention period will be deleted. ##### Response 200400 error response400 text/html404 application/json Copy Ok. ``` { "events": [ { "expire_at": 1663939815, "event_id": "2f9e3499-8e5d-4003-b524-ed23aca2ac38", "metric_data": { "transaction_id": "01GD37M86FM1AZ2QXQ243NDKHE", "product_identifier": "c72b3b7c-dc30-41d0-81d3-3d3889370ef2", "product_api_identifier": "77958f4b-7158-42d0-adbd-22e2b74fe0c9", "invocation_code": "2000", "elapsed_time": 147.4666051864624, "created_at": "2022-09-16 09:30:13", "response_collection_id": "d4f48c0f-6560-4da9-8c8d-a54d10d22d7e", "id": "37e9b907-ef5b-4e54-b782-de1e64259a80", "configuration_id": "e1b96c6d-d24e-459c-ae8a-ec460df3de8f", "product_build_hash": "f144ef21958ba7cde95a9bbd5372ec99605af106", "host_environment": "health.staircaseapi.com", "status": "SUCCEEDED" }, "created_at": "2022-09-16T09:30:13", "alarm_id": "alarm_id_1" } ], "next_token": null } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `alarm_id` required | `string` query | `product_identifier_1` | Alarm ID | | `start_date` required | `string` query | `2022-01-01T00:00:00` | Start date in ISO format | | `end_date` required | `string` query | `2022-01-01T01:01:01` | End date in ISO format | | `next_token` | `string` query | `eyJwcm9kdWN0X25hbWUiOiAiQnVpbGQiLCAiY3JlYXRlZF9hdCI6ICIyMDIxLTA2LTA0VDE0OjU5OjE5LjU3MTg3OSJ9` | The token for the next set of items to return. | | `limit` | `string` query | `150` | The number of results to return in this request | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `events` | `object[]` | List of events | | `alarm_id` | `string` | Alarm IDExample `alarm_id_1` | | `event_id` | `string` | Event IDExample `event_id_1` | | `created_at` | `string` | Event creation date.Example `2022-09-16T09:30:13` | | `expire_at` | `integer` | Event item expiration timestamp.Example `1663939815` | | `metric_data` | `object` | Metric payload | | `id` | `string` | Metric IDExample `37e9b907-ef5b-4e54-b782-de1e64259a80` | | `host_environment` | `string` | Metric host environmentExample `health.staircaseapi.com` | | `product_identifier` | `string` | Product IdentifierExample `c72b3b7c-dc30-41d0-81d3-3d3889370ef2` | | `product_api_identifier` | `string` | Product API identifierExample `77958f4b-7158-42d0-adbd-22e2b74fe0c9` | | `transaction_id` | `string` | Transaction IDExample `01GD37M86FM1AZ2QXQ243NDKHE` | | `response_collection_id` | `string` | Response collection IDExample `d4f48c0f-6560-4da9-8c8d-a54d10d22d7e` | | `elapsed_time` | `number` | Elapsed timeExample `147.46` | | `status` | `string` | StatusExample `SUCCEEDED` | | `invocation_code` | `string` | Invocation codeExample `2000` | | `configuration_id` | `string` | Product configuration IDExample `e1b96c6d-d24e-459c-ae8a-ec460df3de8f` | | `product_build_hash` | `string` | Product build hashExample `f144ef21958ba7cde95a9bbd5372ec99605af106` | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Metric Alarms `POST` `/alarms/metric` #### Create Metric Alarm `create_metric_alarms` #### Metric Alarm Health alarms provide real-time alerts based on a given condition. If you want to be notified when an alert event has occurred, you can select a destination option. You are able to select one or more destination channels from the available options. ##### Condition Health alarms are generated based on given conditions. ##### Destinations Notification can be delivered after the alert event has occurred. Destinations are notification channels for alert delivery. One or more notification channels can be selected ex: Slack, and Webhook. - Slack: Slack integration requires a slack token that belongs to Slack apps. Please create a new application by using Slack API. After application creation, go to channel configuration and add created Slack app as an integration using "Apps" section in the "Integrations" tab. ##### Request Create Metric AlarmAlarm Only If campaign_id is present in metric application/json Copy ``` { "alarm_id": "alarm_id_1", "condition": { "product_identifier": "product_identifier_1", "product_api_identifiers": [ "product_api_identifier_1" ] }, "destinations": [ { "type": "SLACK", "slack_channel": "slack_channel_1", "slack_token": "slack_token_1", "slack_usergroup_id": "S03TW2A7A3U" }, { "type": "WEBHOOK", "url": "https://webhook.com" } ] } ``` application/json Copy ``` { "alarm_id": "alarm_id_1", "condition": { "product_identifier": "product_identifier_1", "required_properties": [ "campaign_id" ] }, "destinations": [ { "type": "SLACK", "slack_channel": "slack_channel_1", "slack_token": "slack_token_1", "slack_usergroup_id": "S03TW2A7A3U" }, { "type": "WEBHOOK", "url": "https://webhook.com" } ] } ``` ##### Response 201400 application/json400 text/html404 application/json Copy Success response. ``` { "message": "migration configuration created" } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `alarm_id`required | `string` | Unique alarm ID | | `condition`required | `object` | Alarm filter configuration | | `host_environment` | `string` | Host environment | | `product_identifier`required | `string` | Product identifier | | `product_api_identifiers` | `string[]` | List of product api identifiers | | `configuration_ids` | `string[]` | List of product configuration ID | | `statuses` | `string[]` | List of status | | `invocation_codes` | `string[]` | List of invocation codes | | `product_build_hash` | `string` | Product build hash | | `elapsed_time_above` | `number` | Filters metrics which has elapsed time above | | `elapsed_time_below` | `number` | Filters metrics which has elapsed time below | | `required_properties` | `string[]` | List of required properties | | `destinations`required | `array` | List of alarm destinations | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message response | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `PUT` `/alarms/metric/{alarm_id}` #### Update Metric Alarm `update_metric_alarm` This service updates metric alarm. ##### Request application/json Copy ``` { "condition": { "product_identifier": "product_identifier_1", "product_api_identifiers": [ "product_api_identifier_1" ] }, "destinations": [ { "type": "SLACK", "slack_channel": "slack_channel_1", "slack_token": "slack_token_1" }, { "type": "WEBHOOK", "url": "https://webhook.com" } ] } ``` ##### Response 201400 application/json400 text/html404 application/json Copy Success response. ``` { "message": "migration configuration updated" } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `x-api-key` required | `string` header | `` | API key | | `alarm_id` required | `string` path | `alarm_id_1` | Unique alarm ID | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `condition`required | `object` | Alarm filter configuration | | `host_environment` | `string` | Host environment | | `product_identifier`required | `string` | Product identifier | | `product_api_identifiers` | `string[]` | List of product api identifiers | | `statuses` | `string[]` | List of status | | `invocation_codes` | `string[]` | List of invocation codes | | `configuration_ids` | `string[]` | List of product configuration ID | | `product_build_hash` | `string` | Product build hash | | `elapsed_time_above` | `number` | Filters metrics which has elapsed time above | | `elapsed_time_below` | `number` | Filters metrics which has elapsed time below | | `slack_usergroup_id` | `string` | Slack usergroup id. Use this to tag your team group in the slack message. This ID ALWAYS starts with S and is followed by 9 characters.Example `slack_usergroup_id_1` | | `required_properties` | `string[]` | List of required properties | | `destinations`required | `array` | List of alarm destinations | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message response | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `GET` `/alarms/metric` #### List Metric Alarms `list_metric_alarms` This service returns list of metric alarms. ##### Response 200400 error response400 text/html404 application/json Copy Ok. ``` { "alarms": [ { "destinations": [ { "type": "SLACK", "slack_channel": "slack_channel_1", "slack_token": "slack_token_1" } ], "alarm_id": "alarm_id_1", "condition": { "product_api_identifiers": [ "product_api_identifier_1" ], "product_identifier": "product_identifier_1" } } ] } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `product_identifier` | `string` query | `product_identifier_1` | Filters by product identifier | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `alarms` | `object[]` | Configurations | | `alarm_id` | `string` | Unique configuration name. Value can be alphanumeric and underscore characters only.Example `test_configuration` | | `condition` | `object` | Target environment API key | | `host_environment` | `string` | Host environmentExample `health.staircaseapi.com` | | `product_identifier` | `string` | Product identifierExample `ccd6b8dd-02a7-4c64-a983-7e0c108cd666` | | `product_api_identifiers` | `array` | List of api identifiers | | `statuses` | `array` | List of status | | `invocation_codes` | `array` | List of invocation codes | | `configuration_ids` | `array` | List of configuration ID | | `product_build_hash` | `string` | Product build hash | | `elapsed_time_above` | `number` | Elapsed time above filterExample `5` | | `elapsed_time_below` | `number` | Elapsed time below filterExample `10` | | `destinations` | `array` | List of alarm destinations | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `GET` `/alarms/metric/{alarm_id}` #### Get Metric Alarm `get_metric_alarms` This service returns metric alarms. ##### Response 200400 error response400 text/html404 application/json Copy Ok. ``` { "destinations": [ { "type": "SLACK", "slack_channel": "slack_channel_1", "slack_token": "slack_token_1" } ], "alarm_id": "alarm_id_1", "condition": { "product_api_identifiers": [ "product_api_identifier_1" ], "product_identifier": "product_identifier_1" } } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `x-api-key` required | `string` header | `` | API key | | `alarm_id` required | `string` path | `alarm_id_1` | Unique alarm ID | ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `alarm_id` | `string` | Unique configuration name. Value can be alphanumeric and underscore characters only.Example `test_configuration` | | `condition` | `object` | Target environment API key | | `host_environment` | `string` | Host environmentExample `health.staircaseapi.com` | | `product_identifier` | `string` | Product identifierExample `ccd6b8dd-02a7-4c64-a983-7e0c108cd666` | | `product_api_identifiers` | `array` | List of api identifiers | | `statuses` | `array` | List of status | | `invocation_codes` | `array` | List of invocation codes | | `configuration_ids` | `array` | List of configuration ID | | `product_build_hash` | `string` | Product build hash | | `elapsed_time_above` | `number` | Elapsed time above filterExample `5` | | `elapsed_time_below` | `number` | Elapsed time below filterExample `10` | | `destinations` | `array` | List of alarm destinations | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `DELETE` `/alarms/metric/{alarm_id}` #### Delete Metric Alarm `delete_metric_alarm` This service deletes metric alarm. ##### Response 200400 error response400 text/html404 application/json Copy Ok. ``` { "message": "migration configuration deleted" } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `x-api-key` required | `string` header | `` | API key | | `alarm_id` required | `string` path | `alarm_id_1` | Unique alarm ID | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Unique configuration nameExample `test_configuration` | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Custom Reports `POST` `/build-report` #### Create Custom Report `create_custom_report` Build a custom report using the metrics posted for any product or custom-created metric types. Build a custom report using the metrics posted for any product or custom-created metric types. Define the fields to retrieve, the filters to apply, and the aggregation if needed. The report data to retrieve can be defined in two ways: - Aggregated:Providing the aggregation function, aggregation_fields and group_by will allow to bring the results aggregated. - Detailed:Specify the fields and filters to retrieve detailed metrics data. ##### Request Examples - Detailed reportExample - Aggregated application/json Copy ``` { "get": [ "product_name", "status", "transaction_id", "request_collection_id", "response_collection_id", "operation_status", "partner_name", "severity", "service_endpoint" ], "filters": { "product_name": [ "Health", "Account" ], "status": [ "succeeded" ], "host_env": [ "health.staircaseapi.com" ] }, "report_name": "report_to_create_name", "metric_type": "performance" } ``` application/json Copy ``` { "get": [ "product_name", "service_endpoint", "status" ], "filters": { "product_name": [ "Health" ] }, "aggregation": "count", "aggregation_field": "transaction_id", "group_by": [ "product_name", "service_endpoint", "status" ], "report_name": "report_to_create_name", "metric_type": "performance" } ``` ##### Response 201400 0400 text/html403502 application/json Copy Success Response ``` { "message": "the custom report was successfully created" } ``` application/json Copy Bad request error ``` { "message": "Error in metric_type creation: the Report simples2 already exists" } ``` text/html Copy Bad request error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Error. ``` { "message": "Internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `get` | `string[]` | Items which will be retrieved (product_name, status, transaction_id,request_collection_id,response_collection_id,operation_status,partner_name,severity,service_endpoint,created_at) | | `metric_type` | `string` | The name of the metric type created or use "performance" for transaction and logging metrics posted in the Health. | | `aggregation` | `string` | For aggregated reports, it will calculate the given function (count, avg, sum) | | `aggregation_field` | `string` | For aggregated reports, it will calculate the aggregation function with this field. Example(transaction_id, response_collection_id) | | `group_by` | `array` | For aggregated reports, it will group the data by these fields. Example(product_name, service_endpoint) | | `filters` | `object` | Filters applied for the report | | `environment` | `string[]` | Environment example | | `product_name` | `string[]` | Product Name Example | | `status` | `string[]` | Status Example | | `report_name` | `string` | Name of the Report. | ##### Response `201``application/json` 1 fields Success Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Bad request error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `502``application/json` 1 fields Error. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message error | `GET` `/get-report` #### Retrieve Custom Report `get_custom_report` This service runs a custom report and allows to retrieve the results for the given report structure. This service runs a custom report and allows to retrieve the results for the given report structure. The start and end date defines the report data timeframe, also the filters are applied. See the service Update custom report to change the structure of the report. ##### Response 200400 0400 text/html403 application/json Copy Success ``` { "Items": [ { "product_name": "Assess", "status": "succeeded", "transaction_id": "1ce37c58-12aa-400f-a7b6-97f5d63b0e50", "host_env": "health.staircaseapi.com", "created_at": "2021-06-25 14:03:03.504" } ] } ``` application/json Copy Error Response ``` { "message": "Error in report retrieving: there is no report with the report_name equals: simples221" } ``` text/html Copy Error Response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `report_name` required | `string` query | `simples221` | The name of the Report | | `start_date` required | `string` query | `2021-01-01` | Start date | | `end_date` required | `string` query | `2021-06-30` | End date | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `Items` | `object[]` | Items | | `transaction_id` | `string` | Field name | | `created_at` | `string` | Field name | | `host_env` | `string` | Field name | | `product_name` | `string` | Field name | | `status` | `string` | Field name | ##### Response `400``application/json` 1 fields Error Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | `PUT` `/update-build-report` #### Update Custom Report `update_custom_report` This service allows updating a custom report structure. This service allows updating a custom report structure. ##### Request Examples - Detailed reportExample - Aggregated application/json Copy ``` { "get": [ "product_name", "status", "transaction_id", "request_collection_id", "response_collection_id", "operation_status", "partner_name", "severity", "service_endpoint" ], "filters": { "product_name": [ "Health", "Account" ], "status": [ "succeeded" ], "environment": [ "health.staircaseapi.com" ] }, "report_name": "report_to_create_name", "metric_type": "performance" } ``` application/json Copy ``` { "get": [ "product_name", "service_endpoint", "status" ], "filters": { "product_name": [ "Health" ] }, "aggregation": "count", "aggregation_field": "transaction_id", "group_by": [ "product_name", "service_endpoint", "status" ], "report_name": "report_to_create_name", "metric_type": "performance" } ``` ##### Response 200400403502 application/json Copy Success Response ``` { "message": "the custom report was successfully updated" } ``` application/json Copy 400 Bad Request ``` { "message": "Error in updating report: the Report report_to_create_name does not exist" } ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Error. ``` { "message": "Internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `get` | `string[]` | Items which will be retrieved (product_name, status, transaction_id,request_collection_id,response_collection_id,operation_status,partner_name,severity,service_endpoint,created_at) | | `metric_type` | `string` | The name of the metric type created or use "performance" for transaction and logging metrics posted in the Health. | | `filters` | `object` | Filters applied for the report | | `environment` | `string[]` | Environment example | | `product_name` | `string[]` | Product Name Example | | `status` | `string[]` | Status Example | | `report_name` | `string` | Name of the Report. | ##### Response `200``application/json` 1 fields Success Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields 400 Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `502``application/json` 1 fields Error. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message error | `GET` `/get-report-id` #### Retrieve Custom Report Id `get_custom_report_id` This service runs a custom report and allows to retrieve the results for the given report structure. This service runs a custom report and allows to retrieve the results for the given report structure. The start and end date defines the report data timeframe, also the filters are applied. The response will be a report id which could be used to retrieve the report using the service /get-report-result See the service Update custom report to change the structure of the report. ##### Response 200400 0400 text/html403 application/json Copy Success ``` { "report_id": "4e6a5826-9a18-4656-b527-03dd7ad1b258", "Items": [] } ``` application/json Copy Error Response ``` { "message": "Error in report retrieving: there is no report with the report_name equals: simples221" } ``` text/html Copy Error Response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `report_name` required | `string` query | `simples221` | The name of the Report | | `start_date` required | `string` query | `2021-01-01` | Start date | | `end_date` required | `string` query | `2021-06-30` | End date | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `report_id` | `string` | Field name | | `Items` | `array` | Items | ##### Response `400``application/json` 1 fields Error Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | `GET` `/get-report-result` #### Retrieve Custom Report CSV `get_custom_report_results_csv` This service runs a custom report and allows to retrieve the results as a pre signed URL which contains a CSV file with the report results. This service runs a custom report and allows to retrieve the results for the given report structure. The start and end date defines the report data timeframe, also the filters are applied. See the service Update custom report to change the structure of the report. ##### Response 200400 0400 text/html403 application/json Copy Success ``` { "Items": [ { "product_name": "Assess", "status": "succeeded", "transaction_id": "1ce37c58-12aa-400f-a7b6-97f5d63b0e50", "host_env": "health.staircaseapi.com", "created_at": "2021-06-25 14:03:03.504" } ] } ``` application/json Copy Error Response ``` { "message": "Error in report retrieving: there is no report with the report_name equals: simples221" } ``` text/html Copy Error Response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `report_id` required | `string` query | `simples221` | The id of the report | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `Items` | `object[]` | Items | | `transaction_id` | `string` | Field name | | `created_at` | `string` | Field name | | `host_env` | `string` | Field name | | `product_name` | `string` | Field name | | `status` | `string` | Field name | ##### Response `400``application/json` 1 fields Error Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ### Cost Metrics `POST` `/cost-metric` #### Create a Cost Metric `create_cost_metric` Create a cost metric. These metrics are used to track customer costs. ##### Request Example Cost metricExample Cost Mortgage application/json Copy ``` { "product_name": "Health", "transaction_id": "3041fe98-4005-438d-9e14-5849ed8d6cc6", "cost_in_cents": 95, "cost_category": "customer" } ``` application/json Copy ``` { "product_name": "Data Extraction", "transaction_id": "1234", "cost_in_cents": 25, "partner": "softworks", "document_type": "W2", "request_collection_id": "01FH8712A4W0TDKGQQ5QF9B8S", "response_collection_id": "01FHAZNF0E0070QSKYS6DW62EH", "pages": "1", "cost_category": "partner" } ``` ##### Response 201400 application/json400 text/html403 application/json Copy Success response. ``` { "message": "cost metric created" } ``` application/json Copy Error Response. ``` { "message": "error in store cost metric" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key | ##### Request body`application/json` 9 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. | | `cost_in_cents`required | `number` | The Cost in cents. It must be an integer number. | | `pages` | `string` | The number of pages of a document used for data extraction. | | `partner` | `string` | Partner | | `product_name`required | `string` | The system that is exposed externally to customers and performs the action. Examples Assess, Build, Employment. | | `document_type` | `string` | The type of document in the data extraction. Example: W2cost: the cost price. | | `cost_category`required | `string` | There are only two types of cost_category allowed (partner and customer)Example `customer` | | `request_collection_id` | `string (string)` | A request collection in Staircase is a container for the elements that a product needs to execute. For example, an AUS collection is a digital representation of a loan application, while a Data Extraction collection is a digital representation of a document.Example `01F2MHXNNNVK02YEY63Q5EQ59T` | | `response_collection_id` | `string (string)` | A response collection in Staircase is a container for the elements that a product has as an output for its execution.Example `01F2MHXNNNVK02YEY63Q5EQ59T` | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message response | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | `GET` `/cost-metric` #### Retrieve a Cost Metric `get_cost_metric` Retrieve a list of cost metric. These metrics are used to track customer costs. ##### Response 200400 error response400 text/html403 application/json Copy Ok. ``` { "cost_metrics": [ { "product_name": "Health", "transaction_id": "2345678a", "cost_in_cents": "123", "partner": "test-partner", "document_type": "test-1", "pages": "223", "created_at": "2021-10-04 15:06:06.720" }, { "product_name": "Health", "transaction_id": "2345678a", "cost_in_cents": "162", "partner": "test-partner", "document_type": "test-1", "pages": "223", "created_at": "2021-10-04 15:06:13.462" } ] } ``` application/json Copy Error response example ``` { "Error": "Invalid Parameter document" } ``` text/html Copy Error response example ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 11 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` | `string` query | `2345678a` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. | | `product_name` | `string` query | `Health` | The system that is exposed externally to customers and performs the action. Examples Assess, Build, Employment. | | `partner` | `string` query | `softworks` | Partner | | `cost_in_cents` | `string` query | `95` | Cost | | `pages` | `string` query | `110` | The number of pages of a document used for data extraction. | | `cost_category` | `string` query | `partner` | Cost category the metric belongs to. | | `document_type` | `string` query | `test-1` | The type of document in the data extraction. | | `start_date` | `string` query | `2021-04-13` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `end_date` | `string` query | `2021-04-16` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format: YYYY-MM-DD | | `date` | `string` query | `2021-04-16` | If provided, filters by date Date must be in ISO8601 format: YYYY-MM-DD | | `x-api-key` required | `string` header | `` | API key | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `Items` | `object[]` | Items | | `transaction_id` | `string` | Transaction Identifier | | `cost_in_cents` | `string` | cost | | `pages` | `string` | pages | | `partner` | `string` | partner | | `created_at` | `string` | Creation date in timestamp format | | `product_name` | `string` | Name of the Product | | `document_type` | `string` | Type of the document | ##### Response `400``application/json` 1 fields Error response example | Field | Type | Description | | --- | --- | --- | | `Error` | `string` | Error | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ### Development `POST` `/development-products` #### Mark as development env for specific product `register_env` Mark this environment as development env for specific product, so failures for this product on this env will not affect Staircase status page. ##### Request application/json Copy ``` { "product_id": "ccd6b8dd-02a7-4c64-a983-7e0c108cd666", "is_disabled": true } ``` ##### Response text/html Copy 400 response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `product_id`required | `string` | The product id that we want to mark as development env.Example `ccd6b8dd-02a7-4c64-a983-7e0c108cd666` | | `is_disabled`required | `boolean` | If true, disable sending alerts for this product_id on this env.Example `true` | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The environment was configured successfully | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error in storing the environment invalid host | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Performance Metrics `POST` `/metric/{transaction_id}` #### Create New Metric `create_metric` Create New Metric. Registers a metric identified by a transaction_id or a unique identifier to track product performance, If multiple services in a product perform processing for the same transaction, the services should send their results to Create New Metric, enabling customers to see the result for one transaction between all products. Create New Metric tracks the following metric types: - Transaction: For every service endpoint invocation, a metric of this type is posted to Health providing information about the service, error, or relevant data to track. Show the rest - Logging: For every service endpoint invocation the logging metrics are posted to follow up the execution process in the source code and including relevant information to track an issue. Health Metrics stores additional fields depending on the product family that allows tracking product KPIs. Single Health Metric payload has 256 KB size limit. Creating a new metric programmatically example: ``` import requests from uuid import uuid4 import json import boto3 client = boto3.client('dynamodb') def create_metric(event, **kwargs): transaction_id = str(uuid4) request_host = event["headers"]["Host"] service_url = request_host + event['path'] x_api_key = event['headers']['x-api-key'] logging_message = kwargs["logging_message"] if "logging_message" in kwargs else None if "error" in kwargs and isinstance(kwargs['error'], dict): payload = { "host_environment": request_host, "product_name": kwargs['product_name'], "metric_type": kwargs['metric_type'], "logging_message": logging_message, "method": kwargs['method'], "service_endpoint": service_url, "error": kwargs['error'], "data": { "status": kwargs['status_response']} } else: payload = { "host_environment": request_host, "product_name": kwargs['product_name'], "metric_type": kwargs['metric_type'], "logging_message": logging_message, "method": kwargs['method'], "service_endpoint": service_url, "data": { "status": kwargs['status_response']} } requests.post( f"", headers={"x-api-key": x_api_key}, json=payload ) @cors_headers def lambda_handler(event, context): try: # Example doing something create_metric(event, product_name="test_example", metric_type="logging", "logging_message"="start handler" method="POST", status_response=200 ) item_example = { "Enterprise": "Staircase", "Phone":"1-347-563-5689", } response = client.put_item( TableName='string', Item=item_example ) # Example create a successfully metric create_metric(event, product_name="test_example", metric_type="transaction", method="POST", status_response=200 ) # return function example return { 'statusCode': 200, 'body': json.dumps({'response': response }) } except Exception as e: # create metric error create_metric(event, product_name="test_example", error={ "status": 400, "message": 'error', "code": 42042}, metric_type="transaction", method="POST", status_response=200 ) # return function example return { 'statusCode': 400, 'body': json.dumps({'response': e }) } ``` ##### Request MortgagePlatformDevops and other productsExample error metricExample logging metricExample failed logging metric application/json Copy Use HealthMetricInputV3 schema - An example of error report. ``` { "host_environment": "documentation.staircaseapi.com", "product_name": "employment", "service_endpoint": "/employment", "method": "POST", "metric_type": "transaction", "partner_name": "truework", "operation_status": "STARTED", "request_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27 } ``` application/json Copy Use HealthMetricInputV3 schema ``` { "host_environment": "documentation.staircaseapi.com", "product_name": "Connector", "service_endpoint": "/vendors/{vendor_name}/flows/{flow_name}/jobs", "method": "POST", "metric_type": "transaction", "partner_name": "truework", "request_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27 } ``` application/json Copy Use HealthMetricInputV3 schema - ``` { "host_environment": "documentation.staircaseapi.com", "product_name": "Code", "service_endpoint": "/clone", "method": "POST", "metric_type": "transaction", "operation_status": "IN PROGRESS", "data": { "project": "Health", "branch": "main" } } ``` application/json Copy Use HealthMetricInputV3 schema - An example of error report. ``` { "host_environment": "documentation.staircaseapi.com", "product_name": "Code", "service_endpoint": "/clone", "method": "POST", "metric_type": "transaction", "error": { "status": 500, "code": 42042, "message": "Internal server error", "more_info": "https://httpstatuses.com/500" }, "data": { "project": "Health", "branch": "main" } } ``` application/json Copy Example using metric as logging in metric_type. ``` { "host_environment": "documentation.staircaseapi.com", "product_name": "Code", "service_endpoint": "/clone", "method": "POST", "metric_type": "logging", "logging_message": "Connect to Github", "elapsed_time": 200.27, "data": { "project": "Health", "branch": "main" } } ``` application/json Copy Example using metric as logging in metric_type. ``` { "host_environment": "documentation.staircaseapi.com", "product_name": "Code", "service_endpoint": "/clone", "method": "POST", "metric_type": "logging", "logging_message": "Connect to Github", "data": { "project": "Health", "branch": "main" }, "error": { "status": 500, "code": 42042, "message": "Internal server error" } } ``` ##### Response 201400 application/json400 text/html403500 application/json Copy Ok. ``` { "message": "metrics created." } ``` application/json Copy Failed Creation. ``` { "message": "Error in creating metric " } ``` text/html Copy Failed Creation. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Failed Creation. ``` { "message": "Internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `transaction_id` required | `string` path | `3cd0ffab-6e87-40a8-bc84-697155131f4c` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. | ##### Request body`application/json` 14 fields | Field | Type | Description | | --- | --- | --- | | `product_name`required | `string` | The system that is exposed externally to customers and performs the action. Examples Assess, Build, Employment.Example `employment` | | `host_environment` | `string` | Environment host where the product is deployed.Example `documentation.staircaseapi.com` | | `service_endpoint`required | `string` | The service endpoint URL that executed an operation, process, or function in the product. Endpoints with path parameters cannot be sent with real values, it must be sent as variables. Example /metric/%7Btransaction_id%7D and /metric are service endpoints of the Health product.Example `/metric/%7Btransaction_id%7D` | | `method` | `string` | HTTP's method or verb that indicates the service endpoint operation type.`DELETE GET PATCH POST PUT`Example `POST` | | `metric_type` | `string (string)` | The type of metric to create, valid options: logging | transaction`logging``transaction`Example `logging` | | `logging_message` | `string (string)` | This field is only available for logging metric_type. It is used for logging purpose.Example `Get collection translation` | | `data` | `object` | Receives a valid JSON with data fields the product wants to log to track issues faster. | | `request_collection_id` | `string (string)` | A request collection in Staircase is a container for the elements that a product needs to execute. For example, an AUS collection is a digital representation of a loan application, while a Data Extraction collection is a digital representation of a document.Example `01F2MHXNNNVK02YEY63Q5EQ59T` | | `response_collection_id` | `string (string)` | A response collection in Staircase is a container for the elements that a product has as an output for its execution.Example `01F2MHXNNNVK02YEY63Q5EQ59T` | | `partner_name` | `string` | The name of the data partner you will receive a product response from. Products that interact with partner integrations in the service endpoint operation should send this field.Example `Atomic` | | `severity` | `string` | The type of the severity to create metric.`CRITICAL``DEBUG``ERROR``HIGH``INFO``LOW``MEDIUM``WARNING` | | `operation_status` | `string` | Every single Staircase service endpoint (such as POST /persistence/transactions or POST /aus/underwrite) is required to provide operation status updates to denote the progress of a transaction in its execution. For more information see the Health overview page with examples.`ABORTED``CANCELLED``COMPLETED``CREATED``EMAIL_CONFIRMED``ERROR``FAILED``IN PROGRESS``IN_PROGRESS``NOT_FOUND``REQUEST_MADE``RUNNING``STARTED``SUCCEEDED``SUCCEEDED_WITH_WARNING``TIMED_OUT``TIMEOUT``UNAUTHORIZED``WAITING_FOR_RESPONSE`Example `COMPLETED` | | `elapsed_time` | `number` | The measured duration of an event. The time is expressed in seconds.Example `120.27` | | `error` | `object` | Receives a valid JSON with the fields to store the error or exception details that occurred during the operation execution. The metric is considered as failed when the error details are provided | | `status`required | `integer` | Status or error code that will be returned by the serviceExample `401` | | `code` | `integer` | Internal error codes.Example `42042` | | `message`required | `string` | Message of Status Code.Example `Unauthorized` | | `more_info` | `string` | Additional Information on ErrorExample `https://api.staircase.co/docs/errors/42042` | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message the metric was successfully created | ##### Response `400``application/json` 1 fields Failed Creation. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message reason why the creation has failed | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Failed Creation. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message error | `GET` `/metric` #### Retrieve Metrics `transactions_list` The service retrieves a list of metrics given one or multiple filters. To retrieve all results, send the request with the same query parameters and next_token provided on the previous call until next_token does not appear in the response. The parameters must use URL Encoding for Special Characters ``` e.g. Left Curly Brace (“{”) = “%7B”, Right Curly Brace (“}”) = “%7D” ``` service_endpoint=%7Btransaction_id%7D Example: service_endpoint=/metric/%7Btransaction_id%7D, for the service "/metric/%7Btransaction_id%7D" ##### Response 200400 application/json400 text/html403 application/json Copy Ok. ``` { "Success response": { "value": { "next_token": "eyJwcm9kdWN0X25hbWUiOiAiQnVpbGQiLCAiY3JlYXRlZF9hdCI6ICIyMDIxLTA2LTA0VDE0OjU5OjE5LjU3MTg3OSJ9", "metrics": [ { "created_at": "2021-07-07T14:17:28.991666-04:00", "product_name": "a", "status": "succeeded", "customer_api_key": "f5c4fec5-2159-4ca4-a061-ab8938ceb70d", "transaction_id": "11111111111111", "service_endpoint": "/bulg", "elapsed_time": "120.0", "service_name": "a" }, { "request_collection_id": "a", "created_at": "2021-05-13T14:07:36.598931-04:00", "product_name": "aa", "status": "succeeded", "transaction_id": "KLKLKLKLKLKLKLKLKLKLKLKL", "service_endpoint": "", "service_name": "aa" } ] } } } ``` application/json Copy Error Response. ``` { "response": { "value": { "message": "Filters not allowed ", "allowed filters": [ "product_name", "status", "partner_name", "metric_type", "operation_stauts", "product_name and severity", "product_name and status", "operation_stauts and partner_name", "start_date and end_date can be combined with every filter" ] } } } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 15 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `service_name` | `string` query | `/employment` | It will be consider as product_name, If provided, filters by concrete product name. | | `product_name` | `string` query | `employment` | If provided, filters by concrete product name. | | `criterion` | `string` query | `succeeded` | It will be consider status. Available values: failed, succeeded | | `status` | `string` query | `succeeded` | status. Available values: failed, succeeded | | `partner_name` | `string` query | `Atomic` | If provided, filters by partner_name | | `operation_status` | `string` query | `STARTED` | If provided, filters by operation_status | | `metric_type` | `string` query | `logging` | If provided, filters by metric_type | | `severity` | `string` query | `LOW` | If provided, filters by severity | | `start_date` | `string` query | `2021-04-13` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `end_date` | `string` query | `2021-04-16` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format: YYYY-MM-DD | | `date` | `string` query | `2021-04-16` | If provided, filters by date Date must be in ISO8601 format: YYYY-MM-DD | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `customer_api_key` | `string` query | `954913e2-db71-4f22-b71c-ef803915eb2b` | It is the key required in order to use the API. Filters by customer_api_key. | | `elapsed_time` | `string` query | `120.27` | The measured duration of an event. The time is expressed in seconds. | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination Token | | `metrics` | `object[]` | Metrics | | `host_environment` | `string` | Environment host where the product is deployed. | | `service_endpoint` | `string` | The service endpoint URL that executed an operation, process, or function in the product. Endpoints with path parameters cannot be sent with real values, it must be sent as variables. Example /metric/%7Btransaction_id%7D and /metric are service endpoints of the Health product. | | `product_name` | `string` | The system that is exposed externally to customers and performs the action. Examples Assess, Build, Employment. | | `created_at` | `string` | A collection in Staircase is a container for the elements that a product needs to execute. For example, an AUS collection is a digital representation of a loan application, while a Data Extraction collection is a digital representation of a document. | | `operation_status` | `string` | The status of an operation given the nature of the actions performed by the service and the transaction result. The service endpoint operation could be successful but the transaction_id could have different status given certain conditions and other operations performed. | | `metric_type` | `string` | The type of metric options allowed logging | transaction | | `logging_message` | `string` | This field is only available for metric_type equals logging. It is used for logging purpose. | | `transaction_id` | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. | | `severity` | `string` | Severity e.g. (HIGH, MEDIUM, LOW)`CRITICAL``DEBUG``ERROR``HIGH``INFO``LOW``MEDIUM``WARNING` | | `customer_api_key` | `string` | It is the key required in order to use the API. Filters by customer_api_key. | | `partner_name` | `string` | The name of the data partner you will receive a product response from. Products that interact with partner integrations in the service endpoint operation should send this field. | | `elapsed_time` | `string` | The measured duration of an event. The time is expressed in seconds. | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `GET` `/metric/{transaction_id}` #### Retrieve Metrics by Transaction ID `get_metrics` Retrieve Metrics by transaction_id Retrieve all health reports for specified transaction_id ##### Response 200400 application/json400 text/html403500 application/json Copy Ok. ``` { "Success Response": { "metrics": [ { "host_environment": "health.staircaseapi.com", "created_at": "2021-07-02T14:52:18.657665-04:00", "product_name": "Health", "data": { "request_data": "9384b4ac-9ea5-4926-824c-eefe37d9689c" }, "status": "succeeded", "customer_api_key": "954913e2-db71-4f22-b71c-ef803915eb2b", "transaction_id": "9384b4ac-9ea5-4926-824c-eefe37d9689c", "metric_type": "transaction", "method": "GET", "service_endpoint": "/metric" } ] } } ``` application/json Copy Error Response. ``` { "message": "Error in metric retrieving" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Error while retrieving metrics. ``` { "message": "Internal server error" } ``` ##### Parameters 8 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | | `transaction_id` required | `string (uuid)` path | `3cd0ffab-6e87-40a8-bc84-697155131f4c` | An Identifier for a Transaction in Staircase. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `product_name` | `string` query | `Code` | filters by concrete product name. | | `host_environment` | `string` query | `health.staircaseapi.com` | filters by host environment. | | `status` | `string` query | `succeeded` | filters by status. Available values: failed, succeeded | | `service_endpoint` | `string` query | `/transactions` | filters by service endpoint | | `method` | `string` query | `GET` | filters by Http Methods. Available values DELETE GET PATCH POST PUT | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `metrics` | `object[]` | Response Body | | `host_environment` | `string` | Environment host where the product is deployed. | | `service_endpoint` | `string` | The service endpoint URL that executed an operation, process, or function in the product. Endpoints with path parameters cannot be sent with real values, it must be sent as variables. Example /metric/%7Btransaction_id%7D and /metric are service endpoints of the Health product. | | `product_name` | `string` | The system that is exposed externally to customers and performs the action. Examples Assess, Build, Employment. | | `metric_type` | `string` | The type of metric options allowed logging | transaction | | `logging_message` | `string` | This field is only available for metric_type logging. It is used for logging purpose. | | `created_at` | `string` | A collection in Staircase is a container for the elements that a product needs to execute. For example, an AUS collection is a digital representation of a loan application, while a Data Extraction collection is a digital representation of a document. | | `operation_status` | `string` | The status of an operation given the nature of the actions performed by the service and the transaction result. The service endpoint operation could be successful but the transaction_id could have different status given certain conditions and other operations performed. | | `transaction_id` | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. | | `severity` | `string` | Severity e.g. (HIGH, MEDIUM, LOW)`CRITICAL``DEBUG``ERROR``HIGH``INFO``LOW``MEDIUM``WARNING` | | `customer_api_key` | `string` | It is the key required in order to use the API. Filters by customer_api_key. | | `partner_name` | `string` | The name of the data partner you will receive a product response from. Products that interact with partner integrations in the service endpoint operation should send this field. | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Error while retrieving metrics. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response Body | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Health Metrics `POST` `/metrics` #### Create Health Metric `create_health_metric` Create New Health Metric. #### Health Metric ##### Product Identifier A product is an entity in the ontology. Product identifiers can be retrieved from Marketplace after product registration. Please visit Marketplace for product registration. ##### Product Api Identifier API can be referenced by unique ID under products. Please visit Marketplace for API registration. ##### Transaction ID Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. Show the rest ##### Response Collection ID A response collection in Staircase is a container for the elements that a product has as an output for its execution. Combination of transaction ID and response collection ID uniquely identifies an execution. ##### Status | Status | Description | | --- | --- | | REQUEST_MADE | Request received successful by API. | | IN_PROGRESS | Invocation has not reached a final state. | | SUCCEEDED | Invocation finished successfully. | | FAILED | Invocation was not successful. | ##### Elapsed Time Amount of time that passes between the beginning of the request and the end of the invocation. ##### Invocation Code The invocation code provides information for the invocation response. Codes and descriptions are given below. Please raise CR if needed invocation code is not listed here. | Invocation Code | Description | | --- | --- | | 2000 | OK. Invocation is successful | | 4000 | BAD_REQUEST. The server cannot or will not process the request due to something that is perceived to be a client error. | | 4001 | UNAUTHORIZED. The client is not authenticated to get the requested response. | | 4003 | FORBIDDEN. The client is known but has no access rights to the content. | | 4004 | NOT_FOUND. The server can not find the requested resource. | | 4009 | CONFLICT. The request could not be completed due to a conflict with the current state of the target resource. | | 4013 | PAYLOAD_TOO_LARGE. The request entity is larger than the limits defined by the server. | | 4022 | UNPROCESSABLE_ENTITY. The request was well-formed but was unable to be followed due to semantic errors. | | 4029 | TOO_MANY_REQUEST. The user has sent too many requests in a given amount of time. | | 5000 | INTERNAL_SERVER_ERROR. The server has encountered a situation it does not know how to handle. | | 5004 | TIMEOUT. This error response is given when the server cannot get a response in time. | | 6000 | PARTNER_CALL_SUCCESS. Partner invocation returns a successful response. | | 6001 | PARTNER_CALL_ERROR_INVALID_AUTH. Unauthorized partner call. | | 6002 | PARTNER_CALL_ERROR_TIMEOUT. The partner did give the response in the given time. | | 6003 | PARTNER_CALL_ERROR_TOO_MANY_REQUESTS. Partner called too many times in the amount of time that partner defined. | | 6004 | PARTNER_CALL_ERROR_INVALID_PAYLOAD. Provided payload to the partner is invalid. | | 6005 | PARTNER_CALL_ERROR_SERVICE_ERROR. Partner returns generic/unclassified service error. | | 6006 | PARTNER_CALL_ERROR_NOT_FOUND The server cannot find the requested resource. | | 6007 | PARTNER_CALL_ERROR_CONFLICT This response is sent when a request conflicts with the current state of the server. | | 7000 | COLD_START. The server received the request successfully but had an initialization process before working on the client request. | | 7001 | INTERNAL_OPERATION_THRESHOLD_EXCEEDED. The server could not finish the internal operation at the given threshold. The threshold can be duration, coverage, etc. | | 7002 | INTERNAL_OPERATION_FAILED. The server completed transaction but had failure in the internal operation. | | 7003 | OVERHEAD. Metric for measuring overhead on given service. | | 8000 | SITE_SESSION_INITIATED. Metric for measuring Site Sessions. | | 8001 | SITE_PAGE_CHANGED. Metric for measuring Site page changes. | | 8002 | CONSOLE_APP_LOADED. Metric for measuring Console App loads. | | 8003 | CONSOLE_APP_USED_DATA. Metric for calculating if Console App used prepopulated data. | | 9001 | EMAIL_SEND. Email send. The send request was successful and the email provider will attempt to deliver the message to the recipient’s mail server. | | 9002 | EMAIL_DELIVERY. Email delivery. The email provider successfully delivered the email to the recipient’s mail server. | | 9003 | EMAIL_OPEN. Email open. The recipient received the message and opened it in their email client. | | 9004 | EMAIL_CLICK. The recipient clicked one or more links in the email. | | 9400 | EMAIL_DELIVERY_DELAY. The email couldn’t be delivered to the recipient’s mail server because a temporary issue occurred. | | 9401 | EMAIL_UNSUBSCRIBE. The email was successfully delivered, but the recipient updated their subscription preferences by clicking on an unsubscribe link. | | 9403 | EMAIL_COMPLAINT. The email was successfully delivered to the recipient’s mail server, but the recipient marked it as spam. | | 9500 | EMAIL_REJECT. The email provider accepted the email but determined that it contained a virus and didn’t attempt to deliver it to the recipient’s mail server. | | 9501 | EMAIL_BOUNCE. The recipient’s mail server permanently rejected the email. | | 9502 | EMAIL_RENDERING_FAILURE. The email wasn’t sent because of a template rendering issue. | ##### Product Build Hash The builder generates a hash value after every product build. The hash value indicates which build version the metric comes from. Please check Builder documentation for details and how to get the build hash. ##### Request application/json Copy An example health metric. ``` { "product_identifier": "ccd6b8dd-02a7-4c64-a983-7e0c108cd666", "product_api_identifier": "1236b8dd-02a7-4c64-a983-7e0c108cd666", "transaction_id": "01F2Q6WJXF5DK3ERTZ18JHSNE8", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "invocation_code": "6001", "status": "FAILED", "elapsed_time": 200.27 } ``` ##### Response 201400 application/json400 text/html application/json Copy Ok. ``` { "id": "86a9ef39-5907-4fb6-bdc5-987017b6c999", "message": "metrics created." } ``` application/json Copy Failed Creation. ``` { "message": "Error in creating metric " } ``` text/html Copy Failed Creation. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `x-sc-trace-id` | `string` header | `041fe98-4005-438d-9e14-5849ed8d6cc6` | Id to trace all transactions related. It will be generated automatically if not provided. | ##### Request body`application/json` 20 fields | Field | Type | Description | | --- | --- | --- | | `product_identifier`required | `string` | Unique product identifier.Example `ccd6b8dd-02a7-4c64-a983-7e0c108cd666` | | `product_api_identifier`required | `string` | Unique product api identifierExample `548070b4-6ea7-459e-9746-5020446b3a73` | | `transaction_id`required | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled.Example `3cd0ffa-6e87-40a8-bc84-697155131f4c` | | `response_collection_id`required | `string (string)` | A response collection in Staircase is a container for the elements that a product has as an output for its execution. Combination of transaction ID and response collection ID uniquely identifies a single execution.Example `01F2MHXNNNVK02YEY63Q5EQ59T` | | `status`required | `string` | Indicates status of the process.`FAILED``IN_PROGRESS``REQUEST_MADE``SUCCEEDED`Example `SUCCEEDED` | | `elapsed_time`required | `number` | The measured duration of an event. The time is expressed in seconds.Example `120.27` | | `invocation_code`required | `string` | Product invocation response code. For more information please check invocation code mapping.Example `6001` | | `configuration_id` | `string` | Product configuration ID. | | `product_build_hash` | `string` | Hash value that generated from builder. | | `campaign_id` | `string` | Campaign ID | | `user_agent` | `string` | Optional. Represents actor's user agent. This will not be derived from the request headers if omitted.Example `Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3` | | `person_guid` | `string` | Person GUID | | `phone_call_callback_number` | `string` | Callback number | | `virtual_phone_number` | `string` | To phone number | | `communication_identifier` | `string` | From phone number | | `call_center_number` | `string` | Call center number | | `lead_identifier` | `string` | Lead identifier | | `voice_transcription` | `string` | The text representation of the spoken audio, transcribed from voice input. | | `sms_text` | `string` | The SMS text that we received. | | `x-sc-trace-id` | `string` | Id to trace all transactions related. It will be generated automatically if not provided. | ##### Response `201``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `id` | `string` | Unique metric id. | | `message` | `string` | Message the metric was successfully created | ##### Response `400``application/json` 1 fields Failed Creation. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message reason why the creation has failed | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `POST` `/metrics/query` #### Create Asynchronous Health Metric Query `create_async_health_query_execution` Create Asynchronous Health Query Execution #### Query Execution Create Asynchronous Health Metric Query creates and executes the query immediately, for the query status and results invoke Get Asynchronous Health Metric Query Result. If you invoke multiple times Get Asynchronous Health Metric Query Result for the same query_id you will receive the same results set that was created during the (first) execution. Each execution of Create Asynchronous Health Metric Query creates a new query and result set. #### Limits | Limit | Value | | --- | --- | | Concurrent Query Execution | 20 query execution per second | #### Timezone The Health product uses the timezone Eastern Standard Time (UTC-5). Please specify the `include_timezone` field in the query configuration to get time with timezone information included. ##### Request Query BodyQuery Body List Fields application/json Copy Create asynchronous query execution ``` { "transaction_id": "01F2Q6WJXF5DK3ERTZ18JHSNE8", "start_date": "2022-04-11T00:00:00", "end_date": "2022-04-11T23:59:59" } ``` application/json Copy Create asynchronous query execution ``` { "start_date": "2022-04-11T00:00:00", "end_date": "2022-04-11T23:59:59", "product_identifier": "ccd6b8dd-02a7-4c64-a983-7e0c108cd666", "invocation_codes": [ 7000, 7001 ] } ``` ##### Response 201400 application/json400 text/html application/json Copy Ok. ``` { "query_id": "c62a1228-fae7-44c8-aebe-8706ecfb9fc4", "status": "PENDING" } ``` application/json Copy Failed Creation. ``` { "message": "Error in creating metric " } ``` text/html Copy Failed Creation. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 22 fields | Field | Type | Description | | --- | --- | --- | | `product_identifier` | `one of` | Product identifier | | `product_api_identifier` | `one of` | Product api identifier | | `transaction_id` | `one of` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. | | `response_collection_id` | `one of` | A response collection in Staircase is a container for the elements that a product has as an output for its execution. Combination of transaction ID and response collection ID uniquely identifies a single execution. | | `invocation_code` | `one of` | Code that indicates invocation response | | `status` | `one of` | Indicates status of the process. | | `configuration_id` | `one of` | Product configuration ID. | | `product_build_hash` | `one of` | Hash value that generated from builder. | | `campaign_id` | `one of` | campaign_id from metric body. | | `user_agent` | `one of` | user_agent from metric body. | | `person_guid` | `one of` | person_guid from metric body. | | `phone_call_callback_number` | `one of` | callback number from metric body. | | `virtual_phone_number` | `one of` | virtual_phone_number number from metric body. | | `call_center_number` | `one of` | call_center_number number from metric body. | | `lead_identifier` | `one of` | lead_identifier from metric body. | | `communication_identifier` | `one of` | phone number from metric body. | | `voice_transcription` | `one of` | The text representation of the spoken audio, transcribed from voice input. | | `query_configuration` | `object` | Query configuration | | `include_timezone` | `boolean` | Includes timezone info and update date format to ISO8601. | | `include_host_environment` | `boolean` | Includes environment domain info to result set. | | `callback_url` | `string (uri)` | When query execution is done, this url will be called with resultExample `https://webhook.com/callback` | | `start_date`required | `string` | Datetime must be in ISO8601 format.Example `2021-08-13T00:00:00` | | `end_date`required | `string` | Datetime must be in ISO8601 format. Should be later than `start_date`Example `2021-08-13T23:59:59` | | `x-sc-trace-id` | `string` | Id to trace all transactions related.Example `041fe98-4005-438d-9e14-5849ed8d6cc6` | ##### Response `201``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `query_id` | `string` | Unique identifier for running query execution | | `status` | `string` | Status of the query execution | ##### Response `400``application/json` 1 fields Failed Creation. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message reason why the creation has failed | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `GET` `/metrics/query/{query_id}` #### Get Asynchronous Health Metric Query Result `get_async_health_query_result` The service retrieves a list of metrics by given query id. To retrieve all results, send the next_token provided on the previous call until next_token does not appear in the response. ##### Response 200400 application/json400 text/html404 application/json Copy Ok. ``` { "status": "SUCCEEDED", "result_csv_file": "https://athena-query-results-293107503335.s3.amazonaws.com/1cf6527c-95cc-4998-b273-d3f4b9dd8014.csv&Expires=1661502173", "next_token": "QVdzd01lM0VwNUNSUjNjakRRMllkNDBEdi92ZWZ6ODJXNFBGZnAxMmk4QjhlcTUrQ2tVaTFIZGpOSXRyYThUYU9YRHVHRzlzN3cxMXEwZTUzY3ZETGxOVHZQOWkwSFYzTUE9PQ==", "metrics": [ { "created_at": "2022-08-26 02:34:46", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-1", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:34:49", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-2", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:34:52", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-3", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:34:55", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-4", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:34:58", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-5", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:35:02", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-6", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:35:05", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-7", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:35:08", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-8", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" }, { "created_at": "2022-08-26 02:35:12", "host_environment": "health.staircaseapi.com", "product_identifier": "product_identifier_1", "product_api_identifier": "product_api_identifier_1", "transaction_id": "test-9", "response_collection_id": "01F2Q6WJXF5DK3ERTZ1E9NDNE8", "elapsed_time": 200.27, "status": "IN_PROGRESS", "invocation_code": "2000" } ] } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `query_id` required | `string` path | `1fc23e2-b13e-405a-a3de-a5228950e3b8` | Unique query execution id | | `x-api-key` required | `string` header | `` | API key | | `limit` | `integer` query | `150` | The number of results to return in this request. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `query_id` required | `string` path | `query_id_1` | Query ID received previously with asynchronous query creation | ##### Response `200``application/json` 4 fields Ok. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the query execution`FAILED``IN_PROGRESS``SUCCEEDED`Example `SUCCEEDED` | | `result_csv_file` | `string` | Url for query result in CSV formatExample `https://athena-query-results-293107503335.s3.amazonaws.com/1cf6527c-95cc-4998-b273-d3f4b9dd8014.csv?%2Fol&Expires=1661502173` | | `next_token` | `string` | Indicates next page exist. Using this token next page can retrieve.Example `QVdMejZQT0gzY1I5ZmZCOXF2V1NlQW1Za2xITTNRYWtiVFViRUswYUVScWk2ZFJ3Q0xRRFFaQkx0QXVNVlU3K0JvZU8yTDIzc0RCSGNlcGg0TE5ZdExIeWJNeDlidDBSNkE9PQ==` | | `metrics` | `object[]` | Metrics | | `id` | `string` | Metric unique identifierExample `babb5fb4-b587-4914-a84c-c52c431b7905` | | `created_at` | `string` | Metric creation date.Example `2022-08-26 02:34:46` | | `host_environment` | `string` | Environment host where the product is deployed.Example `health.staircaseapi.com` | | `product_identifier` | `string` | Unique product identifier.Example `ccd6b8dd-02a7-4c64-a983-7e0c108cd666` | | `product_api_identifier` | `string` | Unique product api identifier.Example `548070b4-6ea7-459e-9746-5020446b3a73` | | `transaction_id` | `string` | Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled.Example `3cd0ffa-6e87-40a8-bc84-697155131f4c` | | `response_collection_id` | `string` | A response collection in Staircase is a container for the elements that a product has as an output for its execution. Combination of transaction ID and response collection ID uniquely identifies a single execution.Example `01F2MHXNNNVK02YEY63Q5EQ59T` | | `elapsed_time` | `number` | The measured duration of an event. The time is expressed in seconds.Example `14.55` | | `status` | `string` | Indicates status of the process.Example `IN_PROGRESS` | | `invocation_code` | `string` | Product invocation response code.Example `2000` | | `configuration_id` | `string` | Product configuration ID.Example `e1b96c6d-d24e-459c-ae8a-ec460df3de8f` | | `product_build_hash` | `string` | Product build hash.Example `46b5218a58aed835e63a3b7bf158742600dfbf10` | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Aggregation[new] `POST` `/metrics/aggregation/query` #### Aggregate Health Metrics[new] `aggregate_health_metrics` Aggregate Health Metrics The service creates aggregated metric query execution for the given query parameters. #### Aggregation ##### Date If specified, fillers data between the given start and end date and group them according to the given date interval. ###### Interval Allowed interval types: - `second` - `minute` - `hour` - `day` ##### Filters Multiple filters that applied before grouping metrics. Filter condition applied according to the given operator onto the given field. Show the rest | Allowed Operator | Allowed Field | | --- | --- | | `=` | `product_identifier`, `product_api_identifier`, `transaction_id`, `response_collection_id` , `status`, `invocation_code`, `configuration_id`, `product_build_hash` | ##### Group By Group values with a given field. Allowed field names: - `product_identifier` - `product_api_identifier` - `transaction_id` - `response_collection_id` - `status` - `invocation_code` - `configuration_id` - `product_build_hash` ##### Methods Allows applying methods on filtered and grouped results. Methods are defined and applicable according to filed names. `row` is a special keyword for representing a single row in the result set. | Allowed Method | Allowed field | | --- | --- | | `COUNT` | `row`, `product_identifier`, `product_api_identifier`, `transaction_id`, `response_collection_id` , `status`, `invocation_code`, `elapsed_time`, `configuration_id`, `product_build_hash` | | `SUM` | `elapsed_time` | | `AVG` | `elapsed_time` | | `P50, P90, P95, P99` | `elapsed_time` | ##### Limits | Limit | Value | | --- | --- | | Concurrent Aggregation Execution | 20 query execution per second | ##### Request Product APIs Hourly Status Distribution Product APIs Hourly Avg Elapsed times application/json Copy Create asynchronous query execution ``` { "date": { "start_date": "2022-10-03T00:00:00", "end_date": "2022-10-10T23:59:59", "interval": { "type": "hour", "value": "1" } }, "filters": [ { "field_name": "product_identifier", "field_value": "e53e749f-38ec-4435-943f-6d5c6d32bc12", "operator": "=" } ], "group_by": [ "product_identifier", "product_api_identifier", "status" ], "methods": [ { "method_name": "COUNT", "field_name": "row" } ] } ``` application/json Copy Create asynchronous query execution ``` { "date": { "start_date": "2022-10-03T00:00:00", "end_date": "2022-10-10T23:59:59", "interval": { "type": "hour", "value": "1" } }, "filters": [ { "field_name": "product_identifier", "field_value": "e53e749f-38ec-4435-943f-6d5c6d32bc12", "operator": "=" } ], "group_by": [ "product_identifier", "product_api_identifier" ], "methods": [ { "method_name": "AVG", "field_name": "elapsed_time" } ] } ``` ##### Response 201400 application/json400 text/html application/json Copy Ok. ``` { "query_id": "c62a1228-fae7-44c8-aebe-8706ecfb9fc4", "status": "IN_PROGRESS" } ``` application/json Copy Failed Creation. ``` { "message": "Error in creating metric " } ``` text/html Copy Failed Creation. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `date`required | `object` | Date filter and interval specification | | `start_date`required | `string` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format.Example `2021-08-13T00:00:00` | | `end_date`required | `string` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format.Example `2021-08-13T23:59:59` | | `interval` | `object` | Date interval | | `type`required | `string` | Interval type`day``hour``minute``second`Example `minute` | | `value`required | `integer` | Interval valueExample `1` | | `filters` | `object[]` | List of filters | | `field_name`required | `string` | Filter field name`configuration_id``invocation_code``product_api_identifier``product_build_hash``product_identifier``response_collection_id``status``transaction_id`Example `status` | | `field_value`required | `string` | Filter field valueExample `FAILED` | | `operator`required | `string` | The operator that will be used for comparison`=` | | `group_by`required | `string[]` | Field names that will be used for grouping | | `methods` | `object[]` | Methods that will be applied to grouped metrics | | `method_name`required | `string` | Method name`AVG``COUNT``SUM`Example `COUNT` | | `field_name`required | `string` | Field name`configuration_id``elapsed_time``invocation_code``product_api_identifier``product_build_hash``product_identifier``response_collection_id``row``status``transaction_id`Example `row` | | `callback_url` | `string (uri)` | When query execution is done, this url will be called with resultExample `https://webhook.com/callback` | | `query_configuration` | `object` | Query configuration | | `include_timezone` | `boolean` | Includes timezone info and update date format to ISO8601. | | `include_host_environment` | `boolean` | Includes environment domain info to result set. | ##### Response `201``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `query_id` | `string` | Unique identifier for running query execution | | `status` | `string` | Status of the query execution | ##### Response `400``application/json` 1 fields Failed Creation. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message reason why the creation has failed | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `error` | `string` | Error | `GET` `/metrics/aggregation/query/{query_id}` #### Get Health Aggregation Query Result[new] `get_aggregated_health_query_result` Get Health Aggregation Query Result The service retrieves aggregated metric query result. To retrieve all results, send the next_token provided on the previous call until next_token does not appear in the response. ##### Response 200400 application/json400 text/html404 application/json Copy Ok. ``` { "status": "SUCCEEDED", "result_csv_file": "https://athena-query-results-1111111111.s3.amazonaws.com/2ff0bc1e-c48e-438a-b82b-418d2d844f0a.csv?&Expires=1665390635", "metrics": [ { "time_interval": "2022-10-05 00:00:00", "product_identifier": "e53e749f-38ec-4435-943f-6d5c6d32bc12", "product_api_identifier": "087dc8c8-936c-4148-82f6-7f8fe112d48c", "elapsed_time_avg": 0.0018733719 }, { "time_interval": "2022-10-07 00:00:00", "product_identifier": "e53e749f-38ec-4435-943f-6d5c6d32bc12", "product_api_identifier": "087dc8c8-936c-4148-82f6-7f8fe112d48c", "elapsed_time_avg": 0.00072799996 }, { "time_interval": "2022-10-06 00:00:00", "product_identifier": "e53e749f-38ec-4435-943f-6d5c6d32bc12", "product_api_identifier": "087dc8c8-936c-4148-82f6-7f8fe112d48c", "elapsed_time_avg": 0.0010120743 } ] } ``` application/json Copy Error Response. ``` { "message": "Bad Request" } ``` text/html Copy Error Response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01GYYMHV78DVPV5TSHPQTJ31X9` | Trace ID | | `x-api-key` required | `string` header | `` | API key | | `limit` | `integer` query | `150` | The number of results to return in this request. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `query_id` required | `string` path | `query_id_1` | Query ID received previously with asynchronous query creation | ##### Response `200``application/json` 4 fields Ok. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the query execution`FAILED``IN_PROGRESS``SUCCEEDED`Example `SUCCEEDED` | | `result_csv_file` | `string` | Url for query result in CSV formatExample `https://athena-query-results-293107503335.s3.amazonaws.com/1cf6527c-95cc-4998-b273-d3f4b9dd8014.csv?%2Fol&Expires=1661502173` | | `next_token` | `string` | Indicates next page exist. Using this token next page can retrieve.Example `QVdMejZQT0gzY1I5ZmZCOXF2V1NlQW1Za2xITTNRYWtiVFViRUswYUVScWk2ZFJ3Q0xRRFFaQkx0QXVNVlU3K0JvZU8yTDIzc0RCSGNlcGg0TE5ZdExIeWJNeDlidDBSNkE9PQ==` | | `metrics` | `object[]` | Metrics | ##### Response `400``application/json` 1 fields Error Response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Custom Metric Types `POST` `/post-metric` #### Create Custom Metrics `post_custom_metric` Create custom metric for a specific metric type. Create custom metric for a specific metric type ##### Request 012 application/json Copy ``` { "metric_type": "test_27", "name": "simnlol", "address": "formiga112", "product": { "place": "luzitania", "sin": "rep_24" }, "techno": [ 69, 21, 12, 24 ] } ``` application/json Copy ``` { "metric_type": "test_nnn", "name": "simnlol", "address": "formiga112", "product": { "place": "luzitania", "sin": "rep_24" }, "techno": [ 69, 21, 12, 24 ] } ``` application/json Copy ``` { "metric_type": "test_27", "name": "simnlol", "address": "formiga112", "product": { "place": "nono", "sin": "rep_24" }, "techno": [ 69, 21, 12, 24 ] } ``` ##### Response 201400 0400 1400 text/html403 application/json Copy Created Response ``` { "resp": "metric sent" } ``` application/json Copy Error Response ``` { "error": "metric_type test_nnn does not exist " } ``` application/json Copy Error Response ``` { "error": "123 is not of type 'string'\n\nFailed validating 'type' in schema['properties']['product']['properties']['place']:\n {'type': 'string'}\n\nOn instance['product']['place']:\n 123" } ``` text/html Copy Error Response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `product` | `object` | Metric object | | `sin` | `string` | Metric field example | | `place` | `string` | Metric field example | | `address` | `string` | Metric field example | | `techno` | `integer[]` | Metric field example | | `metric_type`required | `string` | Metric field example | | `name` | `string` | Metric field example | ##### Response `201``application/json` 1 fields Created Response | Field | Type | Description | | --- | --- | --- | | `resp` | `string` | Response | ##### Response `400``application/json` 1 fields Error Response | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error Response | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | `PUT` `/put-metric-type` #### Update Metric Type `update_metric_type` This service update an existing metric type and its fields, allowing the customer to update their own metrics based on events when a metric is posted to the Health. This service update an existing metric type and its fields, allowing the customer to update their own metrics based on events when a metric is posted to the Health. This service update an existing metric type and its fields, allowing the customer to update their own metrics based on events when a metric is posted to the Health /post-metric service. The metric type name is the main reference. The field names can be reference to build a new report. ##### Request 01 application/json Copy ``` { "metric_type_name": "test_000", "schema": { "type": "object", "required": [], "properties": { "name": { "type": "string" }, "address": { "type": "string" }, "product": { "type": "object", "properties": { "place": { "type": "string" }, "sin": { "type": "string" } } }, "techno": { "type": "array", "items": { "type": "number" } } } } } ``` application/json Copy ``` { "schema": { "type": "object", "required": [], "properties": { "name": { "type": "string" }, "address": { "type": "string" }, "product": { "type": "object", "properties": { "place": { "type": "string" }, "sin": { "type": "string" } } }, "techno": { "type": "array", "items": { "type": "number" } } } } } ``` ##### Response 201400 0400 text/html403 application/json Copy Metric type created response ``` { "message": "the metric_type was successfully updated" } ``` application/json Copy Error response ``` { "error": "error updating metric type: metric_type_name is a required field " } ``` text/html Copy Error response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | The metric type schema | | `type` | `string` | Type declaration example | | `required` | `string[]` | Required array. All the field which are required in the schema | | `properties` | `object` | Example fields | | `product` | `object` | Example fields | | `type` | `string` | Example type | | `properties` | `object` | Example fields | | `address` | `object` | Example fields | | `type` | `string` | Example type | | `techno` | `object` | Example Array Field | | `type` | `string` | Example type | | `items` | `object` | Example Field | | `name` | `object` | Example Field | | `type` | `string` | Example type | | `metric_type_name` | `string` | Unique identifier of the metric type | ##### Response `201``application/json` 1 fields Metric type created response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `POST` `/create-metric-type` #### Create Metric Type `create_new_metric_type` This service defines a metric type and its fields, allowing the customer to create their own metrics based on events when a metric is posted to the Health. This service defines a metric type and its fields, allowing the customer to create their own metrics based on events when a metric is posted to the Health /post-metric service. The metric type name is the main reference. The field names can be reference to build a new report. ##### Request 01 application/json Copy ``` { "metric_type_name": "test_000", "schema": { "type": "object", "required": [], "properties": { "name": { "type": "string" }, "address": { "type": "string" }, "product": { "type": "object", "properties": { "place": { "type": "string" }, "sin": { "type": "string" } } }, "techno": { "type": "array", "items": { "type": "number" } } } } } ``` application/json Copy ``` { "schema": { "type": "object", "required": [], "properties": { "name": { "type": "string" }, "address": { "type": "string" }, "product": { "type": "object", "properties": { "place": { "type": "string" }, "sin": { "type": "string" } } }, "techno": { "type": "array", "items": { "type": "number" } } } } } ``` ##### Response 201400 0400 text/html403 application/json Copy Metric type created response ``` { "message": "the new metric_type was successfully created" } ``` application/json Copy Error response ``` { "error": "error creating metric type: metric_type_name is a required field " } ``` text/html Copy Error response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | The metric type schema | | `type` | `string` | Type declaration example | | `required` | `string[]` | Required array. All the field which are required in the schema | | `properties` | `object` | Example fields | | `product` | `object` | Example fields | | `type` | `string` | Example type | | `properties` | `object` | Example fields | | `address` | `object` | Example fields | | `type` | `string` | Example type | | `techno` | `object` | Example Array Field | | `type` | `string` | Example type | | `items` | `object` | Example Field | | `name` | `object` | Example Field | | `type` | `string` | Example type | | `metric_type_name` | `string` | Unique identifier of the metric type | ##### Response `201``application/json` 1 fields Metric type created response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Environments Data `POST` `/register-env` #### Register Environment and API Key `store_new_environment_credentials` Register the environment and api key the customer wants to get in reports. Register the environment and API key, this will allow Health to retrieve data from one environment to another. The data is migrated daily, the customer can retrieve reports from local and other registered environments. ##### Request application/json Copy . ``` { "host": "test2.staircaseapi.com\"", "api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" } ``` ##### Response 400403 text/html Copy 400 response. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `host`required | `string` | The environment hostExample `health.staircaseapi.com` | | `api-key`required | `string (api-key)` | The api-key used in order to access APIs in the hostExample `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The environment was stored successfully | ##### Response `400``application/json` 1 fields 400 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error in storing the environment invalid host | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Internal server error | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | ### Report Subscription `POST` `/report-subscription` #### Create Report Subscription `report-subscription` Subscription to receive a report through Slack notification. Subscription to receive a report through Slack notification. Specify the period either by days, week, or month, and the filters to apply. You can subscribe to the following reports: - Partner Report: Subscribe to receive the Partner report. See this link for more information. - Products by operation status: Subscribe to receive the Product By Operation Status Report. See this link for more information. - Summary Reports: Subscribe to receive the Summary Report by Status. See this link for more information. - Products by unique transactions report: Subscribe to receive the Unique Transactions By Product Report. See this link for more information. - Custom reports created in the service /build-report The Slack media type is currently allowed. A token must be provided to send the notification. After the subscription, the user will receive the report through a post with the results in the configured period. Follow this link to choose or create new apps in Slack. Use the app token "Bot User OAuth Token" ##### Request Example dailyExample cron dailyExample [x] daysExample weeklyExample monthlyCustom Report Example application/json Copy ``` { "subscription_name": "no5", "media": "slack", "send_to_id": "slack-channel-name", "period": "1d", "products": [ "employment", "income", "Health" ], "environments": [ "account.staircaseapi.com", "health.staircaseapi.com" ], "report_type": "summary_report", "token": "" } ``` application/json Copy ``` { "subscription_name": "no5", "media": "slack", "send_to_id": "slack-channel-name", "cron": "0 9,16 * * *", "products": [ "employment", "income", "Health" ], "environments": [ "account.staricaseapi.com", "health.staircaseapi.com" ], "report_type": "summary_report", "token": "" } ``` application/json Copy ``` { "subscription_name": "no3", "media": "slack", "send_to_id": "slack-channel-name", "period": "15d", "products": [ "employment", "income", "Health" ], "environments": [ "account.staircaseapi.com", "health.staircaseapi.com" ], "partners": [ "atomic", "citadel" ], "report_type": "partner_report", "token": "" } ``` application/json Copy ``` { "subscription_name": "no2", "media": "slack", "send_to_id": "slack-channel-name", "period": "1w", "products": [ "employment", "income", "Health" ], "environments": [ "account.staircaseapi.com", "health.staircaseapi.com" ], "report_type": "product_unique_transactions_report", "token": "" } ``` application/json Copy ``` { "subscription_name": "no1", "media": "slack", "send_to_id": "slack-channel-name", "period": "1m", "products": [ "employment", "income", "Health" ], "environments": [ "account.staircaseapi.com", "health.staircaseapi.com" ], "report_type": "product_unique_transactions_report", "token": "" } ``` application/json Copy ``` { "media": "slack", "subscription_name": "no2", "send_to_id": "slack-channel-name", "period": "15d", "report_type": "custom_report_name", "token": "" } ``` ##### Response 201400 0400 1400 2400 text/html403 application/json Copy Subscription success response ``` { "message": "Subscription successfully created" } ``` application/json Copy Subscription error response ``` { "error": "period field is invalid. format allowed: d, w, m " } ``` application/json Copy Subscription error response ``` { "error": "the Subscription solo already exists" } ``` application/json Copy Subscription error response ``` { "error": "There is no custom report with the name: cabuc" } ``` text/html Copy Subscription error response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Request body`application/json` 11 fields | Field | Type | Description | | --- | --- | --- | | `subscription_name`required | `string` | Unique Identifier of the Subscription | | `group_by` | `string` | Option to retrieve unique transactions by field transaction_id, request_collection_id or response_collection_id. It is only used in report type product_by_operation_status or partner report | | `period`required | `string` | The period is sent using d for days, w for weeks and m for months, the number always goes first e.g. 3w | | `cron`required | `string` | The scheduler definition is required for cumulative reports. Currently, supports only daily reports. Example of scheduler definition "0 9,16 * * *" → Get report between 00:00 - 09:00 and 00:00 - 16:00 for every day. | | `environments` | `string[]` | Environments | | `send_to_id`required | `string` | Slack channel name or Member ID (For private DM) | | `media`required | `string` | The only type allowed at the moment is slack | | `products` | `string[]` | List of products used in the query to build the reports which will be sent | | `partners` | `string[]` | List of partners (only for report_type = partner_report) used in the query to build the reports which will be sent | | `token` | `string` | In order to use it to send reports through slack this Field is required, the app token must be authorized in the User Token Scopes with files:write | | `report_type` | `string` | The report name (partner_report, summary_report, product_by_operation_status and product_unique_transactions_report) or Custom report name | ##### Response `201``application/json` 1 fields Subscription success response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Subscription error response | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | `POST` `/error-subscription` #### Create Error Report Subscription `create_error_subscription` This service sends a notification when an error is posted for a product service endpoint in Health. ##### Request application/json Copy ``` { "media": "slack", "subscription_name": "my-error-subscription", "send_to_id": "U04SR512392R", "products": [ "Account", "employment" ], "token": "" } ``` ##### Response 201400 0400 text/html403 application/json Copy Success Response ``` { "message": "Subscription successfully created" } ``` application/json Copy Error Response ``` { "error": "products is a required field" } ``` text/html Copy Error Response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `subscription_name` | `string` | Unique Identifier of the Subscription | | `send_to_id` | `string` | Slack channel name or Member ID (For private DM) | | `media` | `string` | The only type allowed at the moment is slack | | `products` | `string[]` | List of products used in the query to build the reports which will be sent | | `token` | `string` | In order to use it to send reports through slack this Field is required, the app token must be authorized in the User Token Scopes with files:write | ##### Response `201``application/json` 1 fields Success Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Error Response | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | `DELETE` `/delete-subscription/{subscription_id}` #### Delete Report Subscription `delete_subscription_id` This service allows removing a notification subscription. This service allows removing a notification subscription, the subscription name must be provided. After deleting the subscription, the notification will not be received through slack. ##### Response 200 0200 2400403404 application/json Copy Auto generated using Swagger Inspector ``` { "message": "subscription no2 successfully deleted" } ``` application/json Copy Auto generated using Swagger Inspector ``` { "message": "subsription te99 not found" } ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | | `subscription_id` required | `string` path | `MNe` | Unique identifier of a subscription which will be deleted. | ##### Response `200``application/json` 1 fields Auto generated using Swagger Inspector | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `DELETE` `/delete-error-subscription/{subscription_id}` #### Delete Report Error Subscription `delete-error-subscription` This service allows removing a notification subscription. This service allows removing a notification subscription, the subscription name must be provided. After deleting the subscription, the notification will not be received through Slack. ##### Response 200 0200 2400403404 application/json Copy Auto generated using Swagger Inspector ``` { "message": "subscription no2 successfully deleted" } ``` application/json Copy Auto generated using Swagger Inspector ``` { "message": "subsription te99 not found" } ``` text/html Copy Bad request. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` text/html Copy Not found. ``` \r\n400 Bad Request\r\n\r\n

404 Not found

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | | `subscription_id` required | `string` path | `MNe` | Unique identifier of a subscription which will be deleted. | ##### Response `200``application/json` 1 fields Auto generated using Swagger Inspector | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Not found. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | `GET` `/get-subscriptions` #### Retrieve All Report Subscriptions `get_all_subscription` It retrieves a list of subscriptions registered, all subscriptions send a notification with the report type selected, the method, and the send_to_id. ##### Response 200400403 application/json Copy Subscription data. ``` { "subscriptions": [ { "subscription_name": "ass", "media": "slack", "send_to_id": "test", "period": "15d", "cron": null, "report_type": "summary_report", "query_info": { "customer_x_api_key": "iaia-222-4ca4-a061-xxxaoaoao", "environments": [ "account.staircaseapi.com", "health.staircaseapi.com" ], "products": [ "employment", "income", "Health" ] } } ], "error_subscriptions": [ { "subscription_name": "11", "media": "slack", "query_info": { "products": [ "Health" ] } } ] } ``` text/html Copy 400 Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Response `200``application/json` 2 fields Subscription data. | Field | Type | Description | | --- | --- | --- | | `subscriptions` | `object[]` | Subscription data. | | `period` | `string` | Period. | | `cron` | `string` | Period. | | `send_to_id` | `string` | ID where it will be sent. | | `subscription_name` | `string` | Unique identifier of the subscription. | | `media` | `string` | Slack the only value allowed at the moment. | | `report_type` | `string` | Type of the report. | | `query_info` | `object` | Filters detail | | `customer_x_api_key` | `string` | It is the key required in order to use the API. Filters by customer_api_key. | | `environments` | `string[]` | Environments | | `products` | `string[]` | List of products used in the query to build the reports which will be sent | | `error_subscriptions` | `object[]` | Error Subscriptions | | `subscription_name` | `string` | Unique identifier of the subscription. | | `send_to_id` | `string` | ID where it will be sent. | | `query_info` | `object` | Filters detail | | `products` | `string[]` | List of products for error metrics. | | `media` | `string` | Slack the only value allowed at the moment. | ##### Response `400``application/json` 1 fields 400 Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ### Reports `GET` `/summary_report_by_status` #### Retrieve Summary Report by Status `get_report_summary_report_by_status` This report brings the total number of metrics by status. This report brings the total number of metrics by status. You can get the following information about your products by using this report: - The metrics posted for per product - The metrics that succeeded per product. - The metrics that failed, this means that an error or exception occurred in the product while processing one of the services. ##### Response 200400 Error Response Example400 text/html403 application/json Copy Example Success Response ``` { "report": { "Items": [ { "product_name": "service-decision-api-dev", "host_env": "account.staircaseapi.com", "succeeded": "2", "total": 2 }, { "product_name": "income-dev", "host_env": "account.staircaseapi.com", "succeeded": "2", "total": 2 }, { "product_name": "assessments", "host_env": "health.staircaseapi.com", "succeeded": "9", "total": 9 }, { "product_name": "employment", "host_env": "health.staircaseapi.com", "succeeded": "21", "failed": "5", "total": 26 } ], "Next_token": " " } } ``` application/json Copy Error response ``` { "message": "error: end_date is a required field" } ``` text/html Copy Error response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `start_date` required | `string` query | `2021-04-01` | Filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `end_date` required | `string` query | `2021-05-30` | Filters by end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `environments` | `string` query | `account.staircaseapi.com,health.staircaseapi.com` | List of host environment to filter, the report will bring all environments if this input is not available. Only configured environments will be included in the reports. | | `products` | `string` query | `employment,income` | List of product names to filter, the report will bring all product names if this input is not available. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Response `200``application/json` 1 fields Example Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | report | | `Items` | `object[]` | Items | | `total` | `integer` | Total | | `host_env` | `string` | Environment | | `product_name` | `string` | Product name | | `succeeded` | `string` | Succeeded | | `failed` | `string` | Failed | | `Next_token` | `string` | Next token pagination purpose | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Internal server error | `GET` `/partner_report` #### Retrieve Partner Report `get_report_partner_report` This report retrieves the number of transactions and the last operation status by partner in the given timeframe period. The Mortgage products operations with a data partner are registered from the beginning of the transaction until it is completed. This report retrieves the number of transactions and the last operation status by partner in the given timeframe period. The data will be aggregated between all environments registered. See this link for more information. ##### Response 200400403 application/json Copy Success Response ``` { "report": { "Items": [ { "product_name": "employment", "partner": "atomic", "total_by_status": { "STARTED": 1, "IN_PROGRESS": 3, "COMPLETED": 1 }, "total": 5 }, { "product_name": "income", "partner": "truework", "total_by_status": { "STARTED": 1, "COMPLETED": 2, "CANCELLED": 1 }, "total": 4 }, { "product_name": "employment", "partner": "truework", "total_by_status": { "STARTED": 2, "COMPLETED": 3, "CANCELLED": 6 }, "total": 11 }, { "product_name": "employment", "partner": "citadel", "total_by_status": { "STARTED": 1, "IN_PROGRESS": 4 }, "total": 5 }, { "product_name": "employment", "partner": "argyle", "total_by_status": { "IN_PROGRESS": 5 }, "total": 5 }, { "product_name": "employment", "partner": "verix", "total_by_status": { "COMPLETED": 6 }, "total": 6 } ] } } ``` application/json Copy Auto generated using Swagger Inspector ``` { "message": "error: end_date is a required field" } ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `start_date` required | `string` query | `2021-05-01` | Filters the data by a range of dates starting with this date. Date must be in ISO8601 format: YYYY-MM-DD | | `end_date` required | `string` query | `2021-05-31` | Filters the data until this date. Date must be in ISO8601 format: YYYY-MM-DD | | `environments` | `string` query | `documentation.staircaseapi.com` | List of host environment to filter, the report will bring all environments if this input is not available. Only configured environments will be included in the reports. | | `products` | `string` query | `employment,income` | List of product names to filter, the report will bring all product names if this input is not available. | | `group_by` | `string` query | `request_collection_id` | Option to retrieve unique transactions by field transaction_id, request_collection_id or response_collection_id. | | `partners` | `string` query | `atomic,citadel` | The name of the data partners in Mortgage products. | | `x-api-key` | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Key | ##### Response `200``application/json` 1 fields Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | Report | | `Items` | `object[]` | Items | | `total` | `integer` | Total | | `partner` | `string` | Partner | | `product_name` | `string` | Product name | | `total_by_status` | `object` | Total | | `COMPLETED` | `integer` | Operation status | ##### Response `400``application/json` 1 fields Auto generated using Swagger Inspector | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `504``application/json` 1 fields 504 Timeout response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint request timed out | `GET` `/product_by_operation_status` #### Retrieve Product by Operation Status Report `get_report_product_by_operation_status` This report retrieves the number of transactions and the last operation's status for the given timeframe period. Every single Staircase service endpoint (such as POST /persistence/transactions or POST /aus/underwrite) is required to provide operation status updates to denote the progress of a transaction in its execution. For more information and examples see this link This report retrieves the number of transactions and the last operation's status for the given timeframe period. ##### Response 200400 Error Response Example400 text/html403 application/json Copy Example Success Response ``` { "report": { "Items": [ { "product_name": "get-code-clone", "host_env": "health.staircaseapi.com", "total_by_status": { "STARTED": 11, "IN PROGRESS": 21 }, "total": 32 } ] }, "next_token": "eyJOZXh0VG9rZW4iOiAiQVJ0Zkl4L2QvOVdnRUpBTFJidWNQU0c0MVhrS3lTVURJU3JobCt3dHEvaUZxM3NNa0R2S3NSS0pVdmh4RVZQME5CRzBtS2lGTnF0ZGZlMTBpS3RsM09EZTBSZ0I0OS8rbXc9PSIsICJRdWVyeUV4ZWN1dGlvbklkIjogIjFhYzgwMDUyLTgwNzktNDA4YS04OWU3LTlmM2Q4NWEzZWVjMSJ9" } ``` application/json Copy Error response ``` { "message": "error: end_date is a required field" } ``` text/html Copy Error response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `start_date` required | `string` query | `2021-04-01` | Filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `end_date` required | `string` query | `2021-05-30` | Filters by end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `environments` | `string` query | `account.staircaseapi.com,health.staircaseapi.com` | List of host environment to filter, the report will bring all environments if this input is not available. Only configured environments will be included in the reports. | | `products` | `string` query | `employment,income` | List of product names to filter, the report will bring all product names if this input is not available. | | `group_by` | `string` query | `request_collection_id` | Option to retrieve unique transactions by field transaction_id, request_collection_id or response_collection_id. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Response `200``application/json` 1 fields Example Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | Report | | `Items` | `object[]` | Items | | `total` | `integer` | Total | | `host_env` | `string` | Environment | | `product_name` | `string` | Product Name | | `IN PROGRESS` | `string` | Operation Status | | `STARTED` | `string` | Operation Status | | `Next_token` | `string` | Next token pagination | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Internal server error | `GET` `/product_unique_transactions_report` #### Retrieve Unique Transactions By Product Report `get_report_product_unique_transactions_report` This report brings the total number of unique transactions by status and a breakdown per day. This report brings the total number of unique transactions by status and a breakdown per day. We can have multiple metrics registered for the same transaction, this report will bring unique transaction id count. You can get the following information about your products by using this report: - The transactions processed per product. - The transactions that were processed by a service endpoint and succeeded. - The transactions that were processed by a service endpoint and reported an exception or error. ##### Response 200400 Error Response Example400 text/html403 application/json Copy Example Success Response ``` { "report": { "Items": [ { "product_name": "Health", "host_env": "account.staircaseapi.com", "total_unique_transactions": 71, "failed": 0, "succeeded": 71, "per_day": [ { "day": "2021-05-24", "succeeded": 7, "unique_transactions": 7 }, { "day": "2021-05-25", "succeeded": 31, "unique_transactions": 31 }, { "day": "2021-05-26", "succeeded": 12, "unique_transactions": 12 }, { "day": "2021-05-27", "succeeded": 8, "unique_transactions": 8 }, { "day": "2021-05-28", "unique_transactions": 0 }, { "day": "2021-05-29", "unique_transactions": 0 }, { "day": "2021-05-30", "unique_transactions": 0 }, { "day": "2021-05-31", "unique_transactions": 0 }, { "day": "2021-06-01", "succeeded": 6, "unique_transactions": 6 }, { "day": "2021-06-02", "succeeded": 7, "unique_transactions": 7 } ] } ] }, "next_token": "DUyLTgwNzktNDA4YS04OWU3LTlmM2Q4NWEzZWVjMSJ9" } ``` application/json Copy Error response ``` { "message": "error: end_date is a required field" } ``` text/html Copy Error response ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `start_date` required | `string` query | `2021-04-01` | Filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `end_date` required | `string` query | `2021-05-30` | Filters by end_date. Date must be in ISO8601 format: YYYY-MM-DD | | `environments` | `string` query | `account.staircaseapi.com,health.staircaseapi.com` | List of host environment to filter, the report will bring all environments if this input is not available. Only configured environments will be included in the reports. | | `products` | `string` query | `employment,income` | List of product names to filter, the report will bring all product names if this input is not available. | | `next_token` | `string` query | `000000000000` | The token for the next set of items to return. (You received this token from a previous call. If you have reached the end of the stream, the returned token is null.) | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Response `200``application/json` 1 fields Example Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | Report | | `Items` | `object[]` | Item | | `total_unique_transactions` | `integer` | Total | | `host_env` | `string` | Environment | | `per_day` | `object[]` | Total per day | | `day` | `string` | Date | | `unique_transactions` | `integer` | Total per day | | `succeeded` | `integer` | Total Succeeded per day | | `product_name` | `string` | Product name | | `Next_token` | `string` | Next token pagination | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Internal server error | `GET` `/cost-report-day` #### Retrieve Cost Report Grouped by day `get_cost_report_by_day` Retrieve Cost Report Grouped by day. ##### Response 200400 0400 2400 3403 application/json Copy Example Success Response ``` { "report": { "data": { "cost_category": "customer", "total_cost": 10958155, "total_transaction_count": 115349, "dates": [ { "date": "2021-12-04", "total_cost": 151240, "total_transaction_count": 1592, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 151240, "total_transaction_count": 1592, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 151240, "total_transaction_count": 1592 } ] } ] }, { "date": "2021-12-05", "total_cost": 303810, "total_transaction_count": 3198, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 303810, "total_transaction_count": 3198, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 303810, "total_transaction_count": 3198 } ] } ] }, { "date": "2021-12-06", "total_cost": 534375, "total_transaction_count": 5625, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 534375, "total_transaction_count": 5625, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 534375, "total_transaction_count": 5625 } ] } ] } ] } } } ``` application/json Copy Error response ``` { "message": "error: cost_category is a required field" } ``` application/json Copy Error response ``` { "message": "error: product_name is a required field" } ``` application/json Copy Error response ``` { "message": "error: start_date is a required field" } ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `end_date` required | `string` query | `2021-10-18` | end_date | | `products` | `string` query | `employment,income` | List of product names to filter | | `cost_category` required | `string` query | `customer` | Cost Category (customer, partner) | | `start_date` required | `string` query | `2021-10-12` | start_date | | `environments` | `string` query | `account.staircaseapi.com,health.staircaseapi.com` | List of host environment to filter, the report will bring all environments if this input is not available. Only configured environments will be included in the reports. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Response `200``application/json` 1 fields Example Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | Response object | | `Items` | `object[]` | Array of Items | | `cost_in_cents` | `string` | Cost in USD cents. | | `day` | `string` | The date. | | `product_name` | `string` | Product_name | | `cost_category` | `string` | Cost Category | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Internal server error | `GET` `/cost-report-month` #### Retrieve Cost Report of a given month `get_cost_report_month` Retrieve Cost Report of a given month. ##### Response 200400 0400 1403 application/json Copy Example Success Response ``` { "report": { "data": { "cost_category": "customer", "total_cost": 11133050, "total_transaction_count": 117190, "dates": [ { "date": "2021-12", "total_cost": 11133050, "total_transaction_count": 117190, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 11133050, "total_transaction_count": 117190, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 11133050, "total_transaction_count": 117190 } ] } ] } ] } } } ``` application/json Copy Error response ``` { "message": "error: month is a required field" } ``` application/json Copy Error response ``` { "message": "error: cost_category is a required field" } ``` application/json Copy 403 response ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `month` required | `string` query | `10` | Month | | `products` | `string` query | `employment,income` | List of product names to filter | | `cost_category` required | `string` query | `customer` | Cost Category (customer, partner) | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Response `200``application/json` 1 fields Example Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | Response object | | `Items` | `object[]` | Array of Items | | `cost_in_cents` | `string` | Cost in USD cents. | | `day` | `string` | The date. | | `product_name` | `string` | Product_name | | `cost_category` | `string` | Cost Category | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 response | Field | Type | Description | | --- | --- | --- | | `url` | `string` | URL | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields 500 response. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Internal server error | `GET` `/cost-report` #### Retrieve Cost Report of a given interval `get_cost_report` Retrieve Cost Report of a given interval. ##### Response 200400 0400 1400 3 application/json Copy Example Success Response ``` { "report": { "data": { "cost_category": "customer", "total_cost": 2081260, "total_transaction_count": 21908, "dates": [ { "date": "2021-12-24", "total_cost": 913235, "total_transaction_count": 9613, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 913235, "total_transaction_count": 9613, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 913235, "total_transaction_count": 9613 } ] } ] }, { "date": "2021-12-25", "total_cost": 783940, "total_transaction_count": 8252, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 783940, "total_transaction_count": 8252, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 783940, "total_transaction_count": 8252 } ] } ] }, { "date": "2021-12-26", "total_cost": 384085, "total_transaction_count": 4043, "environments": [ { "environment_name": "health.staircaseapi.com", "total_cost": 384085, "total_transaction_count": 4043, "products": [ { "product_name": "Health", "cost_in_cents": 95, "total_cost": 384085, "total_transaction_count": 4043 } ] } ] } ] } } } ``` application/json Copy Error response ``` { "message": "error: end_date is a required field" } ``` application/json Copy Error response ``` { "message": "error: cost_category is a required field" } ``` application/json Copy Error response ``` { "message": "error: product_name is a required field" } ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `end_date` required | `string` query | `2021-10-18` | end_date | | `products` | `string` query | `employment,income` | List of product names to filter | | `cost_category` required | `string` query | `customer` | Cost Category (customer, partner) | | `start_date` required | `string` query | `2021-10-12` | start_date | | `date_range_type` | `string` query | `daily` | Allows grouping costs by selected date type. | | `environments` | `string` query | `account.staircaseapi.com,health.staircaseapi.com` | List of host environment to filter, the report will bring all environments if this input is not available. Only configured environments will be included in the reports. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key | ##### Response `200``application/json` 1 fields Example Success Response | Field | Type | Description | | --- | --- | --- | | `report` | `object` | Response object | | `Items` | `object[]` | Array of Items | | `cost_in_cents` | `string` | Cost in USD cents. | | `day` | `string` | The date. | | `product_name` | `string` | Product_name | | `cost_category` | `string` | Cost Category | ##### Response `400``application/json` 1 fields Error response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ## Canonical model - `address` - `address` ## Property data it reads - address ## Errors `400``403``404``422``500``502``504` ## More in Shipping - Previous product: Deploy - Next product: Pipeline --- # Pipeline # Pipeline The orchestration primitive that runs the shipping stages as one sequence. The stages exist as separate products — Code, Assess, Build, Deploy, Comply and publication through Marketplace — and this is the thing that runs them in order, as a single automated action against a repository. Keeping the stages independently callable and the sequence separate is what allowed a stage to be run alone. Re-running assessment against a repository without deploying it is a normal operation, not a special mode. What is recorded is the action itself plus the deployment surface behind it — creating a pipeline, deploying it, and the dynamic form that deploys one built for a specific service. ## Operations ### Action `POST` `/run-action` #### Run Action `run_action` Run Action. #### Run Action ##### Other responses `201` ### Operations `POST` `/deployment` #### Run deployment to root Run deployment process for given service from branch to the root account ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `branch`required | `string` | Git branch to use | | `environment`required | `string` | can be dev or test | | `project`required | `string` | name of project(repository name) | ##### Response `201``application/json` 3 fields Deployment created | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of triggered deployment | | `message` | `string` | Information about deployment | | `execution_id` | `string` | ID of deployment using which user can retrieve status | `GET` `/deployment/{execution_id}/status` #### Get deployment status Get deployment status for the deployment to any account using execution_id ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `execution_id` required | `string` path | — | ##### Response `200``application/json` 2 fields Status for provided execution | Field | Type | Description | | --- | --- | --- | | `deployment_status` | `string` | Status of deployment | | `description` | `string` | Deployment description | ##### Response `400``application/json` 2 fields Provided execution id does not exists | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `description` | `string` | Error description | `POST` `/dynamicDeployment` #### Run deployment on given account Run deployment process for given service from branch at any accoun ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `branch`required | `string` | use github sha commit | | `project`required | `string` | name of project(repository name) | | `bucket`required | `string` | name of bucket where place artifacts for sandbox:sandbox-account-artifacts | | `bundle_id`required | `string` | sha commit | | `accessKey`required | `string` | access key for account, ask devops for providing keys | | `secretKey`required | `string` | secret key for account, ask devops for providing keys | ##### Other responses `200` `POST` `/v3/deployments` #### Start deployment pipeline Deploy service to a given account ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `project_name`required | `string` | name of github repository | | `access_key`required | `string` | environment credentials | | `secret_key`required | `string` | environment credentials | | `env` | `string` | — | | `branch` | `string` | branch to be deployed if different from master | | `domain_name`required | `string (hostname)` | domain name of the environment to deploy | ##### Response `201``application/json` 1 fields Pipeline execution created | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | — | ##### Other responses `400` `GET` `/v3/deployments/{bundle_id}` #### Get status of current deployment ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `bundle_id` required | `string (uuid)` path | — | ##### Response `200``application/json` 2 fields Deployment status | Field | Type | Description | | --- | --- | --- | | `bundle_id` | `string (uuid)` | — | | `status` | `string` | — | ##### Other responses `404` ## Errors `400``404` ## More in Shipping - Previous product: Health --- # How this was built # How this was built A fixed five-artifact shape for every vendor integration, a build rule that failed any endpoint without documentation, and a generator for new jurisdictions. Three machines, each doing the same thing in a different domain: fixing the shape of a unit of work so that adding the next one costs less than the last. The integration factory fixed the shape of a vendor. The build rule fixed the shape of a service. The jurisdiction generator fixed the shape of a data source. ## The integration factory A vendor integration is five artifacts in a fixed shape, none of which touches product code. - **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. ## Translation, the artifact that makes one contract serve every vendor A translation is declared, not coded. Each one names four vocabularies: what the canonical model sends in, what the vendor's request expects, what the vendor's response returns, and what comes back out as canonical. Each row below is one such declaration, read from the committed configuration for that integration. The consequence is that a required-field rule stated once at the model propagates into every caller's own field names. A caller working in its own dialect receives the validation error against its own paths, with no per-caller implementation, and a product's contract never changes when a vendor is added. | Provider | Flow | Canonical in | Vendor in | Vendor out | Canonical out | Lender credentials | | --- | --- | --- | --- | --- | --- | --- | | Argyle | `income` | `staircase-graph` | `income-input` | `income-argyle-output` | `staircase-graph` | supported | | Essent | `essent-insurance-flow` | `staircase-graph` | `essent-input` | `essent-output` | `staircase-graph` | not enabled | | Plaid | `asset` | `staircase-graph` | `asset-input` | `asset-plaid-output` | `staircase-graph` | not enabled | | Xactus | `credit-verify` | `staircase-graph` | `credit-input` | `credit-mismo231` | `staircase-graph` | — | A language configuration carries a ruleset in each direction, rules with stable identifiers, and an error-message mapping — so two vendors returning different codes for the same condition surface as one code to the caller. Test requirements are part of the contract: a case per rule, a case per enumeration value, warning assertions, coverage assertions, and validation of the resulting canonical collection against the model. Bulk translation runs on Spark. The recorded measurement is 7,848 translations in 299 seconds across 20 executors. ## The endpoint documentation rule A rule in the build gate failed any build containing an endpoint that did not appear in its own specification. Not a warning, not a report — a failed build. Every service therefore carries a specification that matches what it actually serves, at a canonical path. A documentation rule enforced by the build is a different thing from a documentation culture. One of them survives six years without anybody maintaining it. The gate itself: Assess · the pipeline it runs in: Build ## How the waterfall runs - A vendor that answers asynchronously by webhook resumes the same execution as one that answers synchronously. The waterfall does not distinguish between them. - On a vendor failure with attempts remaining, a new result collection is persisted, stamped with the vendor name and a failure result, before the next vendor is tried. The complete sequence of who was tried, in what order, and what each returned is queryable after the fact rather than reconstructed from logs. - A lender routes through Staircase's own vendor contract or supplies its own credentials, per vendor, with no code change. - Every invocation carries a dry-run branch, and individual vendor flows carry their own dry-run state returning a recorded fixture. ## The jurisdiction generator The same discipline, pointed at public records. One sample page in, an extraction pipeline out, validated against the same canonical classes every other jurisdiction uses. Coverage stops being a vendor negotiation and becomes a compute question. 1. One sample page in — A single record from the jurisdiction's own portal is the whole input. No schema negotiation, no vendor conversation, no bulk file. 1. Retrieve the worked examples — Every jurisdiction already solved is retrieved as a worked example, so the marginal cost of the five-hundredth source approaches the marginal cost of the fifth. 1. An agent writes the extraction pipeline — The output is a jurisdiction-specific extraction pipeline, not a one-off scrape — versioned, testable, and re-runnable. 1. Validate against the canonical model — Extracted records are validated against the published class definitions before they enter the dataset, so a new jurisdiction cannot introduce a shape no downstream consumer understands. 1. Publish as a queryable, agent-callable surface — The jurisdiction becomes a query table an agent can reach directly, and a completeness report says what it does not have. The onboarding contract is five scripts per jurisdiction — owner, structure, layout and utility mapping, then an assembler that reads the raw capture plus those four outputs and writes the canonical record set. The four mappings run in parallel; the assembler runs last. The scripts are generated. A graph agent reads one sample page plus the seed address record and writes the five, then the output is validated against the class schemas and the resulting error list is fed back in as context for the next attempt. The recorded cost of a generation run is about an hour of wall clock and roughly 10 dollars of tokens. Generation retrieves from jurisdictions already solved: every function in the existing transform corpus is indexed by embedding, so authoring the next jurisdiction's structure mapping starts from the closest working implementations rather than from nothing. Enumerations are the failure surface. A generated script throws on an unmapped source value rather than assigning a default, which is what keeps a plausible wrong value out of the dataset. ## Where it reaches today Coverage is reported from the deployed configuration rather than from a record count. A jurisdiction appears here when a configuration names it; a surface it does not name is absent rather than estimated. Property records and permits are separate surfaces with separate coverage. Permits are issued by municipalities rather than counties, so a jurisdiction serving property records does not automatically serve permits, and the two are reported apart. | Jurisdiction | State | Property records | Permits | | --- | --- | --- | --- | | Lee | Florida | served | — | | Palm Beach | Florida | served | — | | Miami-Dade | Florida | served | — | | Orange | Florida | served | — | | Santa Clara | California | served | served | ### Florida, as the reference case for coverage The Florida jurisdictions above are what a served market looks like: records validated against the canonical classes, a query surface an agent calls directly, and completeness reported per source rather than assumed. A tool that says what it does not have is the strongest available credibility signal, and it is already how this surface behaves. ### Texas, as the reference case for the mechanism No Texas jurisdiction is configured. Serving one means running the same five steps above against a jurisdiction with no committed configuration behind it, which is what entering a market costs when the constraint is data rather than desire. --- # Staircase ## Data ### Mortgage model - address - credit - document - employment - employment_income - fee - finance_relation - income - insurance - loan - mortgage_application - mortgage_plan - payment - person - person_credit - person_income - pricing_schema - property - property_tax - tax ### Property model - property_seed - unnormalized_address - address - parcel - person - property - tax - tax_jurisdiction - tax_exemption - lot - sales_history - file - layout - flood_storm_information - structure - property_improvement - utility - deed - geometry - appliance - homeowners_association - hoa_policy - loan - property_ranking_overall - inspection - environment_characteristics - safety_security - transportation_access - school - tax_authority ## Products ### Verification Is what the borrower told us true? - Asset - Credit - Employment - Identity - Income - Tax ### Assessment What is the collateral, and what is it worth? - Appraisal - Listing - Property - Tax - Valuation ### Eligibility Will someone buy this loan? - Compliance - Fraud - Government - Insurance - Rating ### Contract What are the documents and the numbers? - Document - Electronic - Fee - Insurance - Lexicon - Notary - Price - Signature - Title ### Automation Move the loan without a human. - Approval - Boarding - Income ### Integration Reach the systems of record. - Closing - LOS - POS - Servicing ### Validation Are the artifacts we produced correct? - Appraisal - Document - Title ### Adapters Connect to the loan origination system itself. - LOS ## Providers ### Asset verification - Equifax - Finicity - Plaid ### Credit - CBC / Factual Data - Equifax - Informative Research - MeridianLink - Sharper Lending - Xactus ### Document AI / OCR / extraction - Ephesoft - Mindee - Ocrolus - SoftworksAI ### Employment / Income verification - Argyle - Atomic - Citadel - Equifax - Experian - Finicity - Pinwheel - Truework - Truv - Wage ### GSE / AUS - Fannie Mae - Freddie Mac - Wilqo ### Identity - MeridianLink - Prove ### LOS / origination platforms - Blend - Byte Software - ICE Mortgage Technology - LendingPad - Sales Boomerang ### Mortgage insurance - Arch MI - Enact - Essent - MGIC - National MI - Radian ### Pricing / PPE - Optimal Blue ### Property / valuation - RPR ### Servicing - Valon ### Title / closing / notary / signature - DocuSign - Docutech - Stavvy ## Delivery ### Distribution What happens to a build before somebody can call it? - Access - Console - Environment - Finance - Host - Marketplace - Setup ### Shipping How does code get from a repository to a running service? - Assess - Build - Code - Comply - Deploy - Health - Pipeline ## Platform ### Data Where does the canonical record live, and what shapes it? - Content - Language - ML - Persistence - Rule - Site - Turker ### Integration How does a product reach a vendor, and how does it run? - Connection - Job - Product - Workflow ## Agents ### Surfaces - The network - Skills - Registry - Tools - Fleet - Evaluations - Runtimes ### Routing - Router ### Data - Counterparty document expectations - Data-lake assistant - Dataset fulfilment - Knowledge search - Metric reconciliation - Model curator - Pipeline control panel - Property data exploration - Public record ingestion - Question answering - Report catalog - Search to production ### Products - Application document - Assets - Co-borrower invitation - Contact details - Correction - Credit - Declarations - Demographic details - Employment and income - Frequently-asked questions - Gifts and grants - Liabilities - Loan lookup - Military service - Mortgage details - Other income - Personal identity - Preapproval letter - Pricing - Rate estimate - Real estate owned - Residency - Self-employment income - Workspace assistant ### Providers - File sync - Marketing stack - Roster workflow - Send lifecycle ### Delivery - Analytics instrumentation - Application scaffolding - Design implementation - Design testing - Interface triage - Marketplace architecture - Sharing portals ### Platform - Audience selection - Batch workflows - Capability map - Channel assembly - Contact scheduling solver - Conversation management - Conversation runtime - Mail campaign operations - Message assistant - Rule editor - Short links - Solver services - Template inventory ### Creating new agents - Assistant builder - Audit analyser - Operations agent builder - Spend approval --- # Platform # Platform The data and integration substrate every other product is built on. Two categories. Data holds the graph store, the translation layer, the rules engine, the models and the documentation platform. Integration holds the vendor connector layer, the job scheduler and the registry that defines other products. Nothing in this family is sold on its own. It is the layer the mortgage and delivery products are assembled from, documented because the shape of the layer explains the shape of everything above it. - Connection - Content - Job - Language - ML - Persistence - Product - Rule - Site - Turker - Workflow --- # Data # Data The data substrate: the graph store, the translation layer, the rules engine, the models and the documentation platform. Where does the canonical record live, and what shapes it? Everything above this family reads and writes through it. The graph store holds the canonical record with immutable state, so every version of an entity survives and history is a query rather than an audit table. The translation layer maps any caller's own field vocabulary onto the canonical model in both directions. The rules engine expresses the conditions that eligibility and validation test, as data rather than as code. The remaining products serve the surfaces around those three: document and image models, the content store, the human-review queue, and the documentation platform that generated the developer reference from the ontology. ## Products In the order the value chain runs. 1. Content has a recorded specification 1. Language has a recorded specification 1. ML has a recorded specification 1. Persistence has a recorded specification 1. Rule has a recorded specification 1. Site has a recorded specification 1. Turker --- # Content # Content The content store and delivery layer behind the documentation and marketing surfaces. Content is held separately from the applications that render it, so a page's text is edited without a deployment. Site reads from it for product overviews and quickstarts; the marketing surfaces read from it for everything else. Keeping content out of the build is what allowed documentation edits to move at a different speed from code, which is the only speed that works for either. One endpoint is recorded against it, which is the honest measure of how thinly this slot was documented rather than of how much it did: the marketing site and the documentation surface both read from the same content service, and neither of them wrote its contract down. ## Operations ### Operations `GET` `/getting-started` #### Content for getting-started section Get content for getting started section ##### Response `200``application/json` 1 fields Content successfully sent | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ## Errors `403` ## More in Data - Next product: Language --- # Language # Language Bidirectional translation between a caller's own field vocabulary and the canonical model, at single-record and bulk scale. A language is a registered mapping. Language carries the registry, generates and validates rulesets, translates records in both directions, and exposes graph queries in a form a caller can send as structured data rather than as a query language. Bulk translation runs on a Spark cluster. The measurement on record is 7,848 translations in 299 seconds across 20 executors. ## How it works This is the mechanism behind any caller keeping its own field names without per-caller code. A vendor's vocabulary and a lender's vocabulary are the same kind of object here — both are registered languages over the same model — which is why the agency mappings sit in the registry alongside the customer ones. The payoff shows up in validation. A required-field rule declared once at the model surfaces to each caller against that caller's own paths, because the translation runs over the error as well as over the data. ## Operations ### Lexicon `POST` `/build-payload` #### Build Payload `buildPayload` Build Payload builds a payload based on provided JSONPaths and values. ##### Request application/json Copy ``` { "$.deal_sets[0].parties[0].individual.first_name": "John", "$.deal_sets[0].parties[0].roles[0].party_type": "Borrower", "$.deal_sets[0].parties[0].roles[0].employers[0].legal_entity_name": "Truework Inc", "$.deal_sets[0].parties[0].taxpayer_identifiers[0].value": "999-00-0000" } ``` ##### Response 200400403 application/json Copy 200 response ``` { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": "John" }, "roles": { "role": [ { "role_detail": { "party_type": "Borrower" }, "borrower": { "employers": { "employer": [ { "legal_entity": { "legal_entity_detail": { "full_name": "Truework Inc" } } } ] } } } ] }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "type": "EmployerIdentificationNumber", "value": "999-00-0000" } ] } } ] } } ] } } ] } } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Other responses `200` `PUT` `/lexicon` #### Create/Update Staircase Lexicon `createUpdateStaircaseLexicon` Create/Update Staircase Lexicon - for translation between versions Create/Update Staircase Lexicon replaces mappings for a staircase-to-staircase language. Replaces previously created mappings - can be in .csv or .json format. - Lexicon naming based on sc_version_from, sc_version_to params: - For .csv-based languages - use query parameters. ``` Example: ?sc_version_from=0&sc_version-to=2 ``` - For .json-based languages - use .json payload. ``` Example: sc_versions: {sc_version_from: 0, sc_version_to: 2} ``` Translates between Staircase language versions, and is internally named VX_TO_VY - where X is lower, Y is higher version. FromPath and ToPath definitions are defined by sc_version_from and sc_version_to in lexicon definition. Show the rest Example: Lexicon: V0_TO_V2 Lexicon writer initially writes a lexicon from V0 to V2 - in this case sc_version_from = 0, sc_version_to = 2. Later, wants to add detail, etc. and defines lexicon from V2 to V0. In this case, new lexicon overwrites existing one with same name: V0_TO_V2 - in this case, however, internal definition shows sc_version_from = 2 and sc_version_to = 0. During runtime, incoming payload indicates sc_version_from and sc_version_to. Forward translation is done if versions match, reverse translation otherwise. When retrieving Lexicon - must pay close attention to directionality contained within language definition to determine how lexicon was originally written. Guide for building a .csv-based language Guide for building a .json-based language Retrieve a pre-built language to understand how they are constructed. If the language is given in .csv format, which is more straightforward and can be built by a business analyst, Translator converts the .csv file into the more technical .json format. ##### Request application/json Copy ``` { "content_type": "application/json", "mapping": { "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].date": "$.bundle[0].date", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].high_value_range": "$.bundle[0].upper", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range": "$.bundle[0].lower", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].value": "$.bundle[0].zestimate" }, "values_mapping": [ { "element": "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range", "mapping": [ { "language_value": "FooBar", "staircase_value": "HelloWorld" }, { "language_value": "WorldHello", "staircase_value": "BarBaz" } ] } ], "sc_versions": { "sc_version_from": 0, "sc_version_to": 2 } } ``` ##### Response 400403 application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `sc_version_from` required | `integer` query | `1` | .csv-only - staircase-to-staircase language - from version | | `sc_version_to` required | `integer` query | `1` | .csv-only - staircase-to-staircase language - to version | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `mapping`required | `object` | Mapping object | | `values_mapping`required | `object[]` | Value mapping array | | `element`required | `string` | Value mapping element | | `mapping` | `object[]` | Value mapping array | | `staircase_value`required | `string` | Staircase value string | | `language_value`required | `string` | Language value string | | `unique_arrays` | `object` | Key-value pairs, where key is JSONPath to array of objects, and value is key, that has been unique | | `merge_arrays` | `object` | Key-value pairs, where key is JSONPath to array which will contain merged elements, and value is an array, which contains JSONPaths to arrays that should be excluded from result and all their elements should be included to the JSONPath specified as a key. | | `content_type`required | `string` | Content type string | | `sc_versions`required | `object` | Staircase version object | | `sc_version_from`required | `integer` | Staircase version from | | `sc_version_to`required | `integer` | Staircase version to | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Other responses `204``422``500` `GET` `/elements/{element_path}` #### Retrieve Mappings for Element `retrieveMapping` Retrieve Mappings for Element retrieves a list of mappings across all available languages for the specified element. ##### Response 200400403 application/json Copy List of mappings ``` { "lang-name": "$utils.split('$.address', ' ')[1]", "lang-name2": "$.address" } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `element_path` required | `string` path | `%24.deal_sets%5B0%5D.collaterals%5B0%5D.address.city` | (*URLEncoded*)[] JSONPath to element is Staircase language | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Other responses `200` `GET` `/lexicon` #### Retrieve Single Staircase Lexicon `retrieveSingleStaircaseLexicon` Retrieve Single Staircase Lexicon retrieves a Staircase lexicon name, mapping, and content type. A lexicon translates between Staircase language versions, and is internally named VX_TO_VY - where X is lower, Y is higher version. FromPath and ToPath definitions are defined by sc_version_from and sc_version_to in lexicon definition. Example: Lexicon: V0_TO_V2 Lexicon writer initially writes a lexicon from V0 to V2 - in this case sc_version_from = 0, sc_version_to = 2. Later, wants to add detail, etc. and defines lexicon from V2 to V0. In this case, new lexicon overwrites existing one with same name: V0_TO_V2 - in this case, however, internal definition shows sc_version_from = 2 and sc_version_to = 0. During runtime, incoming payload indicates sc_version_from and sc_version_to. Forward translation is done if versions match, reverse translation otherwise. When retrieving Lexicon - must pay close attention to directionality contained within language definition to determine how lexicon was originally written. ##### Response 200400403404 application/json Copy Language ``` { "name": "string", "mapping": { "$.foo": "$.bar", "$.biz": "$.baz" }, "mapping_info": { "language_elements": { "coverage": "string", "mapped_count": 0, "unmapped_count": 0, "unmapped": [ "string" ] }, "staircase_elements": { "coverage": "string", "mapped_count": 0, "unmapped_count": 0, "unmapped": [ "string" ] } }, "values_mapping": [ { "element": "string", "mapping": [ { "staircase_value": "string", "language_value": "string" } ] } ], "required_fields": { "language_elements": [ "string" ], "staircase_elements": [ "string" ] }, "sc_versions": { "sc_version_from": 0, "sc_version_to": 1 }, "content_type": "application/json" } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `sc_version_from` required | `integer` query | `2` | Staircase version from | | `sc_version_to` required | `integer` query | `2` | Staircase version to | ##### Response `200``application/json` 7 fields Language | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Name | | `mapping` | `object` | Mapping object | | `mapping_info` | `object` | Mapping info object | | `language_elements` | `object` | Mapping info object - language elements | | `coverage` | `string` | Element coverage | | `mapped_count` | `number` | Element mapped count | | `unmapped_count` | `number` | Element unmapped count | | `unmapped` | `string[]` | Element unmapped array | | `staircase_elements` | `object` | Staircase element object | | `coverage`required | `string` | Element coverage | | `mapped_count`required | `number` | Element mapped count | | `unmapped_count`required | `number` | Element unmapped count | | `unmapped`required | `string[]` | Element unmapped array | | `values_mapping` | `object[]` | Value mapping array | | `element`required | `string` | Value mapping element | | `mapping` | `object[]` | Value mapping element | | `staircase_value` | `string` | Value mapping staircase value | | `language_value` | `string` | Value mapping language value | | `required_fields` | `object` | Required fields object | | `language_elements`required | `string[]` | Language's elements array | | `staircase_elements`required | `string[]` | Staircase's elements array | | `sc_versions` | `object` | Staircase version | | `sc_version_from`required | `integer` | Staircase version from | | `sc_version_to`required | `integer` | Staircase version to | | `content_type` | `string` | Content type | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `422` ### Monitoring Dashboard `GET` `/dashboard/configurations` #### Get Dashboard Configurations `getDashboardConfigurations` **Retrieve registered dashboard configurations. ##### Response 400403404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Response `200``application/json` 3 fields Configurations retrieved successfully | Field | Type | Description | | --- | --- | --- | | `health_key` | `string` | Environment health key. | | `host_environment` | `string` | Environment domain name. | | `config_type` | `string` | Dashboard configuration type. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PUT` `/dashboard/configurations` #### Create Dashboard Configuration `createDashboardConfiguration` The primary function of this service is to facilitate the configuration of a dashboard that is specifically designed to monitor language products within a specified environment. The data required for monitoring will be retrieved through the utilization of a Health key and the information obtained will be presented using the Console product. For further clarification on the practical application of this service, kindly refer to the views that are maintained by the Language team. It should be noted that data will be fetched on a daily basis, with the worker commencing at precisely 07:00 am (UTC). ##### Request application/json Copy ``` { "health_key": "health-key", "host_environment": "lang.staircaseapi.com" } ``` ##### Response 201400403404422 application/json Copy Configuration response ``` { "message": "Configuration created." } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` application/json Copy The server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions. ``` { "message": "Ruleset with name 'atomic_staircase-graph_TRANSLATE' cannot be deleted while it has rules. Please, delete all rules first and try again." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `host_environment`required | `string` | Environment domain name. | | `health_key`required | `string` | Health key. | ##### Response `201``application/json` 1 fields Configuration response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint result message. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 1 fields The server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions. | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | `DELETE` `/dashboard/configurations/{host_environment}` #### Delete Dashboard Configuration `deleteDashboardConfiguration` This service removes configuration. ##### Response 200403404 application/json Copy Configuration response ``` { "message": "Configuration deleted." } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `host_environment` required | `string` path | `lang.staircaseapi.com` | Environment domain name | ##### Response `200``application/json` 1 fields Configuration response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint result message. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### EMR `POST` `/emr` #### Start EMR Translation `startEMRTranslation` Start new EMR translation ##### Request application/json Copy ``` { "input_bucket_name": "foo", "input_path": "data", "output_bucket_name": "bar", "from_language": "my_lang", "to_language": "lexicon" } ``` ##### Response 200400404 application/json Copy Successfully started the translation. ``` { "product_id": "test_product", "status": "operational" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Request body`application/json` 8 fields | Field | Type | Description | | --- | --- | --- | | `input_bucket_name`required | `string` | Bucket name where to take the input data from. | | `input_path`required | `string` | Prefix to data in the input bucket. | | `input_schema` | `object[]` | Fields names and datatypes. | | `Name` | `string` | Field name. | | `Type` | `string` | Field datatype.`bigint``boolean``double``string` | | `output_bucket_name` | `string` | Bucket name where to put the output data. Optional if datalake_name is provided. | | `from_language`required | `string` | Language to translate from. | | `to_language`required | `string` | Language to translate to. | | `datalake_name` | `string` | Mortgage data lake to use. Will be used to define output s3-location, tables for entities unification, and columns for output tables to save. | | `callback_url` | `string` | If specified, the URL will be called when Job is finished. We will send POST request to the URL with jobRunId, state and stateDetails in the request body as JSON. | ##### Response `200``application/json` 3 fields Successfully started the translation. | Field | Type | Description | | --- | --- | --- | | `applicationId`required | `string` | applicationId | | `jobRunId`required | `string` | jobRunId | | `arn`required | `string` | arn | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/fake` #### FakeEMR `FooBar` Fake foo ##### Response application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `204` `GET` `/emr/{job_id}` #### Get EMR Translation status `getEMRTranslation` EMR translation status ##### Response 200404 application/json Copy Data about the EMR translation ``` { "product_id": "test_product", "status": "operational" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string` path | `00fdj7a1e1ai000a` | Job ID | ##### Response `200``application/json` 6 fields Data about the EMR translation | Field | Type | Description | | --- | --- | --- | | `applicationId`required | `string` | ID of app | | `jobRunId`required | `string` | ID of current Job run | | `createdAt`required | `string` | Creation time of the job | | `updatedAt`required | `string` | Last update time of the job | | `state`required | `string` | Current state of the job | | `stateDetails`required | `string` | Details of the current state | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### MDL `POST` `/etl/jobs` #### Start MDL ETL JOB `startMDLETLJob` ##### Request application/json Copy ``` { "year": 2022, "month": 1, "day": 1, "datalake_name": "datalake" } ``` ##### Response 200400404 application/json Copy Successfully started the translation. ``` { "executionArn": "123" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `year` | `integer` | YearExample `2022` | | `month` | `integer` | MonthExample `1` | | `day` | `integer` | DayExample `1` | | `datalake_name` | `string` | Datalake NameExample `datalake` | ##### Response `200``application/json` 1 fields Successfully started the translation. | Field | Type | Description | | --- | --- | --- | | `executionArn`required | `string` | executionArn | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Languages `PUT` `/languages/{language_name}` #### Create or Update Language `updateLanguage` Create or Update Language replaces mappings for a specified language. All previously created mappings are removed, and new mappings are created. If a language with the specified name doesn't exist, this service will create it. In general, languages are either pre-built and stored in GitHub, or built directly by a customer. They can be in either .csv or .json format. Guide for building a .csv-based language Show the rest Guide for building a .json-based language Retrieve a pre-built language to understand how they are constructed. If the language is given in .csv format, which is more straightforward and can be built by a business analyst, Translator converts the .csv file into the more technical .json format. #### JSONPath syntax | JSONPath | Description | | --- | --- | | $ | the root object/element | | @ | the current object/element | | `. or []` | child operator | | `..` | recursive descent. JSONPath borrows this syntax from E4X. | | * | wildcard. All objects/elements regardless their names | | [] | subscript operator. XPath uses it to iterate over element collections and for predicates. In JavaScript and JSON it is the native array operator. | | [,] | Union operator in XPath results in a combination of node sets. JSONPath allows alternate names or array indices as a set. | | [start:end:step] | array slice operator borrowed from ES4. | | ? | applies a filter (script) expression. | | | script expression, using the underlying script engine. | More info and examples can be found here Also, you can specify constant values instead of JSONPath, for example: ``` { "name": "new_language", "mapping": { "$.value": "Some constant value" } } ``` Sometimes, you might need to set dyanmic JSONPath, that will be generated based on data, that you have passed, for this purpose you can use `{{ }}` syntax, so `` will be executed first against your data, f.e you create language like this: ``` { "mapping": { "$.foo": "$.data.{{ $.target_field }}" } } ``` So when translation begins, `$.target_field` will be queried, and result of this query will replace `{{ $.target_field }}`. For next input: ``` { "target_field": "bar", "data": { "bar": "baz" } } ``` You will get next result: ``` { "foo": "baz" } ``` You may also need to set up a mapping to only happen in a single direction. For example, only when translating to staircase or from staircase. In order to do this place the mapping into the appropriate section in "single_direction_mappings". The mapping itself should look the same. ``` { "single_direction_mappings": { "to_staircase": { "$.foo_only_to": "$.data.{{ $.target_field }}" }, "from_staircase": { "$.foo_only_from": "$.data.{{ $.target_field }}" } } } ``` Lastly you may want to pre-process your data before translation or post-process after translation. This is possible by setting up hooks. In order to use hooks you will need to create endpoints inside of your staircase environment and then link the paths to those endpoints in the mapping hooks property. For example, if your environment is you will set up an endpoint at and then set mapping_hooks to {"pre": "my/pre/hook"}. The domain will be added automatically. The pre hook will be sent the exact request payload that was sent to the "/translate" endpoint. The post hook will be sent the translated data as json with the result under the key "translation_result". ``` { "mapping_hooks": { "pre": "my/pre/hook", "post": "my/post/hook" } } ``` Also, we have some predefined `utils` that we can use in our mappings, just using `$utils.(*args)` List of currently supported utils: #### Join many elements to one string `$utils.join([*elements], character)` | Attribute | Type | Description | | --- | --- | --- | | elements | list of JSONPaths or constants | List of JSONPaths or constants, to elements to be joined | | character | string | Character for join provided elements | Note: Constants are items not starting with $ - are joined as-is. Return value: Joined string Example: ``` { "name": "util_language", "mapping": { "$utils.join(['$.address.line_text', '$.address.city', '$.address.state_code', '$.postal_code', 'USA'], ' ')": "$.address" } } ``` #### Split one element to many `$utils.split(element, separator)` | Attribute | Type | Description | | --- | --- | --- | | element | string | JSONPath to the element that should be split | | separator | string | separator | Return value: array of string Example: ``` { "name": "util_language", "mapping": { "$.deal_sets[0].collaterals[0].address.line_text": "$utils.split('$.address', ' ')[0]", "$.deal_sets[0].collaterals[0].address.city": "$utils.split('$.address', ' ')[1]", "$.deal_sets[0].collaterals[0].address.state_code": "$utils.split('$.address', ' ')[2]", "$.deal_sets[0].collaterals[0].address.postal_code": "$utils.split('$.address', ' ')[3]" } } ``` #### Slice String `$utils.slice(element, beginIndex, endIndex)` | Attribute | Type | Description | | --- | --- | --- | | element | string | JSONPath to the element to be sliced | | beginIndex | number | The zero-based index at which to begin extraction. | | endIndex | number | The zero-based index before which to end extraction. The character at this index will not be included. | #### Use first element that has a value defined `$utils.first_defined(elements)` | Attribute | Type | Description | | --- | --- | --- | | elements | list of JSONPathes | List of JSONPathes to elements, each path will be checked in order of list to find the first defined | Return value: value of first defined element or null Example: ``` { "name": "util_language", "mapping": { "$.name": "$utils.first_defined(['$.official_name', '$.first_name', '$.nickname'])", } } ``` #### String `$utils.if_value_in(element, values)` | Attribute | Type | Description | | --- | --- | --- | | element | string | JSONPath to the element, the value of this element will be checked against the values list | | values | list of strings | List of values deemed to be valid, if the element doesn't match any values it will return null | Return value: value of element if it's deemed valid or null Example: ``` { "name": "util_language", "mapping": { "$.deal_type": "$utils.if_value_in('$.type', ['type_a', 'type_b', 'type_c'])" } } ``` #### Transform values Specify `values_mapping` to transform values. Example: Use the keyword default for no match. Note: Feature is useful for one-way mapping - use caution when reverse-mapping from staircase back to language. ``` { "name": "values_mapping_language", "values_mapping": [ { "element": "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range", "mapping": [ {"staircase_value": "HelloWorld", "language_value": "FooBar"}, {"staircase_value": "BarBaz", "language_value": "WorldHello"}, {"staircase_value": "CatchAll", "language_value": "_default_"}, ], } ] } ``` Where element is JSONPath in staircase language, and mapping is list of values mapping for specified element #### Date handling Specify `normalize_date` to transform dates into standard yyyy-MM-dd format or `denormalize_date` to transform dates from this format. ``` { "mapping": {}, "single_direction_mappings": { "to_staircase": { "$.borrower_birth_date": "$utils.normalize_date('$.birthday', 'yyyy/MM/dd')" }, "from_staircase": { "$utils.denormalize_date('$.borrower_birth_date', 'yyyy/MM/dd')": "$.birthday" } } } ``` Date to be in in standard ISO: year: yyyy, month: MM, day: dd, hour: hh, hour24:HH, minute: mm, second: ss, ms: SSS etc. If it is a timestamp, specify "epoch" for date_format argument If it should parsed from any format (for normalize_date), specify "any" for date_format argument Letters T, Z and UTC to be stripped out prior to conversion. Example: yyyy-MM-dd HH:mm:ss.SSS for 2019-01-02T15:26:02.123Z UTC #### DateTime handling Specify `normalize_datetime` to transform dates/times into standard yyyy-MM-ddTHH.mm.ss.SSS-0X:00 format or `denormalize_datetime` to transform dates/times from this format. ``` { "mapping": {}, "single_direction_mappings": { "to_staircase": { "$.sample_datetime_field": "$utils.normalize_datetime('$.datetime_in', 'yyyy-MM-dd HH:mm:ss.SSS', 'UTC', 'ET')", "$.sample_datetime_field2": "$utils.normalize_datetime('$.datetime_in_epoch', 'epoch', 'UTC', 'ET')" }, "from_staircase": { "$utils.denormalize_datetime('$.sample_datetime_field', 'yyyy-MM-dd HH:mm:ss.SSS', 'ET', 'UTC')": "$.datetime_in" "$utils.denormalize_datetime('$.sample_datetime_field2', 'epoch', 'ET', 'UTC')": "$.datetime_in_epoch" } } } ``` $utils.normalize_datetime(target_field, input_datetime_format, fromTimezone, toTimezone) $utils.denormalize_datetime(target_field, output_datetime_format, fromTimezone, toTimezone) Date to be in in standard ISO or epoch If it should parsed from any format, specify "any" for input_datetime_format/output_datetime_format argument fromTimezone and toTimezone must be specified as "UTC","ET","CT","PT" Daylight Savings Time is calcuated based on target date, and will be returned based on target date year: yyyy, month: MM, day: dd, hour: hh, hour24:HH, minute: mm, second: ss, ms: SSS etc. Output date/time in ISO standard: yyyy-MM-ddTHH:mm:ss.SSS-0X:00 X = offset from UTC (i.e. 5 for EST / 4 for EDT) Example: ('$.datetime_in', 'yyyy-MM-dd HH:mm:ss.SSS','UTC','ET') - converts from UTC to ET Example: ($.datetime_in_epoch', 'epoch','UTC','ET') - converts from epoch - in UTC by definition - to ET #### Parse Float Specify `parse_float` to transform floats into standard format. Second value - number of digits past decimal. ``` { "name": "util_language", "mapping": { "$.float_value_result": "$utils.parse_float('$.float_value_input', '2')" }, } ``` to use with wildcards: ``` { "name": "util_language", "mapping": { "$.deal_sets.deal_set[0].deals.deal[0].assets.asset[*].cash_or_market_value_amount": "$utils.map(\'$.report.items[0].accounts[*].balances.current\',\'$utils.parse_float(item,2)\')" }, } ``` note: item is a keyword - and must be used as-is Parses float and trims digits past decimal to integer given - rounds as appropriate. Incoming float values can come in as either string ("234.556") or float (234.556). Outgoing values are numeric only. JSON does not differentiate between integer and float, as such, trailing zeros are trimmed. If a float is un-translatable, will be returned as null/None. Examples: | Input | DigitsPastDecimal | Result | | --- | --- | --- | | 234.567 | 2 | 234.57 | | Foobaar | 2 | None | | 234.567 | 6 | 234.567 | | 234 | 6 | 234 | #### Sum Numbers Specify `sum_numbers` to sum numbers and truncate/round as above. ``` { "name": "util_language", "mapping": { "$.sum_numbers_result": "$utils.sum_numbers('$.sum_number_in';'$.sum_number_in2';'sum_number_in3', '2')" }, } ``` Items are truncated/rounded prior to summation. Final sum is also truncated/rounded as specified. #### Multiply Numbers Specify `multiply_numbers` to multiply numbers and truncate/round as above. ``` { "name": "util_language", "mapping": { "$.multiply_numbers_result": "$utils.multiply_numbers('$.number_in';12, '2')" }, } ``` Items are truncated/rounded prior to summation. Final sum is also truncated/rounded as specified. #### Parse location You can parse street address and street intersection for the United States. Util knows about directional prefixes and suffixes, fractional building numbers, building units, grid-based addresses (such as those used in parts of Utah), 5 and 9 digit ZIP codes, and all of the official USPS abbreviations for street types, state names and secondary unit designators. `$utils.parse_location(element)` | Attribute | Type | Description | | --- | --- | --- | | element | valid JSONPathes | JSONPath to the element, that should be parsed | Return value: ``` { "title": "Address" "type": "object", "properties": { "number": { "type": "string", "description": "House or street number." }, "prefix": { "type": "string", "description": "Directional prefix for the street, such as N, NE, E, etc. A given prefix should be one to two characters long." }, "street": { "type": "string", "description": "Name of the street, without directional or type qualifiers." }, "type": { "type": "string", "description": "Abbreviated street type, e.g. Rd, St, Ave, etc. See the USPS official type abbreviations at for a list of abbreviations used." }, "suffix": { "type": "string", "description": "Directional suffix for the street, as above." }, "city": { "type": "string", "description": "Name of the city, town, or other locale that the address is situated in." }, "state": { "type": "string", "description": "The state which the address is situated in, given as its two-letter postal abbreviation. for a list of abbreviations used." }, "zip": { "type": "string", "description": "Five digit ZIP postal code for the address, including leading zero, if needed." }, "sec_unit_type": { "type": "string", "description": "If the address includes a Secondary Unit Designator, such as a room, suite or appartment, the sec_unit_type field will indicate the type of unit." }, "sec_unit_num": { "type": "string", "description": "If the address includes a Secondary Unit Designator, such as a room, suite or appartment, the sec_unit_num field will indicate the number of the unit (which may not be numeric)." } } } ``` None of his properties is guaranteed and depends on adress that is provided ###### Example: ``` { "mapping": { "$.number": "$utils.parse_location('$.address')['number']", "$.city_state": "$utils.join([$utils.parse_location('$.address')['city'], $utils.parse_location('$.address')['state']], ' ')" }, "name": "address_location" } ``` #### SetNull Specify `set_null` to hardcode a null to the field - will show in JSON as 'None'. Cannot be used with wildcards. ###### Example: ``` { "name": "util_language", "mapping": { "$.null_value_to": "set_null", "set_null": "$.null_value_from" }, } ``` #### Generate ID You have ability to generate ULID by using `$utlis.ulid` `$utils.ulid(element, many)` | Attribute | Type | Description | | --- | --- | --- | | element | string | JSONPath in your payload, it can point to anything (object, array, string, etc.), if during translation value, that will be result for two usage of this util will be the same, than it will generate same ids | | many | boolean | Indicate, if provided element points to array, generate one ids, based on the whole array, or id for every array element | ###### Example: ###### Language: ``` { "mapping": { "$.elements[*].id": "$utils.ulid('$.input[*].foo')", "$.data[*].id": "$utils.ulid('$.input[*].bar')" } } ``` ###### Input: ``` { "foo": [1, 2, "hello"], "bar": [1, 2, "hello"] } ``` ###### Output: ``` { "elements": [ {"id": "01F4EYZ82K7M46DQAZKZT4Y7QT"}, {"id": "01F4EYZVVM3BTAYHBHV1AJDQZC"}, {"id": "01F4EZ05VWZZ3BM3EFP6FYQ28H"} ], "data": [ {"id": "01F4EYZ82K7M46DQAZKZT4Y7QT"}, {"id": "01F4EYZVVM3BTAYHBHV1AJDQZC"}, {"id": "01F4EZ05VWZZ3BM3EFP6FYQ28H"} ] } ``` As you can see, we generated id's, but we have same id's in `elements` and `data` arrays, because input contains same values in objects by provided in language JSONPathes #### Frame If your languge is in `application/ld+json` you can apply frame algorithm to your payload, and query data from it `$utils.frame(element, frameObject)` | Attribute | Type | Description | | --- | --- | --- | | element | string | JSONPath for querying framed payload | | frameObject | object | JSON-LD frame | Language example: ``` { "mapping": { "$.book_title": "$utils.frame('$[\'ex:contains\'][\'dc11:title\']', { '@type': 'ex:Library', 'ex:contains': { '@type': 'ex:Book' } })" }, "jsonld_context": { "dc11": "", "ex": "", "xsd": "", "ex:contains": { "@type": "@id" } }, "content_type": "application/ld+json" } ``` Input: ``` { "@graph": [ { "@id": "", "@type": "ex:Library", "ex:contains": "" }, { "@id": "", "@type": "ex:Book", "dc11:creator": "Plato", "dc11:title": "The Republic", "ex:contains": "" }, { "@id": "", "@type": "ex:Chapter", "dc11:description": "An introductory chapter on The Republic.", "dc11:title": "The Introduction" } ] } ``` Output: ``` { "book_title": "The Republic" } ``` #### Convert string case `$utils.convert_case(element, case)` | Attribute | Type | Description | | --- | --- | --- | | element | JSONPath | JSONPath to be converted | | case | string | Supported conversions: upper, lower | Return value: Converted string Example: ``` { "name": "util_language", "mapping": { "$utils.convert_case('$.address.state_code', 'upper')": "$.state" } } ``` #### Extract text with regex `$utils.regex_extract(element, regex)` | Attribute | Type | Description | | --- | --- | --- | | element | JSONPath | JSONPath to be extracted from | | regex | regex | The regex to use for extracting text from the element | Return value: Extracted string Example: ``` { "name": "regex_language", "mapping": { "$.income": "$utils.regex_extract('$.borrower_income', '\\d+')" } } ``` #### Set current date `$utils.set_current_date` Example: ``` { "name": "current_date_language", "mapping": { "$.current_date": "$utils.set_current_date" } } ``` Return value: string with current date in normalized format "yyyy-MM-dd" by 'America/New_York' timezone. #### Format field `$utils.format(element, type)` | Attribute | Type | Description | | --- | --- | --- | | element | JSONPath | JSONPath to be extracted from | | type | string | Type of formatting to produce. Choices are "ssn", "itin", "percent", "phone_number", "phone_number_parentheses" | Return value: Formatted string Example: ``` { "name": "format-ssn", "mapping": { "$.ssn": "$utils.format('$.incoming_ssn', 'ssn')" } } ``` #### Relationship `$utils.relationship(element, query, key, relName)` Map XLINK relationships (`1:1` and `1:M`) used in XML-like schemas | Attribute | Type | Description | | --- | --- | --- | | element | JSONPath | JSONPath to extract first relationship entity | | query | JSONPath | JSONPath to extract the second relationship entity | | key | JSONPath | JSONPath of key that contains the value of first relationship component | | relName | string | Name to be used for relationship in output object | The following is an example mapping (note: mappings for this operation are single-direction): ``` { "single_direction_mappings": { "to_staircase": { "$.relationships.relationship[*]|ASSET_LIABILITY-$.assets[?(@.@type=='real_estate_owned')]-with_liability[*]": "$utils.relationship('$.assets[?(@.@type==\'real_estate_owned\')]', 'with_liability[*]', '@id', 'ASSET_LIABILITY')" } } } ``` The above mapping uses the JSON Path query `$.assets[?(@.@type==\'real_estate_owned\')]` to get the relationship's left-side (or from-) entity. The value in its `@id` field will be use to mark this first entity in the created output. The JSON Path `with_liability[*]` marks the value of right-side (or to-) entity in the relationship. The relationship's name is ``` { "people": [ { "@id": "BORROWER_1", "@type": "borrower", "owns_asset": [ "ASSET_1", "ASSET_2" ] } ], "assets": [ { "@id": "ASSET_1", "@type": "retirement_account", "has_account_identifier": { "has_value": "4444" }, "has_asset_description": { "has_value": "Roth IRA" }, "has_market_value_amount": { "has_value": 923.27 } }, { "@id": "ASSET_2", "@type": "real_estate_owned", "has_market_value_amount": { "has_value": 25632.87 }, "with_liability": [ "LIABILITY_1" ] } ], "liabilities": [ { "@id": "LIABILITY_1", "@type": "liability", "has_liability_payment_amount": { "has_value": 923.27 } } ] } ``` When the language mappings are applied to the above example input, the following output is created: ``` { "relationships": { "relationship": [ { "relationship_link": "ASSET_LIABILITY", "link_from": "ASSET_2", "link_to": "LIABILITY_1" } ] } } ``` ##### Request Example with utilsXML Language exampleExample with values mapping application/json Copy ``` { "mapping": { "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].date": "$.bundle[0].date", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range": "$.bundle[0].lower", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].high_value_range": "$.bundle[0].upper", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].value": "$.bundle[0].zestimate", "$utils.join(['$.deal_sets[0].collaterals[0].address.line_text', '$.deal_sets[0].collaterals[0].address.city', '$.deal_sets[0].collaterals[0].address.state_code', '$.deal_sets[0].collaterals[0].address.postal_code'], ' ')": "$.address", "$.deal_sets[0].collaterals[0].address.line_text": "$utils.split('$.address', ' ')[0]", "$.deal_sets[0].collaterals[0].address.city": "$utils.split('$.address', ' ')[1]", "$.deal_sets[0].collaterals[0].address.state_code": "$utils.split('$.address', ' ')[2]", "$.deal_sets[0].collaterals[0].address.postal_code": "$utils.split('$.address', ' ')[3]" }, "sc_version": 0 } ``` application/json Copy ``` { "content_type": "application/xml", "mapping": { "$.about_versions.about_version_identifier": "$.MESSAGE[0].ABOUT_VERSIONS[0].ABOUT_VERSION[0].AboutVersionIdentifier[0]._text[0]", "$.about_versions.data_version_identifier": "$.MESSAGE[0].ABOUT_VERSIONS[0].ABOUT_VERSION[0].DataVersionIdentifier[0]._text[0]", "$.deal_sets[*].about_versions.data_version_identifier": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].ABOUT_VERSIONS[0].ABOUT_VERSION[0].DataVersionName[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.address.address_line_text": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].ADDRESS[0].AddressLineText[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.address.city_name": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].ADDRESS[0].CityName[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.address.postal_code": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].ADDRESS[0].PostalCode[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.address.state_code": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].ADDRESS[0].StateCode[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.attachment_type": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].AttachmentType[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.construction_method_type": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].ConstructionMethodType[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.financed_unit_count": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].FinancedUnitCount[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.property_estate_type": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PropertyEstateType[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.property_estimated_value_amount": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PropertyEstimatedValueAmount[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.property_existing_clean_energy_lien_indicator": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PropertyExistingCleanEnergyLienIndicator[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.property_in_project_indicator": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PropertyInProjectIndicator[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.property_mixed_usage_indicator": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PropertyMixedUsageIndicator[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.property_usage_type": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PropertyUsageType[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_detail.pud_indicator": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_DETAIL[0].PUDIndicator[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_valuations[*].property_valuation_detail.appraisal_identifier": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_VALUATIONS[0].PROPERTY_VALUATION[*].PROPERTY_VALUATION_DETAIL[0].AppraisalIdentifier[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.property_valuations[*].property_valuation_detail.property_valuation_amount": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].PROPERTY_VALUATIONS[0].PROPERTY_VALUATION[*].PROPERTY_VALUATION_DETAIL[0].PropertyValuationAmount[0]._text[0]", "$.deal_sets[*].collaterals[*].subject_property.sales_contracts[*].sales_contract_detail.sales_contract_amount": "$.MESSAGE[0].DEAL_SETS[0].DEAL_SET[*].DEALS[0].DEAL[0].COLLATERALS[0].COLLATERAL[*].SUBJECT_PROPERTY[0].SALES_CONTRACTS[0].SALES_CONTRACT[*].SALES_CONTRACT_DETAIL[0].SalesContractAmount[0]._text[0]" } } ``` application/json Copy ``` { "mapping": { "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].date": "$.bundle[0].date", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].high_value_range": "$.bundle[0].upper", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range": "$.bundle[0].lower", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].value": "$.bundle[0].zestimate" }, "values_mapping": [ { "element": "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range", "mapping": [ { "language_value": "FooBar", "staircase_value": "HelloWorld" }, { "language_value": "WorldHello", "staircase_value": "BarBaz" } ] } ], "sc_version": 0 } ``` ##### Response 202400403 application/json Copy Async update accepted ``` Async update accepted ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `my_lang` | Language name | | `validate` | `boolean` query | `true` | Whether to validate the language before inserting. By default it will be validated. | | `sc_version` | `integer` query | `1` | Version of the staircase language to which this language targets (.csv only) | | `payload_content_type` | `string` query | `application/json` | Content type of payload - defaults to application/json (.csv only) | | `async` | `boolean` query | `true` | Whether to execute the update asynchronously, this is best for larger operations. Be default, async is off. Use the retrieve language update status endpoint to check status and the retrieve language endpoint to get the updated language. | | `parse_enum_values_types` | `boolean` query | `true` | if enum values should be parsed with datatypes (booleans, integers, floats), set this parameter to true. | ##### Request body`application/json` 10 fields | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Language name | | `mapping`required | `object` | Mapping | | `single_direction_mappings` | `object` | Single direction mappings | | `values_mapping` | `object[]` | Mapping values | | `element`required | `string` | Element | | `mapping`required | `object[]` | Mapping | | `staircase_value`required | `string` | Staircase value | | `language_value`required | `string` | Language value | | `unique_arrays` | `object` | Key-value pairs, where key is JSONPath to array of objects, and value is key, that has been unique | | `merge_arrays` | `object` | Key-value pairs, where key is JSONPath to array which will contain merged elements, and value is an array, which contains JSONPaths to arrays that should be excluded from result and all their elements should be included to the JSONPath specified as a key. | | `content_type` | `string` | Content type`application/json``application/ld+json``application/xml` | | `sc_version` | `integer` | Staircase version language is mapped to - defaults to 0 | | `validate_paths` | `boolean` | Turn on or off the validation of language mapping paths. By default, turned on. | | `async` | `boolean` | Whether to execute the update asynchronously, this is best for larger operations. Be default, async is off. Use the retrieve language update status endpoint to check status and the retrieve language endpoint to get the updated language. | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Other responses `202``204``422` `GET` `/languages/{language_name}/status` #### Retrieve Language Update Status `retrieveLanguageStatus` Retrieve Language Update Status retrieves the status of an asynchronous language update. ##### Response 200400403404 application/json Copy Language ``` { "status": "RUNNING" } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `my_lang` | Language name | ##### Response `200``application/json` 1 fields Language | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Update in progress | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `DELETE` `/languages/{language_name}` #### Delete Language `deleteLanguage` Delete Language removes a language from the translator. ##### Response 400403404 application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `my_lang` | Language name | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `204` `GET` `/languages/{language_name}/elements` #### Retrieve Language Elements `retrieveLanguageElements` Retrieve Language Elements retrieves a list of Staircase elements present in a language. ##### Response 200400403404 application/json Copy List of staircase elements present in language ``` [ "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].date", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].low_value_range", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].high_value_range", "$.deal_sets[0].collaterals[0].property_valuations[0].avms[0].value", "$.deal_sets[0].collaterals[0].address.line_text", "$.deal_sets[0].collaterals[0].address.city", "$.deal_sets[0].collaterals[0].address.state_code", "$.deal_sets[0].collaterals[0].address.postal_code" ] ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `my_lang` | Language name | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200` `GET` `/languages` #### Retrieve Languages `retrieveLanguages` Retrieve Languages returns a list of all supported languages on the platform. Note: There is a maximum amount of languages returned in a response. If there are more languages left to retrieve, the next field in the response will contain the name of the last retrieved language. To retrieve the next set of languages, use the optional after_name query parameter. Show the rest ``` curl --location --request GET '' \ --header 'x-api-key: ' \ --header 'Content-Type: application/json' ``` ``` "languages": [ {"name": "mismo34", "version": "3.4", "content_type": "application/ld+json"}, {"name": "jsonlang", "version": "0.1", "content_type": "application/json"}, {"name": "xmlang", "version": "0.1", "content_type": "text/xml"}, ] } ``` ##### Response 400403 application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `after_name` | `string` query | `mismo34` | name of the last language retrieved in the list | | `limit` | `integer` query | `100` | number of items per page | ##### Response `200``application/json` 2 fields 200 response | Field | Type | Description | | --- | --- | --- | | `next` | `string` | Name of the last language evaluated (bookmark) | | `languages` | `object[]` | Language name, version and type of content for the language mapping | | `name` | `string` | Language name | | `version` | `string` | Staircase language version | | `content_type` | `string` | Type of content for the language mapping | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | `GET` `/languages/{language_name}` #### Retrieve Single Language `retrieveLanguage` Retrieve Single Language retrieves a language name, mapping, and content type for a language. If the language is being updated asynchronously and the update hasn't finished the response will contain a status. ##### Response 200400403404 application/json Copy Language ``` { "name": "my_lang", "mapping_info": { "language_elements": { "coverage": "100%", "unmapped_count": 0, "mapped_count": 3, "unmapped": [] }, "staircase_elements": { "coverage": "100%", "unmapped_count": 0, "mapped_count": 4, "unmapped": [] } }, "mapping": { "$.deal_sets.deal_set[0].deals.deal[0].assets.asset[*].account_identifier": "$.report.items[0].accounts[*].mask", "$.deal_sets.deal_set[0].deals.deal[0].services.service[0].verification_of_assets.verification_of_assets_response.partner_product": "Assets", "$.deal_sets.deal_set[0].deals.deal[0].services.service[0].verification_of_assets.verification_of_assets_response.service_date": "$utils.slice('$.report.date_generated', 0, 10)", "$.document.extracted_data.fanniemae_or_freddiemac": "$.extractedData[?(@.name == 'Form_Name')].data" }, "values_mapping": [ { "mapping": [ { "staircase_value": "Fannie Mae", "language_value": "fanniemae" }, { "staircase_value": "Freddie Mac", "language_value": "freddiemac" } ], "element": "$.document.extracted_data.fanniemae_or_freddiemac" } ], "sc_version": 0, "content_type": "application/json" } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `my_lang` | Language name | ##### Response `200``application/json` 6 fields Language | Field | Type | Description | | --- | --- | --- | | `name` | `string` | name | | `mapping` | `object` | Mapping type either string or array | | `mapping_info` | `object` | Meta information about existing mapping | | `language_elements` | `object` | Meta information about existing mapping elements | | `coverage` | `string` | Meta information about coverage | | `mapped_count` | `number` | Meta information about mapped_count | | `unmapped_count` | `number` | Meta information about unmapped_count | | `unmapped` | `string[]` | Meta information about unmapped | | `staircase_elements` | `object` | Meta information about staircase elements | | `coverage` | `string` | Meta information about coverage | | `mapped_count` | `number` | Meta information about mapped_count | | `unmapped_count` | `number` | Meta information about unmapped_count | | `unmapped` | `string[]` | Meta information about unmapped | | `sc_version` | `integer` | Sc_version number | | `values_mapping` | `object[]` | Array of values mapping | | `element` | `string` | Element name | | `mapping` | `object[]` | Mapping array | | `staircase_value` | `string` | Staircase value | | `language_value` | `string` | Language value | | `content_type` | `string` | Type of content sent in the response`application/json``application/ld+json``application/xml` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ### Mappings `POST` `/mappings/{mapping_name}/import` #### Create Mapping from Payload `createMapping` Create mapping from existing payload Import mapping takes an existing payload and creates a starter mapping from it. ##### Request application/json Copy ``` { "settings": { "auto-create": true }, "data": { "report": { "asset_report_id": "bf3a0490-344c-4620-a219-2693162e4b1d", "client_report_id": "123abc", "date_generated": "2020-06-05T22:47:53Z", "days_requested": 3, "items": [ { "accounts": [ { "account_id": "3gE5gnRzNyfXpBK5wEEKcymJ5albGVUqg77gr", "name": "Plaid Saving", "official_name": "Plaid Silver Standard 0.1% Interest Saving" } ] } ], "user": { "client_user_id": "123456789", "email": "accountholder0@example.com", "first_name": "Alberta", "last_name": "Charleson", "middle_name": "Bobbeth", "phone_number": "111-222-3333", "ssn": "999-00-0000" } }, "request_id": "eYupqX1mZkEuQRx", "warnings": [] } } ``` ##### Response 201400403 application/json Copy Mapping created successfully ``` { "name": "mapping_name", "mapping_info": { "language_elements": { "coverage": 0, "mapped_count": 0, "unmapped_count": 16, "unmapped": [ "$.report.asset_report_id", "$.report.client_report_id", "$.report.date_generated", "$.report.days_requested", "$.report.items[*].accounts[*].account_id", "$.report.items[*].accounts[*].name", "$.report.items[*].accounts[*].official_name", "$.report.user.client_user_id", "$.report.user.email", "$.report.user.first_name", "$.report.user.last_name", "$.report.user.middle_name", "$.report.user.phone_number", "$.report.user.ssn", "$.request_id", "$.warnings[*]" ] }, "staircase_elements": { "coverage": 0, "mapped_count": 0, "unmapped_count": 0, "unmapped": null } }, "mapping": { "": [ "$.report.asset_report_id", "$.report.client_report_id", "$.report.date_generated", "$.report.days_requested", "$.report.items[*].accounts[*].account_id", "$.report.items[*].accounts[*].name", "$.report.items[*].accounts[*].official_name", "$.report.user.client_user_id", "$.report.user.email", "$.report.user.first_name", "$.report.user.last_name", "$.report.user.middle_name", "$.report.user.phone_number", "$.report.user.ssn", "$.request_id", "$.warnings[*]" ] } } ``` application/json Copy Unable to create mapping from payload ``` { "message": "Unable to create mapping from payload" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `mapping_name` required | `string` path | `my_mapping` | Mapping name | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `settings` | `object` | Settings object | | `auto-create` | `boolean` | Whether to save the mapping after importing it. Defaults to true. | | `data` | `object` | Data object | ##### Response `400``application/json` 1 fields Unable to create mapping from payload | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Other responses `201` ### Rules Generator `POST` `/rules-generator/jobs` #### Generate Rules `generateRules` Generate Rules from one language to another. Currently supports mapping from/to: - `lexicon` - `staircase-graph` - `staircase-mismo-limited` Multiple algorithms are supported. The source of the partner language schema to match is the Lexicon Languages Registry. List of algorithms: - property_matching - The algorithm uses similarity between property and class names to generate rules. Good fit for more flat languages. - containers_first_matching - The algorithm uses the similarity between class names in the first priority, and property names in the second, to generate rules. Good fit for more nested languages. - gpt - The algorithm uses GPT-4 to generate rules. There is also a possibility to select a string similarity algorithm and similarity score cutoff. These parameters define how particular containers and properties will be chosen as the best match to map in rules. The possible values for `similarity_algorithm` are ratio, jaro, and jaro_winkler: Show the rest - ratio (default) calculates the Levenshtein distance ratio of similarity between two sequences; - jaro and jaro_winkler are string-edit distance algorithms that give more favorable ratings to strings that match from the beginning. #### Parties Mapping ##### (works only for `containers_first_matching` algorithm) In MISMO and MISMO-like languages, parties have a slightly different structure from staircase languages. In order to map parties from the partner language to the staircase you need to specify a path to value in the partner language that determines party type and corresponding value in the staircase language. Check the request body example for more details. #### Static Mappings ##### (works only for `containers_first_matching` algorithm) The rules-generation process consists of matching containers and end-properties: - containers are objects and arrays. - end-properties are literal values - strings, numbers, and booleans. There are common cases when a partner language has similar end-properties to staircase language, but their container structure and names might be pretty different. The static mapping parameter solves this problem. Static mappings are specialized for "hard-coding" the mappings only for containers, so the service is able to map properties (and child containers that are not specified in static mappings) between these containers by the similarity algorithm. Suppose some end-properties should be mapped although they don't match by similarity algorithm. In that case, the user should map it just manually by himself inside the generated rules sample after the generation. Static mappings are specified in the `static_mappings` field of the `algorithm_settings` and might have a recursive structure with a `children` field for each mapping. `foreign_container` and `staircase_container` are relative paths (relative to the parent mapping, if it is in `children`) to the containers in the partner and staircase languages respectively. In staircase language it might be a v2 container in a root mapping, or a relationship in `children` mappings. `foreign_container` might consist of a single node (like "role") or multiple nodes joined with a front slash (like "role/roles/roleDetail"). In this case, intermediate containers are treated as skipped in rules, so they will be mapped to the empty staircase path (`""`). The same logic might be applied by specifying `null` values for `staircase_container` & `staircase_type`. So, these static mappings: ``` [ { "foreign_container": "x/y/z", "staircase_container": "assets", "staircase_type": "asset" } ] ``` are absolutely equal to these: ``` [ { "foreign_container": "x", "staircase_container": null, "staircase_type": null }, { "foreign_container": "x/y", "staircase_container": null, "staircase_type": null }, { "foreign_container": "x/y/z", "staircase_container": "assets", "staircase_type": "asset" } ] ``` and these: ``` [ }, { "foreign_container": "x", "staircase_container": null, "staircase_type": null, "children": [ { "foreign_container": "y", "staircase_container": null, "staircase_type": null, "children": [ { "foreign_container": "z", "staircase_container": "assets", "staircase_type": "asset" } ] } ] } ] ``` It might be useful to map different nested objects to the single item of the same staircase container & type: ``` [ { "foreign_container": "ASSETS", "staircase_container": "assets", "staircase_type": "asset", "children": [ { "foreign_container": "ASSET/ASSET_DETAIL", "staircase_container": null, "staircase_type": null } ] ] } ] ``` In this case, all the properties of the `ASSETS` and the `ASSET_DETAIL` objects will be mapped to the same `asset` item. If some foreign container is array and should be mapped to the staircase relationship, you should map exactly this array container to the relationship, and if needed, specify nested objects as `children`: For example, you have data like this: ``` { "borrower": { "name": "John Doe", "some_dummy_node": { "hmda_races": [ { "hmda_races_info": { "hmda_race_type": "bla-bla-bla" }, "additional_info": { "race_type_additional_description": "bla-bla-bla" }, } ] } } } ``` and you want to map `hmda_races` array to the `with_hmda_race` borrower's relationship. In this case, static mappings should look like this: ``` [ { "foreign_container": "borrower/some_dummy_node/hmda_races", "staircase_container": "with_hmda_race", "staircase_type": "hmda_race", "children": [ { "foreign_container": "hmda_races_info", "staircase_container": null, "staircase_type": null }, { "foreign_container": "additional_info", "staircase_container": null, "staircase_type": null } ] } ] ``` ##### More complete example ``` { "algorithm_settings": { "static_mappings": [ { "foreign_container": "foreign_container_1", "staircase_container": "staircase_container_1", "staircase_type": "staircase_type_1", "children": [ { "foreign_container": "child_foreign_container_1", "staircase_container": "child_staircase_container_1", "staircase_type": "staircase_type_1_1", "evaluate_separate": true, "filter": { "path": "filter_path_1", "value": "filter_value_1", "operation": "IS_EQUAL" } }, { "foreign_container": "child_foreign_container_2", "staircase_container": "child_staircase_container_2", "staircase_type": "staircase_type_1_2" } ] }, { "foreign_container": "foreign_container_2", "staircase_container": "staircase_container_2", "staircase_type": "staircase_type_2", "evaluate_separate": true, "filter": { "path": "filter_path_3", "value": true, "operation": "IS_EQUAL" } } ] } } ``` ##### Request Property matching exampleContainer matching example with parties mappingContainer matching with static mappings application/json Copy ``` { "lang_from": "credit", "lang_to": "staircase-graph", "algorithm": "property_matching" } ``` application/json Copy ``` { "lang_from": "mismo-like", "lang_to": "staircase-graph", "algorithm": "container_first_matching", "algorithm_settings": { "parties_mapping": { "path_to_type_value": "roles/roleDetail/partyRoleType", "mappings": [ { "foreign_type": "PARTY_ROLE_ENUM_BORROWER", "staircase_type": "borrower" }, { "foreign_type": "PARTY_ROLE_ENUM_CO_BORROWER", "staircase_type": "co_borrower" }, { "foreign_type": "PARTY_ROLE_ENUM_LOAN_ORIGINATOR", "staircase_type": "loan_originator" } ] } } } ``` application/json Copy ``` { "lang_from": "some_partner_lang", "lang_to": "staircase-graph", "algorithm": "container_first_matching", "algorithm_settings": { "static_mappings": [ { "foreign_container": "foreign_container_1", "staircase_container": "staircase_container_1", "staircase_type": "staircase_type_1", "children": [ { "foreign_container": "child_foreign_container_1", "staircase_container": "child_staircase_container_1", "staircase_type": "staircase_type_1_1", "evaluate_separate": true, "filter": { "path": "filter_path_1", "value": "filter_value_1", "operation": "IS_EQUAL" } }, { "foreign_container": "child_foreign_container_2", "staircase_container": "child_staircase_container_2", "staircase_type": "staircase_type_1_2" } ], "evaluate_separate": false }, { "foreign_container": "foreign_container_2", "staircase_container": "staircase_container_2", "staircase_type": "staircase_type_2", "evaluate_separate": true, "filter": { "path": "filter_path_3", "value": true, "operation": "IS_EQUAL" } } ] } } ``` ##### Response 202400403404 application/json Copy Generated rules ``` { "id": "5be17d0e-425e-4419-bf7f-18caca2ed530", "status": "running", "lang_from": "staircase-graph", "lang_to": "credit" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `lang_from`required | `string` | Language to generate rules from | | `lang_to`required | `string` | Language to generate rules to | | `algorithm`required | `string` | Algorithm to use for generating rules`container_first_matching``gpt``property_matching` | | `algorithm_settings` | `object` | Algorithm settings. | | `similarity_algorithm` | `string` | The name of the similarity algorithm to use. The possible values are 'ratio', 'jaro', and 'jaro_winkler'. - 'ratio' (***default***) calculates the Levenshtein distance ratio of similarity between two sequences; - 'jaro' and 'jaro_winkler' are string-edit distance algorithms that give more favorable ratings to strings that match from the beginning.`jaro``jaro_winkler``ratio` | | `score_cutoff` | `number (float)` | The minimum score a pair must have to be considered a match. This is based on the similarity measure provided by the selected algorithm. It represents the minimum allowed similarity score between two strings for them to be considered a match. | | `override_container_names` | `object[]` | Array of objects with container names to override. | | `staircase_type`required | `string` | `@type` for which container name should be overridden. | | `staircase_container`required | `string` | Container name in staircase language to set always. | | `parties_mapping` | `object` | Parties mapping settings. Required for container_first_matching algorithm. | | `path_to_type_value` | `string` | Relative path starting from parties(case insensitive container) to value in partner language that determines party type. | | `mappings` | `object[]` | Array of mappings from partner language party type to staircase language party type. | | `foreign_type` | `string` | Party type in partner language. | | `staircase_type` | `string` | Party type in staircase language. | | `static_mappings` | `object[]` | Static mappings are specified to hard-code the mappings only for containers with container_first_matching algorithm. Can have a recursive structure with 'children' field for each mapping. | | `foreign_container`required | `string` | The identifier of the foreign container that needs to be mapped. Might have multiple nodes separated by '/'. | | `staircase_container`required | `string` | The identifier of the staircase container to which the foreign container is mapped. Might have multiple nodes separated by '/'. | | `staircase_type`required | `string` | The type of the staircase container. | | `children` | `object[]` | The array of child static mappings, allowing for recursive mapping structures. | | `evaluate_separate` | `boolean` | A boolean flag indicating whether to evaluate the mapping separately. | | `filter` | `object` | An object that specifies the filter conditions for the mapping for the direction `Foreign -> Staircase`. | | `path` | `string` | The path to the property in the container that needs to be filtered. | | `value` | `one of` | The value against which the property at the given path will be checked. | | `operation` | `string` | The operation to be performed for filtering. Currently, only 'IS_EQUAL' operation is supported.`IS_EQUAL` | ##### Response `202``application/json` 2 fields Generated rules | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Generation id | | `status`required | `string` | Generation status`running` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/rules-generator/jobs/{id}` #### Get Rules Generation Status `getRulesGenerationStatus` ##### Response 200 Running200 Failed200 Completed400403404 application/json Copy Rules Generation Status ``` { "id": "5be17d0e-425e-4419-bf7f-18caca2ed530", "status": "running", "lang_from": "staircase-graph", "lang_to": "credit", "errors": null, "rules": null, "statistics": null } ``` application/json Copy Rules Generation Status ``` { "id": "5be17d0e-425e-4419-bf7f-18caca2ed530", "status": "failed", "lang_from": "staircase-graph", "lang_to": "credit", "errors": [ "Error message 1", "Error message 2" ], "rules": null, "statistics": null } ``` application/json Copy Rules Generation Status ``` { "id": "5be17d0e-425e-4419-bf7f-18caca2ed530", "status": "completed", "lang_from": "staircase-graph", "lang_to": "credit", "errors": null, "statistics": { "mapped_properties_count": 3, "unmapped_properties_count": 1, "coverage_ratio": 0.75, "unmapped_properties": [ "MESSAGE/DEAL_SETS/PARTIES/PARTY/ROLES/ROLE/PARTY_ROLE_IDENTIFIERS/PARTY_ROLE_IDENTIFIER/PartyRoleIdentifier" ], "mapped_properties": [ { "from": "MESSAGE/DEAL_SETS/DEAL_SET/DEALS/DEAL/ABOUT_VERSIONS/ABOUT_VERSION/@SequenceNumber", "to": "data_versions/has_sequence_number/has_value" }, { "from": "MESSAGE/DEAL_SETS/DEAL_SET/DEALS/DEAL/ABOUT_VERSIONS/ABOUT_VERSION/DataVersionName", "to": "data_versions/has_data_version_name/has_value" }, { "from": "MESSAGE/DEAL_SETS/PARTIES/PARTY/LEGAL_ENTITY/LEGAL_ENTITY_DETAIL/FullName", "to": "organizations/has_organization_name/has_value" } ] }, "rules": [ { "definition": { "from": { "path": "MESSAGE/DEAL_SETS/DEAL_SET/DEALS/DEAL/ABOUT_VERSIONS" }, "to": { "path": "data_versions" }, "attribute_mappings": [ { "from": { "value": "data_version" }, "to": { "path": "@type" } }, { "from": { "path": "ABOUT_VERSION" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "@SequenceNumber" }, "to": { "path": "has_sequence_number/has_value" } }, { "from": { "path": "DataVersionName" }, "to": { "path": "has_data_version_name/has_value" } } ] } ] } }, { "definition": { "from": { "path": "MESSAGE/DEAL_SETS/DEAL_SET/DEALS/DEAL/PARTIES/PARTY", "filter": { "path": "ROLES/ROLE/ROLE_DETAIL/PartyRoleType", "IS_EQUAL": "NotePayTo" } }, "to": { "path": "organizations" }, "attribute_mappings": [ { "from": { "value": "note_pay_to" }, "to": { "path": "@type" } }, { "from": { "path": "LEGAL_ENTITY/LEGAL_ENTITY_DETAIL/FullName" }, "to": { "path": "has_organization_name/has_value" } } ] } } ] } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Forbidden ``` { "message": "Invalid Api Key" } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `01H1Y44CSD0CQ7Z26S7QTJ2EF5` | Job id | ##### Response `200``application/json` 7 fields Rules Generation Status | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Generation id | | `status`required | `string` | Generation status`completed``failed``running` | | `lang_from`required | `string` | Language to generate rules from | | `lang_to`required | `string` | Language to generate rules to | | `rules`required | `object[]` | Array of generated rules | | `definition`required | `string` | Rule definition | | `errors`required | `string[]` | Array of errors that occurred during generation. | | `statistics` | `object` | Statistics of the generated mappings. | | `mapped_properties_count`required | `integer` | The number of properties that were mapped. | | `unmapped_properties_count`required | `integer` | The number of properties that were not mapped. | | `coverage_ratio`required | `number (float)` | The percentage of properties that were mapped. | | `unmapped_properties`required | `string[]` | The array of unmapped properties. | | `mapped_properties`required | `object[]` | The array of mapped properties. | | `foreign_path`required | `string` | The path to the property in the foreign language. | | `staircase_path`required | `string` | The path to the property in the staircase language. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ### Monitoring Testing `GET` `/testing/configurations` #### Get Testing Configurations `getTestingConfigurations` **Retrieve registered testing configurations. ##### Response 400403404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Response `200``application/json` 3 fields Configurations retrieved successfully | Field | Type | Description | | --- | --- | --- | | `health_key` | `string` | Environment health key. | | `host_environment` | `string` | Environment domain name. | | `config_type` | `string` | Testing configuration type. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/testing/runs` #### List Testing Runs `listTestingRuns` **Retrieve testing runs. ##### Response 400403404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `testing_environment` | `string` query | `test.staircaseapi.com` | Testing Environment | | `test_run_invocation_type` | `string` query | `http` | Testing run invocation type | ##### Response `200``application/json` 7 fields Testing run retrieved successfully | Field | Type | Description | | --- | --- | --- | | `test_run_id` | `string` | Unique test run id. | | `test_run_status` | `string` | Test run status | | `test_run_invocation_type` | `string` | Test run invocation type. | | `test_run_result` | `object[]` | Test run result details. | | `test_worker_id` | `string` | Test run worker id. | | `expire_at` | `string` | Test run result expiration time. | | `created_at` | `string` | Test run creation time. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PUT` `/testing/configurations` #### Create Testing Configuration `createTestingConfiguration` The primary function of this service is to enable the creation of testing configurations. The testing service, which is responsible for testing the language product against test cases generated from historical invocations, conducts multiple tests throughout the day. It should be noted that the test cases themselves are generated daily and have an expiration period of one month ##### Request application/json Copy ``` { "health_key": "health-key", "host_environment": "lang.staircaseapi.com" } ``` ##### Response 200400403404422 application/json Copy Configuration response ``` { "message": "Configuration created." } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` application/json Copy The server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions. ``` { "message": "Ruleset with name 'atomic_staircase-graph_TRANSLATE' cannot be deleted while it has rules. Please, delete all rules first and try again." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `host_environment`required | `string` | Environment domain name. | | `health_key`required | `string` | Health key. | ##### Response `200``application/json` 1 fields Configuration response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint result message. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 1 fields The server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions. | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | `DELETE` `/testing/configurations/{host_environment}` #### Delete Testing Configuration `deleteTestingConfiguration` This service removes configuration. ##### Response 200403404 application/json Copy Configuration response ``` { "message": "Configuration deleted." } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `host_environment` required | `string` path | `lang.staircaseapi.com` | Environment domain name | ##### Response `200``application/json` 1 fields Configuration response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint result message. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/testing/runs` #### Start Testing Run `startTestingRun` The purpose of this service is to execute test cases in a specified environment. Upon invocation, the collected test cases will be run against the installed version of the Language product. Each individual run will be identified with a unique identifier, which will enable interested parties to query the corresponding result. It should be noted that the information pertaining to test run results will be valid for a period of two months before expiration ##### Request application/json Copy ``` { "api_key": "api-key", "testing_environment": "lang.staircaseapi.com" } ``` ##### Response 200400403404 application/json Copy Test run response ``` { "test_run_id": "01GSWG340T18R53MK6YYS64DD7" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `testing_environment`required | `string` | Environment domain name. | | `api_key`required | `string` | API key. | ##### Response `200``application/json` 1 fields Test run response | Field | Type | Description | | --- | --- | --- | | `test_run_id` | `string` | Test run identifier. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/testing/runs/{test_run_id}` #### Get Testing Run `getTestingRun` **Retrieve testing run. ##### Response 200400403404 application/json Copy Testing run retrieved successfully ``` { "expire_at": "1683887213", "test_run_status": "success", "created_at": "2023-03-13T10:26:53.444553+00:00", "test_run_id": "01GVD84EP2YPDWG6EMFH6K0NJZ", "finished_at": "2023-03-13T10:30:58.736202+00:00", "test_run_invocation_type": "http", "test_run_result": [ { "summary": { "collected": "38", "passed": "38", "failed": "0", "error": "0", "xfailed": "0", "skipped": "0" }, "local_path": "/tmp/tmpw52i9gi5/01GVD84EP2YPDWG6EMFH6K0NJZ/2023-02-19", "total_duration": "142.44527006149292", "failed_test_cases": [], "status": "OK" } ], "testing_environment": "test.staircaseapi.com", "test_worker_id": "language-testing-runner-worker:859b57c4-82d3-482e-8b30-afb3f66871d7", "logs": [ "[Container] 2023/03/13 10:28:27 Entering phase BUILD\n", "[Container] 2023/03/13 10:28:27 Running command python3.9 testing_test_runner_codebuild_worker.py\n", "{\"level\":\"INFO\",\"location\":\":270\",\"message\":\"Test Runner Worker started for test run: 01GVD84EP2YPDWG6EMFH6K0NJZ...\",\"timestamp\":\"2023-03-13 10:28:28,685+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "{\"level\":\"INFO\",\"location\":\"prepare_test_files_for_test_run:168\",\"message\":\"Preparing tests for date:2023-02-19\",\"timestamp\":\"2023-03-13 10:28:31,853+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "{\"level\":\"INFO\",\"location\":\"prepare_test_files_for_test_run:170\",\"message\":\"Preparing tests for env:-ce86d6bcfe.staircaseapi.com\",\"timestamp\":\"2023-03-13 10:28:31,853+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "{\"level\":\"INFO\",\"location\":\"prepare_test_files_for_test_run:195\",\"message\":\"Preparing test files finished /tmp/tmpw52i9gi5: 01GVD84EP2YPDWG6EMFH6K0NJZ\",\"timestamp\":\"2023-03-13 10:28:36,103+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "{\"level\":\"INFO\",\"location\":\"run_defined_tests:108\",\"message\":\"Running tests under /tmp/tmpw52i9gi5/01GVD84EP2YPDWG6EMFH6K0NJZ/2023-02-19\",\"timestamp\":\"2023-03-13 10:28:36,107+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "============================= test session starts ==============================\n", "platform linux -- Python 3.9.16, pytest-7.2.0, pluggy-1.0.0\n", "rootdir: /codebuild/output/src052753333/src\n", "plugins: xdist-3.2.1, mock-3.10.0\n", "gw0 I / gw1 I / gw2 I / gw3 I / gw4 I / gw5 I / gw6 I / gw7 I / gw8 I / gw9 I / gw10 I / gw11 I / gw12 I / gw13 I / gw14 I / gw15 I / gw16 I / gw17 I / gw18 I / gw19 I / gw20 I / gw21 I / gw22 I / gw23 I / gw24 I / gw25 I / gw26 I / gw27 I / gw28 I / gw29 I / gw30 I / gw31 I / gw32 I / gw33 I / gw34 I / gw35 I / gw36 I / gw37 I\n", "gw0 [38] / gw1 [38] / gw2 [38] / gw3 [38] / gw4 [38] / gw5 [38] / gw6 [38] / gw7 [38] / gw8 [38] / gw9 [38] / gw10 [38] / gw11 [38] / gw12 [38] / gw13 [38] / gw14 [38] / gw15 [38] / gw16 [38] / gw17 [38] / gw18 [38] / gw19 [38] / gw20 [38] / gw21 [38] / gw22 [38] / gw23 [38] / gw24 [38] / gw25 [38] / gw26 [38] / gw27 [38] / gw28 [38] / gw29 [38] / gw30 [38] / gw31 [38] / gw32 [38] / gw33 [38] / gw34 [38] / gw35 [38] / gw36 [38] / gw37 [38]\n", "\n", "...................................... [100%]{\"level\":\"INFO\",\"location\":\"run_defined_tests:133\",\"message\":\"Test result: 0\",\"timestamp\":\"2023-03-13 10:30:58,733+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "{\"level\":\"INFO\",\"location\":\":276\",\"message\":\"Test Runner Finished in 150.050298212\",\"timestamp\":\"2023-03-13 10:30:58,736+0000\",\"service\":\"Testing Test Runner Worker\"}\n", "\n", "======================== 38 passed in 142.45s (0:02:22) ========================\n", "\n", "[Container] 2023/03/13 10:30:58 Phase complete: BUILD State: SUCCEEDED\n", "[Container] 2023/03/13 10:30:58 Phase context status code: Message: \n", "[Container] 2023/03/13 10:30:58 Entering phase POST_BUILD\n", "[Container] 2023/03/13 10:30:58 Phase complete: POST_BUILD State: SUCCEEDED\n", "[Container] 2023/03/13 10:30:58 Phase context status code: Message: \n" ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `test_run_id` required | `string` path | `01GST3JQ3DZT2GJ8DBBATN9VQ4` | Test run identifier | ##### Response `200``application/json` 9 fields Testing run retrieved successfully | Field | Type | Description | | --- | --- | --- | | `test_run_id` | `string` | Unique test run id. | | `test_run_status` | `string` | Test run status | | `test_run_invocation_type` | `string` | Test run invocation type. | | `test_worker_id` | `string` | Test run worker id. | | `expire_at` | `string` | Test run result expiration time. | | `created_at` | `string` | Test run creation time. | | `finished_at` | `string` | Test run result finish time. | | `test_run_result` | `object[]` | Test run result details. | | `logs` | `string[]` | Test run logs | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PUT` `/monitoring/testing/data` #### Create Update Testing Data `createUpdateTestingData` This endpoint enables users to create or update testing data in JSON format. The testing data can be either a translation file or a language file. ##### Request TestTranslationDataExampleTestLanguageDataExample application/json Copy ``` { "file_path": "2023-03-12/test.staircaseapi.com/translations/staircase-graph_to_credit-input/111116VY6GRVSJVZV2CPCJYRYY_staircase-graph_to_credit-input.json", "payload": { "test": "data" } } ``` application/json Copy ``` { "file_path": "2023-03-12/test.staircaseapi.com/languages/credit-input.json", "payload": { "test": "data" } } ``` ##### Response 200400403404422 application/json Copy Configuration response ``` { "message": "Test data created/updated." } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` application/json Copy The server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions. ``` { "message": "Ruleset with name 'atomic_staircase-graph_TRANSLATE' cannot be deleted while it has rules. Please, delete all rules first and try again." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `file_path`required | `string` | Test data path. | | `payload`required | `string` | Test data payload. | ##### Response `200``application/json` 1 fields Configuration response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint result message. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 1 fields The server understands the content type of the request entity, and the syntax of the request entity is correct, but it was unable to process the contained instructions. | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | `GET` `/monitoring/testing/data/{file_path}` #### Get Testing Data `getTestingData` This endpoint allows users to retrieve testing data in JSON format. The path to the testing data should be provided in the correct format, and it should be URL encoded. ##### Response 200400403404 application/json Copy Configurations retrieved successfully ``` { "test": "data" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `file_path` required | `string` path | `2023-03-10%test.staircaseapi.com%2Ftranslations%2Fcredit-mismo34_to_staircase-graph%2F01GV60FP5813DD0EXJ2PK7K422_credit-mismo34_to_staircase-graph.json` | Testing data path | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200` `DELETE` `/monitoring/testing/data/{file_path}` #### Delete Testing Data `deleteTestingData` This endpoint allows users to delete testing data with the provided path. Path should be URL encoded. ##### Response 200403404 application/json Copy Configuration response ``` { "message": "Testing data deleted." } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `file_path` required | `string` path | `2023-03-10%test.staircaseapi.com%2Ftranslations%2Fcredit-mismo34_to_staircase-graph%2F01GV60FP5813DD0EXJ2PK7K422_credit-mismo34_to_staircase-graph.json` | Testing data path | ##### Response `200``application/json` 1 fields Configuration response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Endpoint result message. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/testing/encryption/key` #### Register Testing Data Private Key `RegisterTestingDataPrivateKey` Start Testing Run This endpoint enables users to register their private key for RSA encryption and decryption. The private key should be provided in the PEM format. Once the private key is registered, it can be used to decrypt the symmetric key that is used for decrypting the testing data. ##### Request application/json Copy ``` { "key": "" } ``` ##### Response 200400403404 application/json Copy Key response ``` { "message": "Key registered" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "API key is not valid." } ``` application/json Copy Requested resource not found ``` { "message": "Object not found" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `key`required | `string` | Private key. | ##### Response `200``application/json` 1 fields Key response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Key registered. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Translate `GET` `/translate/{translation_id}` #### Retrieve Translation Status `retrieveTranslatedPayload` Retrieve Translation Status retrieves a translation status and the result, if available. The response will contain a signed URL for the file containing the result. This file will contain both the returned data and any warnings or errors detected during translation. ##### Response 200400403404 application/json Copy Translation status ``` { "status": "SUCCEEDED", "translation_id": "8519db-f03b-4a13-885b-5d67d338ea0", "started_at": "2021-11-04 12:18:08.903000+00:00", "translation": { "output_url": "https://example_file.json?Expires=1627597250", "mimetype": "application/json" } } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `translation_id` required | `string` path | `f618ce80-dg5b-4ce2-9996-9d1d3240864d` | Translation ID | ##### Response `200``application/json` 4 fields Translation status | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status description | | `translation_id` | `string` | Translation ID | | `started_at` | `string` | Time when translation started in DateTime format | | `translation` | `object` | Signed URL for the document containing the output and media type of the translation | | `output_url` | `string` | Signed URL for the document containing the output | | `mimetype` | `string` | Media type of the translation`application/json``application/xml` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `POST` `/translate` #### Translate Received Payload `translateReceivedPayload` Translating a received payload Translate Received Payload translates any valid object in the Staircase data model from one language to another. Languages are identified by language_name. In the request body, provide the language to translate from (lang_from), the language to translate to (lang_to). Call Retrieve Languages to retrieve language_name(s) for languages that exist in your environment. Also, in the request body, provide both a valid Staircase data model object or snippet to be translated (data), and the version of Staircase language that the data model object/snippet belongs to. Call Retrieve Data Model Schema to retrieve a complete Staircase data model schema and all objects contained within. Can also be used to translate between different staircase language/lexicon versions. Set 'lang_from' and 'lang_to' to 'staircase', and use sc_version_from, sc_version_to query parameters. See /lexicon for more info. ##### Request application/json Copy ``` { 'data': 'object data in customer_lang format', 'lang_from':'customer_lang', 'lang_to':'staircase' } ``` ##### Response 200202400403404 application/json Copy 200 response ``` { "type": "employment", "permissible_purpose": "risk-assessment", "target": { "first_name": "First", "last_name": "Last", "social_security_number": "***-**-9999", "contact_email": "joesmith@example.org", "company": { "name": "Truework Inc" } } } ``` application/json Copy Async translation accepted ``` { "translation_id": "8519db-f03b-4a13-885b-5d67d338ea0", "started_at": "2021-11-04 12:18:08.903000+00:00", "callback_url": "https://webhook.site/6788842-f03b-4a13-885b-5d67d338ea09" } ``` application/json Copy Request data failed validation ``` { "MissingData": { "message": "{'data': ['Missing data for required field.']}" }, "ValidationFailed": { "message": "Invalid v0 paths detected", "invalid_paths": [ { "path": "$.deal_set.pawrty[0].individual.name.first", "message": "Could not find the given path" }, { "path": "deal_set.partie[0].individual.name.last", "message": "All valid paths are expected to start with $." } ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Requested resource not found ``` { "message": "Language not found" } ``` ##### Request body`application/json` 11 fields | Field | Type | Description | | --- | --- | --- | | `lang_from`required | `string` | Language of the payload | | `lang_to`required | `string` | Language of the desired translation | | `include_missing` | `boolean` | Include mapped fields in output even if originals don't exist in input | | `apply_lexicon_types` | `boolean` | Validates and converts output values according to their types specified in lexicon. Works only for translation to staircase v0 language. | | `data`required | `object` | Any object in a valid Staircase model | | `version` | `integer` | Version of staircase language`0``1` | | `metadata` | `object` | Any metadata about this translation | | `transaction_id` | `string` | Transaction ID associated with this translation. This value will be used in reporting to Health. | | `collection_id` | `string` | Collection ID associated with this translation. This value will be used in reporting to Health. | | `sc_version_from` | `integer` | For staircase to staircase translations - when lang_from and lang_to are staircase | | `sc_version_to` | `integer` | For staircase to staircase translations = when lang_from and lang_to are staircase | | `async` | `boolean` | When false, translation will be returned in a synchronous manner. If async is turned on, translation and translation status will need to be retrieved via Retrieve Translation. | | `callback_url` | `string` | Webhook URL to receive translation result | ##### Response `202``application/json` 3 fields Async translation accepted | Field | Type | Description | | --- | --- | --- | | `translation_id` | `string` | Translation ID | | `started_at` | `string` | Time when translation started in DateTime format | | `callback_url` | `string` | Webhook URL to receive translation result | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Error message | | `invalid_paths` | `object[]` | Details about the request and invalidity | | `path` | `string` | Path from the request | | `message` | `string` | Details about invalidity | ##### Response `403``application/json` 2 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `url` | `string` | API URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Other responses `200``422` ### Language Operations `POST` `/product/products/language/invocations` #### Extended Translate `extendedTranslate` Current Endpoint performs extended translation service, which includes invocation extension and entity translation along with regular translation. In order to execute extended translation workflow provide `from_language`, `to_language` and `data` fields in the `request_data` object. Operation is async, in order to check status input "language" as `product_name` and returned `invocation_id` to retrieve status endpoint. ##### Request application/json Copy ``` { "request_data": { "from_language": "staircase-graph", "to_language": "test_language_1", "data": { "invocations": [ { "has_invocation_code_type": { "has_value": "40004" } } ], "graph_entities": [ { "has_data_path": { "has_value": "person/has_first_name" } } ] } } } ``` ##### Response 202400404 application/json Copy Generated rules ``` { "product_flow_name": "language-translation-workflow", "metadata": {}, "response_collection_id": "01H7SQAMJ98YT3D0KJ9W99D647", "invocation_mode": "single_flow", "widget_url": "", "invocation_id": "01H7SQAMJ98YT3D0KJ9W99D647", "invocation_status": "STARTED", "transaction_id": "01H7SQAK56R1DB10255J2M780K", "request_collection_id": "01H7SQAMTH9A84SEBDMSCNCET5", "request_data": { "from_language": "staircase-graph", "to_language": "test_language_1", "data": { "invocations": [ { "has_invocation_code_type": { "has_value": "40004" } } ], "graph_entities": [ { "has_data_path": { "has_value": "person/has_first_name" } } ] } }, "api_id": null, "_links": { "health_metrics": "https://bushnell.staircaseapi.com/code-health-checker/metric/01H7SQAK56R1DB10255J2M780K?product_name=language" } } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Resource is not found ``` { "message": "Job not found." } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `request_data` | `object` | Request data. | | `from_language` | `string` | Language name to translate from. | | `to_language` | `string` | Language name to translate to. | | `data` | `object` | Content to translate. | ##### Response `202``application/json` 9 fields Generated rules | Field | Type | Description | | --- | --- | --- | | `product_flow_name` | `string` | Name of the executed product flow. | | `invocation_id` | `string` | Invocation ID. | | `invocation_status` | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id` | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `request_data` | `object` | Input data. | | `response_collection_id` | `string` | Response Collection ID. | | `widget_url` | `string (uri)` | URL of the widget. | | `metadata` | `object` | Response collection metadata. | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ### Operations `POST` `/hello-world` #### Hello World Dummy hello world endpoint ##### Other responses `200` `GET` `/info` #### Info endpoint Placeholder endpoint. As this is a language repo, it must be used in conjunction with the Translator Service. ##### Other responses `200` `POST` `/languages` #### Export language `export_language` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | API key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `langugage_description_url` | `string` | — | ##### Response `201``application/json` 1 fields 201 response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | — | ##### Response `400``application/json` 1 fields No language by specified url | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ## Errors `400``403``404``422``500` ## More in Data - Previous product: Content - Next product: ML --- # ML # ML Document and image models: signature detection, hosted document extraction, and the training-data pipelines behind them. Two model families. Signature detection answers whether a page carries a signature and where, which is what makes an executed-document check automatic. Document extraction reads fields from a page image. Training data comes from a labelling pipeline that annotates real mortgage documents rather than generated ones, and accuracy per vendor and per document type is reported by Document. ## How it works Hosting a vendor's extraction engine rather than calling its API was a deliberate option, and the deployment path for it is Host. The choice turns on where the document is allowed to be, not on which is easier to integrate. ## Operations ### AWSDocumentAI `POST` `/document` #### OCR process document `document` Long-running operation endpoint to process document by AWS Textract OCR. ##### Request application/json Copy An example of a batch request. Presigned URLs shown here are just examples, you need to provide valid and active Presigned URLs when making the request. ``` { "urls": [ "https://somebucketname.s3.us-east-1.amazonaws.com/test.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host", "https://somebucketname.s3.us-east-1.amazonaws.com/MultiDocs_10_pages.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host", "https://somebucketname.s3.us-east-1.amazonaws.com/Form1040_Leo.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host" ] } ``` ##### Response 200400 application/json400 text/html401403 application/json Copy Ok. ``` { "documents_info": [ { "uuid": "2db2abe018862e9c4e4cf340696da14ecf3ff37ba153d68ab6796433468e5e48", "url": "https://files.consumerfinance.gov/f/201311_cfpb_kbyo_closing-disclosure.pdf" } ] } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `urls`required | `string[]` | One or more Presigned URLs of PDFs to extract data from. | | `processor` | `string` | Name of AWS DocumentAI processor to be used for data extractionExample `irs_w2` | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `documents_info` | `object[]` | Array of IDs for query results of OCR. | | `uuids` | `object` | UUIDs associated with the documents being processed as part of the batch. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/test-model/{job_id}` #### Retrieve Extracted Data `test-model-status` Get test train document status This service allows getting result of test model. ##### Response 200401403404 application/json Copy Ok. ``` { "code": 200, "pages": [ { "num": 1, "width": 612, "height": 792, "id": "01FQ1V5WYZCKMAZ0DQQNTVPC3C" } ], "annotations": [ { "annotation_spec_id": 5708576960238584000, "display_name": "has_social_security_number", "text_extraction": { "score": 0.9998301267623901, "text_segment": { "start_offset": 86, "end_offset": 96, "content": "123-45-678" } }, "page": "01FQ1V5WYZCKMAZ0DQQNTVPC3C", "bounding_box": { "top_ratio": 0.7323232293128967, "left_ratio": 0.4901960790157318, "height_ratio": 0.012626290321350098, "width_ratio": 0.09477123618125916 } } ], "document_text": "For Official Use Only\nOMB No. XXXXXXX\n22222\na Employee's social security number\nVoid\n123-45-678", "transaction_id": "df5039ba-c650-4e73-8b0a-af6e0b031c15", "train_product_id": "01FQBA6JJNHHN57RBKP0VZPYV4", "processed_pages_count": 8, "units": 33 } ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy File not found ``` { "code": "Not Found", "message": "Nothing matches the given URI" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string` path | `d8b01c18-10f7-4a71-962-43eeaed5ae6b` | Job ID of the test document operation. | ##### Response `200``application/json` 8 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Test model status code.Example `200` | | `pages` | `object[]` | List of pages. | | `id` | `string` | Unique page identifier.Example `01FQ1V5WYZMGW5SQTKQH1DSMTX` | | `num` | `number` | Page number.Example `1` | | `width` | `number` | Page width in points.Example `612` | | `height` | `number` | Page height in points.Example `792` | | `annotations` | `object[]` | Annotations elements | | `annotation_spec_id` | `integer` | Annotation identification. | | `display_name` | `string` | Annotation name. | | `text_extraction` | `object` | Extraction object. | | `score` | `number` | Annotation score. | | `text_segment` | `object` | Text Segment object. | | `start_offset` | `integer` | Character offsets rather than byte offsets. | | `end_offset` | `integer` | Character offsets rather than byte offsets. | | `content` | `string` | Annotation content. | | `page` | `string` | Page identifier.Example `01FQ1V5WYZMGW5SQTKQH1DSMTX` | | `bounding_box` | `object` | Bounding boxes of extracted text. | | `top_ratio` | `number` | Top ratio of bounding boxExample `0.7462121248245239` | | `left_ratio` | `number` | Left ratio of bounding boxExample `0.779411792755127` | | `height_ratio` | `number` | Height ratio of bounding boxExample `0.010101020336151123` | | `width_ratio` | `number` | Width ratio of bounding boxExample `0.026143789291381836` | | `train_product_id` | `string` | Unique train product execution ID.Example `01FQBA6JJNHHN57RBKP0VZPYV4` | | `transaction_id` | `string` | Transaction ID for the generated health metrics.Example `df5039ba-c650-4e73-8b0a-af6e0b031c15` | | `document_text` | `string` | Content of extract file.Example `For Official Use Only OMB No. XXXXXXX 22222 a Employee's social security number Void 123-45-678` | | `processed_pages_count` | `number` | Count of processed pages. It can be the same or less than in the original document.Example `8` | | `units` | `number` | Count of comprehend units used for extraction.Example `33` | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields File not found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | File not found error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Reason why document was not extracted.Example `Test model result contains overlapped annotations` | `POST` `/generate-gs` #### Convert GTL and OCR to annotations `generate-gs` Convert GTL and OCR input to annotations. Annotations will be used for training models for AWS Comprehend. ##### Request application/json Copy ``` { "gtl": { "documents": [ { "@type": "closing_disclosure" } ] }, "gc_presigned_download_urls": [ "https://dev-data-manager-blobs-bucket-us-east-1-1111111.s3.amazonaws.com/foo.json?" ] } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `gtl`required | `object` | Input from GTL | | `documents` | `object[]` | Array of documents from GTL | | `@type`required | `string` | Document typeExample `closing_disclosure` | | `gc_presigned_download_urls`required | `string[]` | Presigned URL for document | ##### Response `200``application/json` 2 fields Successful response. | Field | Type | Description | | --- | --- | --- | | `annotations` | `object[]` | Array of labels, contains label name, value, GTL value and text segment info. | | `displayName` | `string` | Data point (label) name | | `value` | `string` | Value for this data point | | `gtlValue` | `string` | GTL value for this data point, usually V2 output | | `textExtraction` | `object` | Data about where this data point is located in document | | `page` | `number` | Page numberExample `1` | | `textSegment` | `object` | Where data point text starts and ends. | | `startOffset` | `number` | Index of text start | | `endOffset` | `number` | Index of text end | | `document` | `object` | Data about text for each page in document | | `documentText` | `object` | Object with data for text extracted | ##### Response `400``application/json` 1 fields Incorrect payload | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Reason why request was not processed.Example `Error on getting data from presigned URL` | `GET` `/models` #### Retrieve Trained Models `get-models` Get trained models This service allows getting a list of trained Comprehend models. ##### Response 200401 application/json Copy Ok. ``` { "count": 2, "models": [ { "name": "mortgage-insurance-certificate", "versions": [ { "name": "2022-05-12-10-25-09", "precision": 62.68656716417911, "annotations": [ "has_organization_name", "has_insurance_policy_identifier", "has_insurance_policy_effective_date", "has_mortgage_insurance_premium_rate_percent", "has_mortgage_insurance_duration_type", "has_mortgage_insurance_premium_paid_by_type", "has_mortgage_insurance_coverage_percent", "has_mortgage_insurance_premium_refundable_type", "has_mortgage_insurance_premium_calculation_type", "has_mortgage_insurance_third_premium_rate_percent", "has_mortgage_insurance_subsequent_premium_rate_percent" ] } ] }, { "name": "closing-disclosure", "versions": [ { "name": "2022-05-12-13-49-36", "precision": 72.83441367118444, "annotations": [ "applicant_document_date", "product", "loan_type", "sale_price", "interest_rate", "monthly_principal_interest", "mortgage_insurance_required", "property_taxes_in_escrow", "homeowners_insurance_in_escrow", "prepaid_property_taxes_months", "prepaid_property_taxes_amount", "loan_disclosures_assumption", "loan_disclosures_late_payment", "applicant_document_signature" ] }, { "name": "2022-03-31-20-54-33", "precision": 58.03921568627452, "annotations": [ "has_prepaid_taxes_months_count", "has_prepaid_taxes_amount", "has_assumability_indicator", "has_late_charge_type", "has_document_date", "has_loan_amortization_type", "has_mortgage_insurance_required_indicator", "has_tax_escrow_required_indicator", "has_hazard_insurance_escrow_required_indicator" ] } ] } ] } ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `count` | `number` | Count of trained modelsExample `11` | | `models` | `object[]` | List of models. | | `name` | `string` | Model name.Example `closing-disclosure` | | `versions` | `object[]` | List of versions. | | `name` | `string` | Version name.Example `2022-05-12-10-25-09` | | `precision` | `number` | Version precision.Example `70.35830618892508` | | `annotations` | `string[]` | List of trained annotations. | | `status` | `string` | Status of the version. Only trained or imported models are used for extraction.Example `TRAINED` | | `message` | `string` | Message about model version status.Example `TRAINED` | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/setting` #### Settings `settings` AWS Comprehend settings. Can be used for update inference units count to increase throughput. 1 inference unit corresponds to throughput in 100 characters per second. ##### Request application/json Copy ``` { "inference_units_count": 3 } ``` ##### Response 202400 application/json400 text/html403 application/json Copy Request accepted. ``` { "message": "Settings have been successfully updated" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `inference_units_count`required | `integer` | Comprehend inference units count. | ##### Response `202``application/json` 1 fields Request accepted. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response message | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ### ML `POST` `/extract` #### Detect human signature `detectSignature` Check if PDF contains a human written signature ##### Response 200400 application/json400 text/html403 application/json Copy Ok. ``` { "job_id": "WB6XV833KNWF0GZ7" } ``` application/json Copy Bad Request. ``` { "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | Extraction job ID | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | `POST` `/extract/{job_id}` #### Detect human signature status `detectSignatureStatus` Check status of extraction job ##### Response 200400 application/json400 text/html403404 application/json Copy Ok. ``` { "is_signed": true, "page": 7 } ``` application/json Copy Bad Request. ``` { "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Forbidden ``` { "message": "Extraction job not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string` path | `WB6XV833KNWF0GZ7` | Extraction Job ID. | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `is_signed` | `boolean` | Is document signed | | `page` | `number` | Page with signature | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Platform `GET` `/products/train_data_extraction/response-schema` #### Retrieve Response Schema `retrieveResponseSchema` Retrieve Schema retrieves a JSON schema for the response returned by the product. It can also return an example for the response output object through return_example attribute. ##### Response 200400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Successfully returned the list of elements of response of the product waterfall. ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values: true, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "description": "Error Message.", "type": "string" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `return_examples` | `boolean` query | `false` | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 1 fields Successfully returned the list of elements of response of the product waterfall. | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | Element key / value element | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` Retrieve Transaction Collections returns the content of a given `collection_id` associated with a specific `transaction_id`. ##### Response 200400403404500 application/json Copy Transaction collection retrieved successfully ``` { "data": {} } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Transaction collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `array` | The data | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given `collection_id` associated with a `transaction_id`. ##### Request application/json Copy ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` ##### Response 200400 UpdateCollectionError400 text/html403404 UpdateCollectionError404 text/html500 application/json Copy Collection updated successfully ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` application/json Copy Error ``` { "description": "Error details.", "message": "Unable to update collection. Please check the collection data" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data object | ##### Response `200``application/json` 1 fields Collection updated successfully | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data object | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### DocumentAI `POST` `/setup-credentials` #### Set Up Google Cloud Account Credentials `setup-credentials` Setup Google Cloud service account credentials Setup Google Cloud credentials in the form of a service account key in order to authenticate an application as a service account. ##### Request application/json Copy An example of a Google Cloud service account key. The key shown is just an example, you need to provide a valid key in order to use the service. ``` { "type": "service_account", "project_id": "my-great-project-1234560", "private_key_id": "aeb28addda999e5dde66de00041a1fd99ed7e4a32", "private_key": "", "client_email": "name-of-the-service-account@my-great-project-1234560.iam.gserviceaccount.com", "client_id": "378463746364563353673", "auth_uri": "https://accounts.google.com/o/oauth2/auth", "token_uri": "https://oauth2.googleapis.com/token", "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs", "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/name-of-the-service-account%40my-great-project-1234560.iam.gserviceaccount.com" } ``` ##### Response 200400 application/json400 text/html401403408409500501502503 application/json Copy Ok. ``` { "code": "200", "message": "The credentials have been saved." } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Request body`application/json` 10 fields | Field | Type | Description | | --- | --- | --- | | `type`required | `string` | The type of member this key is for.Example `service_account` | | `project_id`required | `string` | The project identifier.Example `my-great-project-1234560` | | `private_key_id`required | `string` | The project key identifier.Example `aeb28addda999e5dde66de00041a1fd99ed7e4a32` | | `private_key`required | `string` | The private key contents.Example `` | | `client_email`required | `string` | The client emails.Example `name-of-the-service-account@my-great-project-1234560.iam.gserviceaccount.com` | | `client_id`required | `string` | The client id.Example `378463746364563353673` | | `auth_uri`required | `string` | The authorization URI.Example `https://accounts.google.com/o/oauth2/auth` | | `token_uri`required | `string` | The token URI.Example `https://oauth2.googleapis.com/token` | | `auth_provider_x509_cert_url`required | `string` | The URL of the public x509 certificate provider.Example `https://www.googleapis.com/oauth2/v1/certs` | | `client_x509_cert_url`required | `string` | The RL of the public x509 certificate.Example `https://www.googleapis.com/robot/v1/metadata/x509/name-of-the-service-account%40my-great-project-1234560.iam.gserviceaccount.com` | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `string` | Status code. | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/batch-process-document` #### Process Batch `new-batch` Long-running operation endpoint to batch process many documents. ##### Request application/json Copy An example of a batch request. Presigned URLs shown here are just examples, you need to provide valid and active Presigned URLs when making the request. ``` { "urls": [ "https://somebucketname.s3.us-east-1.amazonaws.com/test.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host", "https://somebucketname.s3.us-east-1.amazonaws.com/MultiDocs_10_pages.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host", "https://somebucketname.s3.us-east-1.amazonaws.com/Form1040_Leo.pdf?X-Amz-Algorithm=&X-Amz-Credential=%2F20180210%2Feu-west-2%2Fs3%2Faws4_request&X-Amz-Date=&X-Amz-Expires=1800&X-Amz-Signature=&X-Amz-SignedHeaders=host" ] } ``` ##### Response 200400 application/json400 text/html401403408409500501502503 application/json Copy Ok. ``` { "documents_info": [ { "uuid": "4a58346a-dc5b-4678-bc9c-3553952a896b", "url": "https://files.consumerfinance.gov/f/201311_cfpb_kbyo_closing-disclosure.pdf" } ] } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `urls`required | `string[]` | One or more Presigned URLs of PDFs to extract data from. | | `processor` | `string` | Name of DocumentAI processor to be used for data extractionExample `irs_w2` | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `documents_info` | `object[]` | UUIDs associated with the documents being processed as part of the batch. | | `uuid` | `string (uuid)` | Unique ID for querying results.Example `4a58346a-dc5b-4678-bc9c-3553952a896b` | | `url` | `string (uri)` | URL for file from request.Example `https://files.consumerfinance.gov/f/201311_cfpb_kbyo_closing-disclosure.pdf` | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/document/{uuid}` #### Retrieve Extracted Data `retrieve-extracted-data` Retrieve extracted data Retrieves the extracted data of a document based on the UUID assigned to it when accepted to be processed as part of a batch operation. ##### Response 400 application/json400 text/html401403408409500501502503 application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `uuid` required | `string` path | `d8b01c18-10f7-4a71-962-43eeaed5ae6b` | UUID of the document which extracted data it's being requested. | ##### Response `200``application/json` 6 fields Ok. | Field | Type | Description | | --- | --- | --- | | `uri` | `string` | Google Storage location where the file was uploaded to be processed by Document AI.Example `gs://staircase-host-documentai/batch/input/d8b01c18-10f7-4a71-9612-43eeaed5ae6b-test.pdf` | | `mimeType` | `string` | Mime type of the documentExample `application/pdf` | | `text` | `string` | Extracted data as plain textExample `22222 Void 999-00-0000 a Employee’s social security number For Official Use Only ▶ OMB No. 1545-0008 b Employer identification number (EIN) 1 Wages, tips, other compensation 2 Federal income tax withheld 12-3456789 c Employer’s name, address, and ZIP code 3 Social security wages 4 Social security tax withheld Ocrolus Inc. 101 Greenwich Street, Floor 23 New York, NY 10006 5 Medicare wages and tips 6 6 Medicare tax withheld 7 Social security tips 8 Allocated tips d Control number 9 10 Dependent care benefits e Employee’s first name and initial Last name Suff. M99999 John Doe 123 Main Street New York, NY 10001 100000.00 15000.00 98750.00 7500.00 98750.00 4500.00 0.00 0.00 0.00 D 1000.00 x 11 Nonqualified plans 12a See instructions for box 12 C o d e 13 Statutory Retirement Third-party employee plan sick pay 12b C o d e 14 Other 12c C o d e 12d C o d e NY-PFR 223.25 f Employee’s address and ZIP code 15 State Employer’s state ID number 16 State wages, tips, etc. 17 State income tax 18 Local wages, tips, etc. 19 Local income tax 20 Locality name NY | 999999999 100000.00 9000.00 W-2 Wage and Tax Statement Form 2019 Copy A For Social Security Administration — Send this entire page with Form W-3 to the Social Security Administration; photocopies are not acceptable. Department of the Treasury—Internal Revenue Service For Privacy Act and Paperwork Reduction Act Notice, see the separate instructions. Cat. No. 10134D Do Not Cut, Fold, or Staple Forms on This Page` | | `pages` | `object[]` | Pages of the document | | `entities` | `object[]` | Entities of the document | | `shardInfo` | `object` | Share info of the document | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 2 fields Not found. | Field | Type | Description | | --- | --- | --- | | `code` | `string` | Error type.Example `Not Found` | | `message` | `string` | Reason of errorExample `Nothing matches the given uuid` | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/document-type` #### Create New Document Type `document-type` Create new document type. Create new document type to train a model with DocumentAI. ##### Request application/json Copy An example of a document type. ``` { "name": "W-2" } ``` ##### Response 201400 application/json400 text/html401403408409500501502503 application/json Copy Ok. ``` { "message": "The data started to import successfully" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | The name of document type. | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/auto-train` #### Retrieve auto train configurations `reetrieve-auto-train-configurations` Get a list of automatic training configurations with statuses and ready-to-train document counts. ##### Response 200403 application/json Copy Ok. ``` [ { "documentType": "W-2", "enabled": true, "readyForTrainCount": 12 }, { "documentType": "closing_disclosure", "enabled": false, "readyForTrainCount": 20 } ] ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `documentType` | `string` | Document type.Example `W-2` | | `enabled` | `boolean` | Is auto training enabled.Example `true` | | `readyForTrainCount` | `number` | Ready for training documents count.Example `12` | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | `PUT` `/auto-train/{document_type_name}` #### Auto Train Document Type `auto-train-document` Auto train document type Inserting a configuration to enable automatic training of document type. ##### Request application/json Copy An example of configuration. ``` { "enabled": true } ``` ##### Response 201400 application/json400 text/html403 application/json Copy Ok. ``` { "message": "Auto training configuration successfully created" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type_name` required | `string` path | `W-2` | The name of document type | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `enabled`required | `boolean` | Status of auto training.Example `true` | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Configuration creation message.Example `Auto training configuration successfully created` | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | message | `PUT` `/train-document/{document_type_name}` #### Train Document Type `train-document` Train document type This service imports documents annotations and labels to a document type created. The model is trained when the number of documents is enough to train, validate and test. ##### Request application/json Copy An example of document. ``` [ { "annotations": [ { "displayName": "Employee_lastname", "textExtraction": { "textSegment": { "startOffset": "794", "endOffset": "800" } } } ], "document": { "documentText": { "content": "Safe, Accurate,\nVisit the IRS Website\na Employee's social" } } } ] ``` ##### Response 200400 application/json400 text/html401403408409500501502503 application/json Copy Ok. ``` { "code": "200", "message": "The data started to import successfully" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type_name` required | `string` path | `W-2` | The name of document type | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `annotations` | `object[]` | — | | `displayName` | `string` | Name of annotations.Example `Employee_lastname` | | `textExtraction` | `object` | — | | `textSegment` | `object` | — | | `startOffset` | `string` | Start of annotation.Example `794` | | `endOffset` | `string` | End of annotation.Example `800` | | `document` | `object` | — | | `documentText` | `object` | — | | `content` | `string` | Content of annotation.Example `Safe, Accurate, Visit the IRS Website a Employee's social` | | `document_url` | `string` | Download URL of the document.Example `https://foobarwebsite.com/filename.pdf` | | `dataset_id_to_train` | `string` | Dataset ID to be trained.Example `foobarid123` | ##### Response `200``application/json` 2 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `one of` | Status code. | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | message | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/test-model` #### Test Train Document Type `test-model` Test train document type This service allows to test a document type created and trained with DocumentAI. ##### Request application/json Copy An example of test a model. ``` { "document_type_name": "W-2", "url": "https://www.example.com/test.pdf", "transaction_id": "01ARZ3NDEKTSV4RRFFQ69G5FAV" } ``` ##### Response 200400 application/json400 text/html401403408409500501502503 application/json Copy Ok. ``` { "code": 200, "pages": [ { "num": 1, "width": 612, "height": 792, "id": "01FQ1V5WYZCKMAZ0DQQNTVPC3C" } ], "annotations": [ { "annotation_spec_id": 5708576960238584000, "display_name": "has_social_security_number", "text_extraction": { "score": 0.9998301267623901, "text_segment": { "start_offset": 86, "end_offset": 96, "content": "123-45-678" } }, "page": "01FQ1V5WYZCKMAZ0DQQNTVPC3C", "bounding_box": { "top_ratio": 0.7323232293128967, "left_ratio": 0.4901960790157318, "height_ratio": 0.012626290321350098, "width_ratio": 0.09477123618125916 } } ], "document_text": "For Official Use Only\nOMB No. XXXXXXX\n22222\na Employee's social security number\nVoid\n123-45-678", "transaction_id": "df5039ba-c650-4e73-8b0a-af6e0b031c15", "train_product_id": "01FQBA6JJNHHN57RBKP0VZPYV4" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `model_id` | `string` query | `TEN8439699522203942912` | Specific model ID | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `document_type_name`required | `string` | The name of document type. | | `url`required | `string` | URL file. | | `transaction_id` | `string` | Transaction ID. Generated by default | ##### Response `200``application/json` 6 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Test model status code.Example `200` | | `pages` | `object[]` | List of pages. | | `id` | `string` | Unique page identifier.Example `01FQ1V5WYZMGW5SQTKQH1DSMTX` | | `num` | `number` | Page number.Example `1` | | `width` | `number` | Page width in points.Example `612` | | `height` | `number` | Page height in points.Example `792` | | `annotations` | `object[]` | Annotations elements | | `annotation_spec_id` | `integer` | Annotation identification. | | `display_name` | `string` | Annotation name. | | `text_extraction` | `object` | Extraction object. | | `score` | `number` | Annotation score. | | `text_segment` | `object` | Text Segment object. | | `start_offset` | `integer` | Character offsets rather than byte offsets. | | `end_offset` | `integer` | Character offsets rather than byte offsets. | | `content` | `string` | Annotation content. | | `page` | `string` | Page identifier.Example `01FQ1V5WYZMGW5SQTKQH1DSMTX` | | `bounding_box` | `object` | Bounding boxes of extracted text. | | `top_ratio` | `number` | Top ratio of bounding boxExample `0.7462121248245239` | | `left_ratio` | `number` | Left ratio of bounding boxExample `0.779411792755127` | | `height_ratio` | `number` | Height ratio of bounding boxExample `0.010101020336151123` | | `width_ratio` | `number` | Width ratio of bounding boxExample `0.026143789291381836` | | `train_product_id` | `string` | Unique train product execution ID.Example `01FQBA6JJNHHN57RBKP0VZPYV4` | | `transaction_id` | `string` | Transaction ID for the generated health metrics.Example `df5039ba-c650-4e73-8b0a-af6e0b031c15` | | `document_text` | `string` | Content of extract file.Example `For Official Use Only OMB No. XXXXXXX 22222 a Employee's social security number Void 123-45-678` | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/status-document/{document_type_name}` #### Retrieve Status of Training Document `get-status-document` Get status of training document This service retrieves the status of the document in the DocumentAI training ##### Response 201400 application/json400 text/html401403404408409500501502503 application/json Copy Ok. ``` { "status": "COMPLETE" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy File not found ``` { "code": "Not Found", "message": "Nothing matches the given URI" } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type_name` required | `string` path | `W-2` | The name of document type | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | The status can be IN PROGRESS or COMPLETEExample `COMPLETE` | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields File not found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | File not found error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/status-credentials` #### Get Status of Credentials `get-status-credentials` Get status of credentials This service retrieves the status of the credentials ##### Response 201400 application/json400 text/html401403404408409500501502503 application/json Copy Ok. ``` { "status": "COMPLETE" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy File not found ``` { "code": "Not Found", "message": "Nothing matches the given URI" } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | The status can be IN PROGRESS or COMPLETEExample `COMPLETE` | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields File not found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | File not found error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/create-model` #### Create Model `create-model` Create model This service allows creating new model. But process lasts around 3 hours. ##### Request application/json Copy An example of create a model. ``` { "document_type_name": "W-2" } ``` ##### Response 200400 application/json400 text/html401403408409500501502503 application/json Copy Ok. ``` { "code": "200", "message": "The process to create the new model has started. The process lasts about 3 hours" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Request Timeout. ``` { "code": "408", "message": "SoftworksAI partner is not available." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Not Implemented ``` { "code": "501", "message": "Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` application/json Copy Service Unavailable ``` { "code": "503", "message": "Error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `document_type_name`required | `string` | The name of document type. | ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `code` | `one of` | Status code. | | `operation` | `string` | Operation id of transaction. | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `408``application/json` 1 fields Request Timeout. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Timeout error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `501``application/json` 1 fields Not Implemented | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `PATCH` `/documents/{document_type}` #### Update document `updateDocument` Update document, currently only model ID can be updated ##### Request application/json Copy An example of document update. ``` { "model_id": "23ff8e7e-765a-414f-bb04-969298b81c19" } ``` ##### Response 400 application/json400 text/html403 application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type` required | `string` path | `W-2` | Document type. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `model_id`required | `string` | Model id | ##### Response `200``application/json` 1 fields Model updated | Field | Type | Description | | --- | --- | --- | | `document` | `object` | Document | | `document_type` | `string` | Document type | | `dataset_id` | `string` | Dataset ID | | `model_id` | `string` | Model ID | | `count_docs` | `number` | Count docs | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/documents/{document_type}/models` #### Retrieve document models `retireveDocumentModels` ##### Response 400 application/json400 text/html403404 application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy File not found ``` { "code": "Not Found", "message": "Nothing matches the given URI" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type` required | `string` path | `W-2` | Document type. | ##### Response `200``application/json` 1 fields Document models | Field | Type | Description | | --- | --- | --- | | `models` | `object[]` | Models. | | `model_id` | `string` | Model ID. | | `dataset_id` | `string` | Dataset ID. | | `status` | `string` | Deployment status`deployed``deployment_state_unspecified``undeployed` | | `create_time` | `string (datetime)` | Time when the model training finished and can be used for prediction. | | `update_time` | `string (datetime)` | Time when this model was last updated. | | `active` | `boolean` | Is active flag | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields File not found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | File not found error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/create-dataset` #### Create New Dataset `create-dataset` Create new Dataset. Create new Dataset for a specific document type. ##### Request application/json Copy An example of a document type. ``` { "document_type": "closing_disclosure", "dataset_name": "dt_closing_disclosure_23" } ``` ##### Response 201400 application/json400 text/html401403409500502 application/json Copy Created. ``` { "message": "The Dataset was created successfully" } ``` application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Unauthorized. ``` { "code": "401", "message": "This token is not valid for this service." } ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy Conflict ``` { "code": "409", "message": "Batch already exists" } ``` application/json Copy Internal Server Error ``` { "code": "500", "message": "Internal Server Error" } ``` application/json Copy Bad Gateway ``` { "code": "502", "message": "Error" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `document_type`required | `string` | The name of document type. | | `dataset_name`required | `string` | The name of the Dataset. | | `required_labels` | `string[]` | The labels that are required in the Dataset. | | `acceptable_labels` | `string[]` | The labels that are acceptable in the Dataset. | ##### Response `201``application/json` 1 fields Created. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | The message. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `401``application/json` 1 fields Unauthorized. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unauthorized error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessable entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields Internal Server Error | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `502``application/json` 1 fields Bad Gateway | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Conflict error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `DELETE` `/documents/{document_type}/models/{model_id}` #### Delete model `deleteModel` Delete trained model. ##### Response 400 application/json400 text/html403404 application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` application/json Copy File not found ``` { "code": "Not Found", "message": "Nothing matches the given URI" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type` required | `string` path | `W-2` | Document type. | | `model_id` required | `string` path | `TEN0007099176139227136` | Model ID. | | `force` | `boolean` query | `false` | Include model deletion from GCP. | ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields File not found | Field | Type | Description | | --- | --- | --- | | `error` | `object` | File not found error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Other responses `204` ### Workflow `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Response 201403500 application/json Copy Transaction created successfully ``` { "created_at": "03/04/2021, 1:04:05 PM EST", "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB" } ``` application/json Copy 403 invalid error ``` { "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" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `POST` `/blobs/upload` #### Upload Document `uploadBlob` Upload Blob allows a customer to upload a document in .pdf form. Upload Blob uploads a .pdf document (blob) to Persistence product. You can upload PDF using HTML Request Maker Try It Out. Place your API key in the request header, set the request body to binary and browse to your document. Click Send to upload your document. To upload a document programmatically, use the programmatic upload example below. After the approval document is successfully uploaded, a blob_id value is provided. Example: 'blob_id': '01EZYHKY4EXFW4Z8RKWHDP1KHB' After you got successful response, you need to use the blob_id in collection with the following path. Show the rest ``` $.document_sets.document_set[0].documents.document[0].foreign_objects.foreign_object[0].staircase_blob_id ``` To upload a document within code, you can to use a below example. ``` import requests with open("document.pdf", "rb") as document: payload = document.read url = "" headers = { "x-api-key": ..., "Content-Type": "application/pdf" } response = requests.post(url, headers=headers, data=payload) if response.ok: blob_id = response.json["blob_id"] ``` ##### Request application/octet-stream Copy ``` Select option 'binary' in order to upload file ``` ##### Response 201403500 application/json Copy Blob uploaded ``` { "blob_id": "01EZY9J8SEFM2JKDJ1Q3YX65HS" } ``` application/json Copy 403 invalid error ``` { "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" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | ##### Response `201``application/json` 1 fields Blob uploaded | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string` | Created blob id | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400``405``422` `GET` `/products/train_data_extraction/request-schema` #### Retrieve Request Schema `retrieveRequestSchema` Retrieve Request Schema retrieves a JSON schema for the request to the product waterfall. It also has the option of returning an example for the request object expected through the return_example attribute. ##### Response 200400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Successfully returned the list of elements needed for product waterfall. ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values: true, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "description": "Error Message.", "type": "string" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `return_examples` | `boolean` query | `false` | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 1 fields Successfully returned the list of elements needed for product waterfall. | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | Element key / value | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /get-collection ##### Request application/json Copy ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collection data" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction ID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data object | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `array` | The data | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `POST` `/products/train_data_extraction/invocations` #### Extract data from document `InvokeSpecificProductFlow` Invoke TrainDataExtraction Invoke Specific Product Flow helps you to invoke specific product flow, this endpoint shall: - Validate the input `transaction_id`, `request_collection_id`, `response_collection_id` if provided; - Create transaction if the `transaction_id` was not provided; - Create input collection with the `request_data` provided if the `request_collection_id` was not provided; - Create empty output collection if the `response_collection_id` was not provided; - Validate the provided product name and the product flow name; - Retrieve the product flow information associated to the provided Product Flow Name; Show the rest - Translate the input collection from Staircase language to Vendor language if `input_translation_language` was configured for the product flow; - Run the connector flow associated to the Product Flow Name; - Set the status, `invocation_id` and `output_translation_language` that will be used to translate the results from Vendor Language to Staircase language if `output_translation_language` was configured for the product flow. - Send a callback, when the flow execution will be finished if `callback_url` was specified with an input data for the invocation. The callback request body is a JSON with the following schema: ``` { "type": "object", "$schema": "", "required": [ "invocation_id", "invocation_status" ], "properties": { "invocation_id": { "type": "string", "format": "uuid" }, "invocation_status": { "type": "string", "enum": [ "COMPLETED", "FAILED" ] }, "response_data": { "type": "object", "additionalProperties": true }, "failure_reason": { "type": "string" } } } ``` ##### Request application/json Copy ``` { "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "product_flow_name": "Alloy", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4" } ``` ##### Response 201400403404500 application/json Copy Successfully started flow invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "output_language_name": "staircase", "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "invocation_status": "STARTED", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string (uri)` | Callback URL. | | `product_flow_name` | `string` | 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. | | `request_collection_id` | `string` | Request Collection ID. | | `request_data` | `object` | Request JSON body. | | `response_collection_id` | `string` | Response Collection ID. | | `transaction_id` | `string` | Transaction ID used for invocation. | | `vendor_name` | `string` | Vendor name. Cannot be specified together with product_flow_name. | ##### Response `201``application/json` 7 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string` | Callback URL. | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`STARTED` | | `metadata` | `object` | The metadata of the invoked product flow. | | `product_flow_name` | `string` | Product flow name. | | `request_data` | `object` | The data for the request collection. | | `transaction_id`required | `string` | Transaction ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/train_data_extraction/invocations/{invocation_id}` #### Retrieve Status `RetrieveProductFlowInvocationStatus` Status Retrieves the status of running Product flow invocation. ##### Response 200400403404500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "invocation_status": "COMPLETED", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "updated_at": "2021-05-27T15:17:59.859954-04:00" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `invocation_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Product flow invocation identifier | ##### Response `200``application/json` 9 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string` | URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished. | | `invocation_status`required | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `metadata` | `object` | Response Collection ID. | | `request_collection` | `object` | Collection. | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `request_collection_id` | `string` | Request Collection ID. | | `response_collection` | `object` | Collection. | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `response_collection_id` | `string` | Response Collection ID. | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `widget_url` | `string (uri)` | URL of the widget. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 200403404 GetCollectionError404 GetCollectionsError500 application/json Copy Successfully Retrieved Collection ``` { "addresses": [ { "address_line_1_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "56319 Underwood Views", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MQEN90HSCMPQWCAD", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.13863636363636364, "has_bounding_box_width_ratio": 0.23529411764705882, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "address_line_2_text": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Lake Debramouth NE 33667-9751", "with_data_extraction_metadata": { "@id": "01FBHPXCJ110EKH48ZQEK3YQFF", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.07352941176470588, "has_bounding_box_top_ratio": 0.15636363636363637, "has_bounding_box_width_ratio": 0.31411764705882356, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "documents": [ { "@id": "01FBHN4YR48XC75HJF5Z9VRBTV", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FBHN11S8SF835QXB8M1EBZGG" }, "with_page_extraction_metadata": [ { "@id": "01FBHPXCJ03V0AAHVGW6G1YE08", "page_height": 2200, "page_number": 1, "page_width": 1700 } ] } ], "employment": [ { "retirement_plan_participant_indicator": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "x", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1BN0A4XXXG5ZSD8K0", "has_bounding_box_height_ratio": 0.013181818181818182, "has_bounding_box_left_ratio": 0.6194117647058823, "has_bounding_box_top_ratio": 0.26590909090909093, "has_bounding_box_width_ratio": 0.02, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "income": [ { "allocated_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1ZTCHXGVK108FHVHE", "has_bounding_box_height_ratio": 0.016363636363636365, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.17227272727272727, "has_bounding_box_width_ratio": 0.10058823529411764, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "dependent_care_benefits_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "219", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MM5FMP6HGKC606ZD", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8129411764705883, "has_bounding_box_top_ratio": 0.2018181818181818, "has_bounding_box_width_ratio": 0.04352941176470588, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_1_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "678-77-709", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1W0SMD3JVDE47N116", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.1288235294117647, "has_bounding_box_top_ratio": 0.3663636363636364, "has_bounding_box_width_ratio": 0.11411764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "employer_state_2_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "940-46-434", "with_data_extraction_metadata": { "@id": "01FBHPXCJ12M1K4ASVZBF68XHJ", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.12823529411764706, "has_bounding_box_top_ratio": 0.39181818181818184, "has_bounding_box_width_ratio": 0.11588235294117646, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "federal_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "40043.57", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FE1EQ8X9Q3N12W4F", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.77, "has_bounding_box_top_ratio": 0.09181818181818181, "has_bounding_box_width_ratio": 0.09058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9966", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P0KJ87SMG4T98B75", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8182352941176471, "has_bounding_box_top_ratio": 0.23318181818181818, "has_bounding_box_width_ratio": 0.05058823529411765, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12a_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FF708969HFCH40NT", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7847058823529411, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.021176470588235293, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12b_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "284", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1VT54M1WB8JCK60N2", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.2636363636363636, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "307", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1122YD0V4AVKZENYF", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.295, "has_bounding_box_width_ratio": 0.03705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12c_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "P", "with_data_extraction_metadata": { "@id": "01FBHPXCJ17CSM3TM4RXJ81SBQ", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.29545454545454547, "has_bounding_box_width_ratio": 0.02823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "242", "with_data_extraction_metadata": { "@id": "01FBHPXCJ14CVKQT2JE5BGCGCG", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.8188235294117647, "has_bounding_box_top_ratio": 0.3277272727272727, "has_bounding_box_width_ratio": 0.03764705882352941, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "irs_w2_box_12d_code": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "H", "with_data_extraction_metadata": { "@id": "01FBHPXCJ15PYMH0E9SDPSFAFS", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.7817647058823529, "has_bounding_box_top_ratio": 0.3286363636363636, "has_bounding_box_width_ratio": 0.02588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "152406.79", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1FRRA33BQ5Y1WPBZB", "has_bounding_box_height_ratio": 0.015, "has_bounding_box_left_ratio": 0.5735294117647058, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.09823529411764706, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "medicare_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "4419.8", "with_data_extraction_metadata": { "@id": "01FBHPXCJ165FBQES8CNY03WXV", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.8176470588235294, "has_bounding_box_top_ratio": 0.14772727272727273, "has_bounding_box_width_ratio": 0.07176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "nonqualified_retirement_plan_distribution_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "233", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1SH6XFDXZEW448H6A", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.23272727272727273, "has_bounding_box_width_ratio": 0.04176470588235294, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_income_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1MX04VCHK51H8RMF2", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.10705882352941176, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tax_withheld_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "9459.67", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1X5EE4TPRBM2CH0M3", "has_bounding_box_height_ratio": 0.017272727272727273, "has_bounding_box_left_ratio": 0.768235294117647, "has_bounding_box_top_ratio": 0.11818181818181818, "has_bounding_box_width_ratio": 0.07882352941176471, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_tips_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "123655.86", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1P9044AEFH8EF6QT7", "has_bounding_box_height_ratio": 0.014090909090909091, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.175, "has_bounding_box_width_ratio": 0.10470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "wages_salaries_tips_and_other_compensation_amount": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "126204.09", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1Y43WKTXBJJWHE106", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.571764705882353, "has_bounding_box_top_ratio": 0.08954545454545454, "has_bounding_box_width_ratio": 0.10588235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "mortgage_products": [ { "@id": "01FBHN4YR4H8E04K9RJZ3F8CRH", "@type": "groundtruth_labeling", "has_service_request_date": { "has_value": "2021-07-26" }, "has_service_response_date": { "has_value": "2021-07-26" }, "product_used_for": "01FBHN4YR48XC75HJF5Z9VRBTV" } ], "organizations": [ { "organization_identifier": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "39-3114215", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0H5YE99DKRNXTVR5W", "has_bounding_box_height_ratio": 0.015454545454545455, "has_bounding_box_left_ratio": 0.08058823529411764, "has_bounding_box_top_ratio": 0.09136363636363637, "has_bounding_box_width_ratio": 0.12, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "organization_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Carlson Group Group", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1NYMK9JRAAMF3GXRH", "has_bounding_box_height_ratio": 0.01681818181818182, "has_bounding_box_left_ratio": 0.07470588235294118, "has_bounding_box_top_ratio": 0.11954545454545455, "has_bounding_box_width_ratio": 0.2211764705882353, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ], "people": [ { "full_name": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "Taylor Cox", "with_data_extraction_metadata": { "@id": "01FBHPXCJ1011XSCSZ76ZE1CX0", "has_bounding_box_height_ratio": 0.02181818181818182, "has_bounding_box_left_ratio": 0.07588235294117647, "has_bounding_box_top_ratio": 0.2381818181818182, "has_bounding_box_width_ratio": 0.13470588235294118, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } }, "social_security_number": { "data_sourced_from": "01FBHN4YR4H8E04K9RJZ3F8CRH", "has_value": "999-00-0000", "with_data_extraction_metadata": { "@id": "01FBHPXCJ0VCNHZCXPKJ3WY9C8", "has_bounding_box_height_ratio": 0.015909090909090907, "has_bounding_box_left_ratio": 0.26588235294117646, "has_bounding_box_top_ratio": 0.06363636363636363, "has_bounding_box_width_ratio": 0.1288235294117647, "with_page_extraction_metadata": "01FBHPXCJ03V0AAHVGW6G1YE08" } } } ] } ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 1 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data object | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `GET` `/products/train_data_extraction/custom_endpoint/models` #### Retrieve List Of Supported Document Types `RetrieveDoctypes` Successfully returned list of supported document types and partners. Retrieves the list of currently supported documents and partners per document. Best partner for each document type is provided. Customers can use it when invoking product flow as tag in order to extract with this particular partner. ##### Response application/json Copy Successfully returned list of supported document types and partners. ``` { "collection_id": "01G0YH8WJYNHN72ANQ8DYG976M", "data": { "documents": [ { "document_type": "appraisal_report", "partners": [ "google_clould_nl" ], "default_partner": "google_clould_nl" }, { "document_type": "closing_disclosure", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "mortgage_insurance_cancellation_disclosure", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "google_clould_nl" }, { "document_type": "mortgage_insurance_certificate", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "note", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "property_insurance_policy", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "security_instrument", "partners": [ "google_clould_nl", "comprehend" ], "default_partner": "comprehend" }, { "document_type": "standard_flood_hazard_determination", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "title_commitment", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "underwriting_transmittal", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" }, { "document_type": "uniform_residential_loan_application", "partners": [ "google_clould_nl", "comprehend", "mindee" ], "default_partner": "comprehend" } ] }, "transaction_id": "01G0YH8WAREZS5WFZP3CPCT2W9", "metadata": { "created_at": "2022-04-18T10:29:51.838440-04:00", "validation": false } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | The environment API key. | ##### Response `200``application/json` 4 fields Successfully returned list of supported document types and partners. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection IDExample `01G0YH8WJYNHN72ANQ8DYG976M` | | `data` | `object` | Object with info about partners available for each document type. | | `documents` | `object[]` | Array of documents | | `document_type` | `string` | Document type name. Apply this to product tags when invoking product flow to extract particular document.Example `appraisal_report` | | `partners` | `string[]` | Array of partners available for particular document. | | `default_partner` | `string` | Best partner for this document type according to our recommendations.Example `google_clould_nl` | | `transaction_id` | `string` | Transaction IDExample `01G0YH8WAREZS5WFZP3CPCT2W9` | | `metadata` | `object` | Collection metadata | | `created_at` | `string` | Created dateExample `2022-04-18T10:29:51.838440-04:00` | | `validation` | `boolean` | Is validation enabledExample `false` | ### Operations `POST` `/credentials` #### Setup pipeline credentials ##### Response 400 application/json400 text/html403 application/json Copy Bad Request. ``` { "code": "Bad Request", "message": "Bad request syntax or unsupported method" } ``` text/html Copy Bad Request. ``` Bad request syntax or unsupported method ``` application/json Copy Forbidden ``` { "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post", "message": "This key is not valid for this service." } ``` ##### Response `400``application/json` 1 fields Bad Request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad Request error. | | `code`required | `one of` | Bad Request | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `url` | `string` | The URL. | | `message` | `string` | Error message. | ##### Other responses `202` `POST` `/hello-world` #### Hello World Dummy hello world endpoint ##### Other responses `200` ## Canonical model - `document` ## Errors `400``401``403``404``405``408``409``422``500``501``502``503` ## More in Data - Previous product: Language - Next product: Persistence --- # Persistence # Persistence The graph store every product writes into: containers of linked-data items, immutable state, first-class blobs, and the transaction primitive. Persistence holds the canonical record. Items are stored in containers keyed by class, each carrying a sortable identifier, and read back as linked data. Search runs over a separate index rather than over the graph itself, so a text query does not become a traversal. Binary objects are first class. A response collection carries blob identifiers that resolve through a signed-URL call, which keeps documents out of payloads without making the caller manage storage. ## How it works State is immutable. Every change to an entity creates a new record with a new database-generated identifier, while a stable global identifier groups every state of the same real-world thing. Reading history is a query over that group rather than a separate audit table, and a correction never destroys what it corrected. The transaction and collection primitives every product's API reuses are defined here. That is why a per-vendor attempt is inspectable on any product: the attempt was written as its own collection under the transaction, not folded into a final result. ## Operations ### Blobs `POST` `/blobs` #### Create Blob `create_blob` Create Blob creates a blob instance with specified extension and returns presigned url for content upload. Note: This will NOT upload your file to the blob instance. To upload a document, you will need to issue a PUT request to the presigned URL returned by the response body. See example, code snippet below: ``` import requests # Create Blob endpoint returns blob_id and upload presigned url # For example, the presigned_url might look like this: presigned_url = "" # Set the path to the file you want to upload filepath = "document.pdf" # Set the headers appropriately headers = { 'Content-Type': 'application/pdf' } # Read the file data and make the PUT request with open(filepath, 'rb') as file: payload = file.read response = requests.put(url=upload_presigned_url, headers=headers, data=payload) ``` ##### Request Pdf file uploadJpg file upload application/json Copy ``` { "extension": ".pdf", "presign_url_ttl": 30 } ``` application/json Copy ``` { "extension": ".jpg", "blob_name": "image.jpg" } ``` ##### Response 201400 application/json Copy Blob has been created ``` { "blob_id": "8c561841-6671-412e-a356-523460ba0d8d", "extension": ".pdf", "presigned_urls": { "upload": { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" } } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `extension`required | `string` | Extension of file, that blob is persistingExample `.pdf` | | `presign_url_ttl` | `integer` | TTL of presigned url in seconds, default is 3600 | | `blob_name` | `string` | Name for blob | ##### Response `201``application/json` 6 fields Blob has been created | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string (ulid)` | Blob idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `extension` | `string` | Extension of file, that blob is persistingExample `.pdf` | | `presigned_urls` | `object` | Presigned urls for uploading or downloading file | | `upload` | `object` | Presigned url | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | | `page_count` | `integer` | Number of pages present, if the file persisted is a PDF. | | `content_length` | `integer` | Size of the file being persisted. | | `blob_name` | `string` | Blob name | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PUT` `/blobs/{blob_id}/presigned-urls/{action}` #### Create Blob Presigned URL `generate_presigned_url` Generate new presigned url ##### Request application/json Copy ``` { "presign_url_ttl": 3600 } ``` ##### Response 200400404 application/json Copy New presigned url ``` { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (ulid)` path | `01EZQ32PJQGKRA6HR8D72Q9FFF` | Blob id | | `action` required | `string` path | `upload` | Action, one of one of ['upload', 'donwload'] | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `presign_url_ttl` | `integer` | TTL of presigned url in seconds, default is 3600 | ##### Response `200``application/json` 1 fields New presigned url | Field | Type | Description | | --- | --- | --- | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/blobs/{blob_id}` #### Retrieve Blob `get_blob` Retrieve Blob instance: extension, last created presigned urls, page count and content length ##### Response 200400404 application/json Copy Blob instance with last created presigned urls ``` { "blob_id": "8c561841-6671-412e-a356-523460ba0d8d", "extension": ".pdf", "presigned_urls": { "download": { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" }, "upload": { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" } }, "page_count": 3, "content_length": 7478 } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (ulid)` path | `01FJCA39TSCHS6Q8K69FEEMQZQ` | Blob id | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 4 fields Blob instance with last created presigned urls | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string (ulid)` | Blob idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `extension` | `string` | Extension of file, that blob is persistingExample `.pdf` | | `presigned_urls` | `object` | Presigned urls for uploading or downloading file | | `download` | `object` | Presigned url | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | | `upload` | `object` | Presigned url | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | | `blob_name` | `string` | Blob name | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `GET` `/blobs/{blob_id}/presigned-urls` #### Retrieve Blob Presigned URLs `get_preassigned_urls` ##### Response 200400404 application/json Copy Presigned urls ``` { "download": { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" }, "upload": { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (ulid)` path | `01FJCA39TSCHS6Q8K69FEEMQZQ` | Blob id | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 2 fields Presigned urls | Field | Type | Description | | --- | --- | --- | | `download` | `object` | Presigned url | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | | `upload` | `object` | Presigned url | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/blobs/{blob_id}/presigned-urls/{action}` #### Retrieve Presigned URL for Action `get_presigned_url` Get presigned url ##### Response 200400404 application/json Copy Presigned url ``` { "url": "https://api-data-manager-blobs-bucket.s3.amazonaws.com/8c561841-6671-412e-a356-523460ba0d8d" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (ulid)` path | `01EZQ32PJQGKRA6HR8D72Q9FFF` | Blob id | | `action` required | `string` path | `upload` | Action for url | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 1 fields Presigned url | Field | Type | Description | | --- | --- | --- | | `url` | `string (uri)` | Presigned urlExample `https://api-data-manager-blobs-bucket.s3.amazonaws.com/00c8c9e5-dfdd-44c5-a57e-8de7a2672e2e` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Graph `POST` `/graph/merge` #### Execute Merge `execute_merge` Execute merge of collections stored in the Persistence Graph. This API is only available when the Persistence Graph component is installed in the user's environment. The request body must be in JSON format and contain the following properties: `transaction_id`: ID of transaction to merge. Also request body may contain one optional property: `collection_ids`: A list of IDs of collections which should be merged. Show the rest The response is returned in JSON format and contains the results of the merge. #### Example of merging process In the transaction we have two collection that we want to merge. Entities will be merged if it matches by type, properties and values. `first collection`: ``` { "addresses": [ { "@id": "01FD9XEX1KVQ182TXBN67YVJ04", "@type": "residential_address", "has_address_line_1_text": { "has_value": "535 30 RD" }, "has_city_name": { "has_value": "GRAND JUNCTION" }, "has_postal_code": { "has_value": "81504" }, "has_state_code": { "has_value": "CO" } }, { "@id": "01FD9XEX1KN579K22XEC9A6Q6C", "@type": "residential_address", "has_address_line_1_text": { "has_value": "312 OURAY AV" }, "has_city_name": { "has_value": "GRAND JUNCTION" }, "has_postal_code": { "has_value": "81501" }, "has_state_code": { "has_value": "CO" } } ], "people": [ { "@type": "borrower", "@id": "01GQHRJVS13E8S9T0RMZPXF02V", "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" }, "lives_at": [ "01FD9XEX132KHJ64GEE6PYWE19", "01FD9XEX13TNAVJ0NJ23MYZMH2" ], "with_credit_information": [ "01FD9XEWZYM5ZTNCGRRPND285X", "01GTM5V2BEWMFN1Q6E3675YVM1" ] } ], "residences": [ { "@id": "01FD9XEX132KHJ64GEE6PYWE19", "@type": "residence", "has_borrower_residency_type": { "has_value": "current" }, "with_address": [ "01FD9XEX1KVQ182TXBN67YVJ04" ] }, { "@id": "01FD9XEX13TNAVJ0NJ23MYZMH2", "@type": "residence", "has_borrower_residency_type": { "has_value": "prior" }, "with_address": [ "01FD9XEX1KN579K22XEC9A6Q6C" ] } ], "credit_information": [ { "@id": "01FD9XEWZYM5ZTNCGRRPND285X", "@type": "credit_information", "has_credit_frozen_status_equifax_indicator": { "has_value": "false" }, "has_credit_frozen_status_experian_indicator": { "has_value": "false" }, "has_credit_frozen_status_trans_union_indicator": { "has_value": "false" }, "has_credit_rating_code_type": { "has_value": "equifax" }, "has_credit_report_first_issued_date": { "has_value": "2021-08-17" }, "has_credit_report_identifier": { "has_value": "2-a7e4f473-18f0-4fc7-9" }, "has_credit_report_merge_type": { "has_value": "list_and_stack" }, "has_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_repository_included_trans_union_indicator": { "has_value": "true" }, "has_credit_request_data_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_trans_union_indicator": { "has_value": "false" }, "has_data_version_credmo_identifier": { "has_value": "1.3" }, "has_data_version_equifax_identifier": { "has_value": "4" } }, { "@id": "01GTM5V2BEWMFN1Q6E3675YVM1", "@type": "credit_information", "has_credit_frozen_status_equifax_indicator": { "has_value": "false" }, "has_credit_frozen_status_experian_indicator": { "has_value": "false" }, "has_credit_frozen_status_trans_union_indicator": { "has_value": "false" }, "has_credit_rating_code_type": { "has_value": "equifax" }, "has_credit_report_first_issued_date": { "has_value": "2021-08-17" }, "has_credit_report_identifier": { "has_value": "2-a7e4f473-18f0-4fc7-9" }, "has_credit_report_merge_type": { "has_value": "list_and_stack" }, "has_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_repository_included_trans_union_indicator": { "has_value": "true" }, "has_credit_request_data_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_trans_union_indicator": { "has_value": "false" }, "has_data_version_credmo_identifier": { "has_value": "1.3" }, "has_data_version_equifax_identifier": { "has_value": "4" } } ] } ``` `second collection`: ``` { "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", "01GTM5XEKKJ23KC28QEA8TG971" ], "employed_as": [ "01FDF0DFYAHBRJGFA5RS26HVP1" ] } ], "contact_information": [ { "@type": "contact_information", "@id": "01FDF09BNQCT03DCAX7M5KM52T", "has_phone_number": { "has_value": "+1234567890" } }, { "@type": "contact_information", "@id": "01GTM5XEKKJ23KC28QEA8TG971", "has_phone_number": { "has_value": "+1234567890" } } ], "employment": [ { "@id": "01FDF0DFYAHBRJGFA5RS26HVP1", "@type": "employment", "has_employment_position_description": { "has_value": "Engineer" } } ] } ``` `merged collection`: ``` { "addresses": [ { "@id": "01FD9XEX1KVQ182TXBN67YVJ04", "@type": "residential_address", "has_address_line_1_text": { "has_value": "535 30 RD" }, "has_city_name": { "has_value": "GRAND JUNCTION" }, "has_postal_code": { "has_value": "81504" }, "has_state_code": { "has_value": "CO" } }, { "@id": "01FD9XEX1KN579K22XEC9A6Q6C", "@type": "residential_address", "has_address_line_1_text": { "has_value": "312 OURAY AV" }, "has_city_name": { "has_value": "GRAND JUNCTION" }, "has_postal_code": { "has_value": "81501" }, "has_state_code": { "has_value": "CO" } } ], "contact_information": [ { "@id": "01FDF09BNQCT03DCAX7M5KM52T", "@type": "contact_information", "has_phone_number": { "has_value": "+1234567890" } } ], "credit_information": [ { "@id": "01FD9XEWZYM5ZTNCGRRPND285X", "@type": "credit_information", "has_credit_frozen_status_equifax_indicator": { "has_value": "false" }, "has_credit_frozen_status_experian_indicator": { "has_value": "false" }, "has_credit_frozen_status_trans_union_indicator": { "has_value": "false" }, "has_credit_rating_code_type": { "has_value": "equifax" }, "has_credit_report_first_issued_date": { "has_value": "2021-08-17" }, "has_credit_report_identifier": { "has_value": "2-a7e4f473-18f0-4fc7-9" }, "has_credit_report_merge_type": { "has_value": "list_and_stack" }, "has_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_repository_included_trans_union_indicator": { "has_value": "true" }, "has_credit_request_data_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_trans_union_indicator": { "has_value": "false" }, "has_data_version_credmo_identifier": { "has_value": "1.3" }, "has_data_version_equifax_identifier": { "has_value": "4" } } ], "employment": [ { "@id": "01FDF0DFYAHBRJGFA5RS26HVP1", "@type": "employment", "has_employment_position_description": { "has_value": "Engineer" } } ], "people": [ { "@id": "01GQHRJVS13E8S9T0RMZPXF02V", "@type": "borrower", "contact_at": [ "01FDF09BNQCT03DCAX7M5KM52T" ], "employed_as": [ "01FDF0DFYAHBRJGFA5RS26HVP1" ], "has_birth_date": { "has_value": "01/01/1985" }, "has_first_name": { "has_value": "John" }, "has_last_name": { "has_value": "Deere" }, "has_taxpayer_identifier_value": { "has_value": "999-00-0000" }, "lives_at": [ "01FD9XEX13TNAVJ0NJ23MYZMH2", "01FD9XEX132KHJ64GEE6PYWE19" ], "with_credit_information": [ "01FD9XEWZYM5ZTNCGRRPND285X" ] } ], "residences": [ { "@id": "01FD9XEX13TNAVJ0NJ23MYZMH2", "@type": "residence", "has_borrower_residency_type": { "has_value": "prior" }, "with_address": [ "01FD9XEX1KN579K22XEC9A6Q6C" ] }, { "@id": "01FD9XEX132KHJ64GEE6PYWE19", "@type": "residence", "has_borrower_residency_type": { "has_value": "current" }, "with_address": [ "01FD9XEX1KVQ182TXBN67YVJ04" ] } ] } ``` ##### Request Merge selected collections in transactionMerge all collections in transaction application/json Copy ``` { "transaction_id": "01GSWRGPWD2C5SYPAN8TS4ZADJ", "collection_ids": [ "01GSWRQXKK7AHPH4XG4DRHYXSZ", "01GSWS0PY75NFRHBFA4ERTFMD8" ] } ``` application/json Copy ``` { "transaction_id": "01GSWRGPWD2C5SYPAN8TS4ZADJ" } ``` ##### Response 200400 application/json Copy Ok. ``` { "merge_result": { "contact_information": [ { "@id": "01FDF09BNQCT03DCAX7M5KM52T", "@type": "contact_information", "has_phone_number": { "has_value": "+1234567890" } } ], "employment": [ { "@id": "01FDF0DFYAHBRJGFA5RS26HVP1", "@type": "employment", "has_employment_position_description": { "has_value": "Engineer" } } ], "people": [ { "@id": "01FDF04MYHEZ98AD7T8ZGY5CMB", "@type": "borrower", "contact_at": [ "01FDF09BNQCT03DCAX7M5KM52T" ], "employed_as": [ "01FDF0DFYAHBRJGFA5RS26HVP1" ], "has_birth_date": { "has_value": "01/01/1985" }, "has_first_name": { "has_value": "John" }, "has_last_name": { "has_value": "Deere" }, "has_taxpayer_identifier_value": { "has_value": "999-00-0000" }, "lives_at": [ "01GS59J4PHKYRH3D9TPAV3FK40", "01FD9XEX13TNAVJ0NJ23MYZM10" ] } ] } } ``` application/json Copy Request data invalid ``` { "message": "Request body is not valid JSON." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | ID of transaction to merge.Example `01GSWRGPWD2C5SYPAN8TS4ZADJ` | | `collection_ids` | `string[]` | Array of collection IDs to merge. | ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `merge_result`required | `object` | Merged collections | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `POST` `/graph/query` #### Execute Query `execute_query` Execute query against data stored in the Persistence Graph. This API endpoint /graph/query allows users to execute a query against the data stored in the Persistence Graph. This API is only available when the Persistence Graph component is installed in the user's environment. The HTTP method used to execute a query is POST. The request body must be in JSON format and contain the following properties: `query`: A JSONPATH or JMESPATH query object containing the path of the data to query, the operation to perform, and the value to query against. The query object has the following properties: `path`: An object containing the query path and format. The format property must be set to JSONPATH or JMESPATH. `operation`: The operation to perform, such as BETWEEN, CONTAINS, EQ, GT, GTE, LT, LTE, NE, or STARTSWITH. `value`: The value to query against. `echo`: Boolean flag, if true, the raw SPARQL Query will be present in the response. `include_total_count`: An optional boolean value that determines whether the response should include a field called "total_count" with the total number of items returned by the query. The default value is false. `sort`: Optional flag. If ASC, response will be sorted from small to greater. If DESC, response will be sorted from greater to lesser. By default, ASC sort is applied. `transaction_ids`: Optional field. If provided, response will include only collections from the transactions_ids provided. If omitted, will return data in all transactions. `page` parameter is specified with the `next_token` parameter. The `page` parameter is a number with a value more than 0. `latest_collections_only` Boolean flag. If true, only return the latest collection from each transaction. Default is false. `use_sug` Boolean flag. If true, collections are searched in SUG. Default is false. 'latest_collection_only_tr`: Boolean flag, new version of `latest_collections_only`flag. Uses different method to make queries to SPARQL, optimized for large amount of collections in transaction, but works only with collections created after 18.01.2024. Has priority over`latest_collection_only` The request body examples show how to use the API to perform different types of queries. For example, finding the first person in the people array with a has_first_name property equal to Vlad, or finding all people with a has_credit_score property between 400 and 500. The response is returned in JSON format and contains the results of the query. If query_result array of the response body is empty, it means no new data is available for this query. Show the rest Known limitations 1. No slices are supported. 1. No multiselect for JMESPATH (for example `'people[?age > `20`].[name, age]'`) is not supported. 1. Pipe Expressions for JMESPATH not available. 1. No multiple logical conditions for JMESPATH. 1. No functions for JMESPATH. If you need this feature, please open Customer Request to us. ##### Request First person in people array with has_first_name equals VladFirst person in people array with has_first_name equals Vlad Only latest collectionsFirst person in people array with has_first_name equals Vlad Second PageFirst person in people array with has_first_name equals Vlad inside transactions labeled as prodFirst person in people array with has_first_name equals Vlad jmespathAll people with has_credit_score between 400 and 500All people with first name Vlad and last name KNested filters, find peoples with name Vlad that lives in New York city NY statestartswithcontainsnegtgteltlteandand_orCombine JSONPATH and JMESPATHPaginated requestlimittotal_count application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" }, "latest_collections_only": true } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" }, "page": 1, "next_token": "7b22637265617465645f6174223a2022323032332d30322d32325431383a31333a32352e3834373236372b30323a3030222c20226f6666736574223a20313030307d" } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" }, "transaction_label": "prod" } ``` application/json Copy ``` { "query": { "path": { "path": "people[0].has_first_name.has_value", "format": "jmespath" }, "operation": "eq", "value": "Vlad" } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "between", "value": [ 400, 500 ] } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[?(@.has_first_name.has_value = 'Vlad')].has_last_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "K" } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[?(@.has_first_name.has_value = 'Vlad')].with_addresses[?(@.has_city_name.has_value = 'New York')].has_state_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "NY" } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].with_addresses[*].has_state_name.has_value", "format": "jsonpath" }, "operation": "startswith", "value": "N" } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_last_name.has_value", "format": "jsonpath" }, "operation": "contains", "value": "mik" } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "ne", "value": 200 } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "gt", "value": 200 } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "gte", "value": 200 } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "lt", "value": 200 } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "lte", "value": 200 } } ``` application/json Copy ``` { "query": { "and": [ { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "eq", "value": 200 }, { "and": [ { "path": { "path": "$.people[*].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Bob" }, { "path": { "path": "$.people[*].has_last_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Odenkirk" } ] } ] } } ``` application/json Copy ``` { "query": { "or": [ { "path": { "path": "$.people[*].has_credit_score.has_value", "format": "jsonpath" }, "operation": "eq", "value": 200 }, { "and": [ { "path": { "path": "$.people[*].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Bob" }, { "path": { "path": "$.people[*].has_last_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Odenkirk" } ] } ] } } ``` application/json Copy ``` { "query": { "and": [ { "or": [ { "path": { "path": "people[*].has_credit_score.has_value", "format": "jmespath" }, "operation": "eq", "value": 200 }, { "path": { "path": "$.people[*].has_last_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "K" } ] }, { "and": [ { "path": { "path": "$.people[*].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Bob" }, { "path": { "path": "$.people[*].has_last_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Odenkirk" } ] } ] } } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" }, "next_token": "7b22637265617465645f6174223a2022323032332d30322d32325431383a31333a32352e3834373236372b30323a3030222c20226f6666736574223a20313030307d" } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" }, "limit": 150 } ``` application/json Copy ``` { "query": { "path": { "path": "$.people[0].has_first_name.has_value", "format": "jsonpath" }, "operation": "eq", "value": "Vlad" }, "include_total_count": true } ``` ##### Response 200400 application/json Copy Ok. ``` { "query_result": [ { "transaction_id": "01GSD62EEBT4YD1Y0W6GFVA4EB", "collection_id": "01GSD68Z48JRJK8MM4YYRCTH3D" }, { "transaction_id": "01GSD62EEBT4YD1Y0W6GFVA4EB", "collection_id": "01GSD6AC2XH7QW4N8RE67QB0Z9" } ], "next_token": "7b22637265617465645f6174223a2022323032332d30322d32325431383a31333a32352e3834373236372b30323a3030222c20226f6666736574223a20313030307d", "total_count": 42 } ``` application/json Copy Request data invalid ``` { "message": "Invalid path. Reason: Invalid JSONPATH." } ``` ##### Request body`application/json` 11 fields | Field | Type | Description | | --- | --- | --- | | `query`required | `object` | JSONPath query | | `path`required | `object` | The location of data for query | | `path`required | `string` | The query path. Must be valid JSONPATH or JMESPATH. | | `format`required | `string` | The query format in use`JMESPATH``JSONPATH` | | `operation`required | `string` | Operation`BETWEEN``CONTAINS``EQ``GT``GTE``LT``LTE``NE``STARTSWITH` | | `value`required | `string` | What value to query against. | | `next_token` | `string` | Next token from the response body.Example `7b22637265617465645f6174223a2022323032332d30322d32325431383a31333a32352e3834373236372b30323a3030222c20226f6666736574223a20313030307d` | | `limit` | `integer` | Limits how many results should be in the response.Example `100` | | `transaction_label` | `string` | If provided, include only the transactions with the provided 'transaction_label'.Example `my_label` | | `transaction_ids` | `string[]` | If provided, include only the transactions with the provided 'transaction_ids'. | | `echo` | `boolean` | If provided, response will include `raw_query` key.Example `true` | | `sort` | `string` | If provided, response will be sorted asc or desc.`ASC``DESC`Example `DESC` | | `include_total_count` | `boolean` | An optional boolean value that determines whether the response should include a field called "total_count" with the total number of items returned by the query. The default value is false. | | `page` | `integer` | Optional parameter to specify the page of data to retrieve. Must be used with the "next_token" parameter. | | `latest_collections_only` | `boolean` | If true, only return the latest collection from each transaction.Example `true` | | `use_sug` | `boolean` | If true, collections are searched in SUG.Example `true` | ##### Response `200``application/json` 3 fields Ok. | Field | Type | Description | | --- | --- | --- | | `query_result`required | `object[]` | Array of transaction and collection IDs pair | | `transaction_id`required | `string` | Transaction IDExample `01GSD62EEBT4YD1Y0W6GFVA4EB` | | `collection_id`required | `string` | Collection IDExample `01GSD6AC2XH7QW4N8RE67QB0Z9` | | `next_token`required | `string` | Next token of the query. Pass it to request body to get next 1000 results of the query. If null, no next results available.Example `7b22637265617465645f6174223a2022323032332d30322d32325431383a31333a32352e3834373236372b30323a3030222c20226f6666736574223a20313030307d` | | `raw_query` | `string` | The raw SPARQL Query that was executed. Useful for debug. Only available if request body parameter echo is true.Example `PREFIX sci: PREFIX sc: PREFIX rdf: PREFIX xsd: SELECT DISTINCT ?transaction_id ?collection_id { {?data sc:communications/rdf:rest*/rdf:first ?x_1 . ?x_1 rdf:type ?x_2 . ?x_1 sc:has_communication_source_username/sc:has_value ?x_3 FILTER (?x_2 = sc:email) . FILTER (?x_3 = "nivanjeet.singh@staircase.co")}{?data sc:communications/rdf:rest*/rdf:first ?x_4 . ?x_4 rdf:type ?x_5 . ?x_4 sc:with_sender/rdf:first/sc:contact_at/rdf:first/sc:has_email_address/sc:has_value ?x_6 FILTER (?x_5 = sc:email) . FILTER (?x_6 = "blah@blah.com")} GRAPH ?transaction_id { ?collection_id sci:data ?data } ?collection_id sci:metadata/sci:created_at ?created_at . FILTER (xsd:dateTime(?created_at) <= "2023-03-06T16:24:11.362539+00:00"^^xsd:dateTime) } ORDER BY ?transaction_id ?collection_id LIMIT 10 OFFSET 0` | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/graph/sparql` #### Query Graph `query_graph` Query Graph as SPARQL HTTP JSON query endpoint so that customer can use it with any SPARQL wrapper, f.e.: Endpoint is fully compatible with SPARQL 1.1 Protocol. Supports SELECT, ASK, CONSTRUCT, and DESCRIBE queries. The default return format is JSON-LD, customizable with an `Accept` header. Persistence Graph service is installed as a separate component from the marketplace and requires an installed Persistence product. Persistence Graph costs 300 USD per month. Show the rest To include the collection in the graph, you should set the serialise_to_graph parameter in metadata to true. The collection is stored as a named graph with transaction_id as graph URI in the format: ``. Example of Collection in TriG format: ``` @prefix sci: . @prefix sc: . @prefix xsd: . sci:01GPG88H8ZYDDTXE9M6DYCF7WN { sci:01GPG88H8ZYDDTXE9M6DYCF7WN sci:transaction_label "some_label" sci:01GPG89C7FRM7F5STXMW59TBPQ sci:data [ sc:addresses sci:01GPG9FP9CM7SN1AF1NP3Z0B5K, sci:01GPGBQNZ5YHEWTKN43B8CPWHW ; sc:people sci:01GPG8ZHGNWH85DYPZQ7CEVTRZ ] ; sci:metadata [ sci:active true ; sci:created_at "2023-01-11T13:56:48.485729" ; sci:last_updated_at "2023-01-11T13:57:48.485729" ] . sci:01GPG8ZHGNWH85DYPZQ7CEVTRZ a sc:borrower ; sc:has_first_name [ sc:has_value "Bob" ] ; sc:with_addresses sci:01GPG9FP9CM7SN1AF1NP3Z0B5K, sci:01GPGBQNZ5YHEWTKN43B8CPWHW . sci:01GPG9FP9CM7SN1AF1NP3Z0B5K a sc:mailing_address ; sc:has_city_name [ sc:has_value "New York" ] . sci:01GPGBQNZ5YHEWTKN43B8CPWHW a sc:mailing_address ; sc:has_city_name [ sc:has_value "Chicago" ] . } ``` ##### Response application/json Copy Request data failed validation ``` { "detailedMessage": "Malformed query", "code": "MalformedQueryException" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `query` required | `string` query | `SELECT%20%2A%20WHERE%20%7B%20%3Fs%20%3Fp%20%3Fo%20%7D%20LIMIT%2010` | Your SPARQL query in URL-encoded format | | `Accept` | `string` header | `application/sparql-results+json` | Accept header is used to specify the format of the response. If not specified, the default is application/sparql-results+json. Supported formats: application/nquads, application/n-triples, application/rdf+xml, application/ld+json, application/trig, application/trix, text/turtle, text/x-nquads, text/n3, application/sparql-results+json, application/x-binary-rdf, */* | | `explain` | `string` query | `static` | Explain parameter could be passed to retrieve information about how your SPARQL query will be executed in the neptune. Currently supports explain only in SPARQL SELECT queries. | ##### Response `200``application/sparql-results+json` 3 fields queried | Field | Type | Description | | --- | --- | --- | | `head` | `object` | The head of the result set. | | `vars` | `string[]` | The variables in the result set. | | `results` | `object` | The results of the query. | | `bindings` | `object[]` | The bindings of the results. | | `boolean` | `boolean` | The boolean result of the query. Used in ASK query | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Exception Code in Neptune format | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `406``422``500` ### Typesense `GET` `/health` #### Health check `health_check` ##### Response application/json Copy OK response ``` { "ok": true } ``` ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `ok` | `boolean` | Health check status. | ### Indexes `POST` `/indexes` #### Create Index `create_index` Creates an index. Persistence indexes support 2 type of JSON query languages: JSONPath and JMESPath. Both of them work with graph v2 collections like in Query on Collection Level endpoint. After index is created all collections will be indexed against it. You can list indexed items using List index items endpoint. ##### Request application/json Copy ``` { "name": "borrower_ssn", "path": { "path": "$.people[?(@['@type'] == 'borrower')].has_taxpayer_identifier_value.has_value", "format": "jsonpath" } } ``` ##### Response application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Name of the Index | | `many` | `boolean` | Flag that defines the separating of values in the query to different items. If `many` == true, and query by index found more than 2 values, they will be put to different items. Otherwise, to the same item. | | `path`required | `object` | The location of data to be indexed | | `path`required | `string` | The query path | | `format`required | `string` | The query format in use`jmespath``jsonpath` | | `transaction_labels` | `string[]` | The list of transaction labels, which collections need to be captured in the index | ##### Response `201``application/json` 3 fields created | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Name of the Index | | `many` | `boolean` | Flag that defines the separating of values in the query to different items. If `many` == true, and query by index found more than 2 values, they will be put to different items. Otherwise, to the same item. | | `path`required | `object` | The location of data to be indexed | | `path`required | `string` | The query path | | `format`required | `string` | The query format in use`jmespath``jsonpath` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `GET` `/indexes` #### List Indexes `list_indexes` List indexes List indexes. You can specify additional filters using the `index_name` or `created_at` parameters, with available operators: `gt, lt, startswith`. ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `filter` | `string` query | Filter by one of the index_name or created_at fields. | ##### Response `200``application/json` 3 fields Index | Field | Type | Description | | --- | --- | --- | | `indexes` | `array` | List of indexes | | `_links` | `object` | Links to next page of results | | `next` | `string` | Link to next page of results | | `next_token` | `string` | Pagination token for next page | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `DELETE` `/indexes/{index_name}` #### Delete Index `delete_index` Delete an index ##### Response 200404 application/json Copy Index ``` { "message": "Index deleted" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `index_name` required | `string` path | `my_index` | The name of the index | ##### Response `200``application/json` 1 fields Index | Field | Type | Description | | --- | --- | --- | | `message` | `string` | MessageExample `Index deleted` | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/indexes/{index_name}` #### Retrieve Index `get_index` Retrieve an index ##### Response 200400404 application/json Copy Index ``` { "name": "borrower_ssn", "path": { "path": "$.people[@['@type'] == 'borrower'].has_taxpayer_identifier_value.has_value", "format": "jsonpath" } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `index_name` required | `string` path | `my_index` | The name of the index | ##### Response `200``application/json` 6 fields Index | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | The name of the index | | `path`required | `object` | The query location of the indexed data | | `path`required | `string` | Value of the path | | `format`required | `string` | The query format in use`jmespath``jsonpath` | | `created_at` | `string (date-time)` | Date time when index was created. | | `status` | `string` | Status of the index`AVAILABLE``REINDEXING``REINDEXING_FAILED` | | `reindexing_failure_reason` | `string` | Provided if status is "REINDEXING_FAILED". | | `_links` | `object` | Links | | `items` | `string (uri)` | Link to index items | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/indexes/{index_name}/items` #### Get items in index `list_items` List index items List index items. Index items contain transaction and collection IDs of collections with its values. Items can be filtered by value and by creation date, by providing them in query parameters. Items are sorted by creation date. Filtering by created_at: - gt: - description: Get items, that were created after specified datetime in ISO format - example: created_at+gt+2021-03-30T04:27:15.372006-04:00 - lt: - description: Get items, that were created before specified datetime in ISO format - example: created_at+lt+2021-03-30T04:27:15.372006-04:00 ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `index_name` required | `string` path | `my_index` | The name of the index | | `value` | `string` query | — | Filter by value of the indexed data | | `sort` | `string` query | — | Sorting direction. | | `filter` | `string` query | — | Filter by created_at field. | | `limit` | `integer` query | — | Limit the number of items returned. | ##### Response `200``application/json` 3 fields Indexed data | Field | Type | Description | | --- | --- | --- | | `items` | `array` | Items matching the query | | `_links` | `object` | Links to next page of results | | `next` | `string` | Link to next page of results | | `next_token` | `string` | Pagination token for next page | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/indexes/{index_name}/reindex` #### Re-index collections `reindex_collections` Re-indexes specific v2 collections on the environment that were created before the index was created. You must specify specific transactions to be re-indexed with body parameters: `transaction_ids` or `transaction_label`. Reindexing of all collections on the environment is not supported since cost of reindexing all collections is too high. ##### Request Specific list of transactionsSpecific transaction label application/json Copy ``` { "transaction_ids": [ "01EZQ32NEN5VDHE288WN4TV2D3", "01EZQ32NEN5VDHE288WN4TV2D4" ] } ``` application/json Copy ``` { "transaction_label": "my_transaction_label" } ``` ##### Response 400404409 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` application/json Copy Conflict ``` { "message": "Index name 'x' already exists" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `index_name` required | `string` path | `my_index` | The name of the index | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | List of transaction ID's which collections will be re-indexed. | | `transaction_label` | `string` | Transaction label, which collections will be re-indexed. | ##### Response `200``application/json` 1 fields created | Field | Type | Description | | --- | --- | --- | | `status` | `string` | New status of the index`REINDEXING` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/indexes/query` #### Query Indexes `query_indexes` Query on Indexes Query on multiple Indexes at the same time to find specific collections. You can query on indexes values with operations: `between, contains, eq, gt, gte, lt, lte, ne, startswith`. And then you can combine them with logical operators: `and, or, xor, diff`; such as on the example below. ##### Request Complex querySimple query application/json Copy ``` { "or": [ { "and": [ { "index_name": "foo", "operation": "eq", "value": 23 }, { "index_name": "bar", "operation": "startswith", "value": "grate" } ] }, { "index_name": "baz", "operation": "between", "value": [ 20, 35 ] } ] } ``` application/json Copy ``` { "index_name": "foo", "operation": "eq", "value": 23 } ``` ##### Response `200``application/json` 1 fields Successfully queried indexes | Field | Type | Description | | --- | --- | --- | | `results` | `object[]` | List of collections that match the query | | `transaction_id` | `string` | Transaction ID of the collection | | `collection_id` | `string` | Collection ID of the collection | ##### Other responses `422` ### Lexicon `PUT` `/lexicon` #### Import Lexicon `PutLexicon` ##### Request application/json Copy ``` { "classes": [ { "type": "person", "container_name": "people", "is_deprecated": false, "deprecated_properties": [], "properties": { "first_name": { "type": "boolean" } } }, { "type": "address", "container_name": "addresses", "is_deprecated": false, "deprecated_properties": [ "address_line_deprecated" ], "properties": { "address_type": { "type": "string", "enum": [ "Mailing", "Current" ] }, "address_line_1": { "type": "string" }, "address_line_deprecated": { "type": "string" } } }, { "type": "credit", "container_name": "credits", "is_deprecated": false, "deprecated_properties": [], "properties": { "credit_identifier": { "type": "string" } }, "relationships": { "owed_to": { "targets": [ "person" ] } } }, { "type": "finance_relation", "container_name": "relationships", "relationships": { "has_person": { "targets": [ "person" ] } } }, { "type": "contact_relation", "container_name": "relationships", "relationships": { "my_id": { "targets": [ "person" ] } } } ] } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `classes`required | `object[]` | List of classes | | `type`required | `string` | Type of class | | `container_name`required | `string` | Container name | | `is_deprecated`required | `boolean` | Is deprecated | | `deprecated_properties`required | `string[]` | Deprecated properties | | `properties`required | `object` | Properties | | `relationships` | `object` | Relationships | ##### Response `201``application/json` 1 fields Lexicon have been accepted to import | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Lexicon have been accepted to import | ##### Response `400``application/json` 1 fields Lexicon did not passed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ### Embeddings `GET` `/lexicon/embeddings/smoke` #### Smoke `smoke` Hello World Dummy hello world endpoint ##### Other responses `200` ### Notifications `DELETE` `/notifications/configurations` #### Configure channel webhook `delete_configuration` Delete Configuration Delete a notification configuration. ##### Response 400404 application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Configuration not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `configuration` required | `string` query | `https://hooks.slack.com/services/ABCZXC/B00000000/ABCZXCJWKM` | The configuration identifier to delete. | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `204` `GET` `/notifications/configurations` #### Configure channel webhook `list_configurations` List Configurations Retrieve a list of notification configurations. ##### Response 200404 application/json Copy List of configurations ``` { "configurations": [ { "slack_webhook_url": "https://hooks.slack.com/services/ABCZXC/B00000000/ABCZXCJWKM" } ] } ``` application/json Copy Requested resource not found ``` { "message": "Configuration not found" } ``` ##### Response `200``application/json` 1 fields List of configurations | Field | Type | Description | | --- | --- | --- | | `configurations` | `object[]` | List of configurations | | `slack_webhook_url` | `string` | Slack webhook URL | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/notifications/configurations` #### Configure channel webhook `create_configuration` Create configuration Create a new configuration for notifications. Use slack webhook url from to your channel, to use it for getting notifications about deprecated collections in persistence on daily basis. ##### Request application/json Copy ``` { "slack_webhook_url": "https://hooks.slack.com/services/ABCZXC/B00000000/ABCZXCJWKM" } ``` ##### Response 201400 application/json Copy Configuration created ``` { "slack_webhook_url": "https://hooks.slack.com/services/ABCZXC/B00000000/ABCZXCJWKM" } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `slack_webhook_url` | `string (uri)` | Slack webhook URL | ##### Response `201``application/json` 1 fields Configuration created | Field | Type | Description | | --- | --- | --- | | `slack_webhook_url` | `string (uri)` | Slack webhook URL | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` ### PDFs `POST` `/pdf-splitter/invocations` #### Split PDF `split_pdf` Start PDF splitting process. If `callback_url` was provided in body, this url will be called with `POST` request, with your `x-api-key` in headers. If response for this call has non `2XX` status code or doesn't respond 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.pdf_split | PDF splitting is finished successfully | | co.staircase.pdf_split_failed | PDF splitting is failed | Event structure is cloudevents, so you can use any tools that supports it or SDK ``` { "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.pdf_split", "co.staircase.persistence.pdf_split_failed" ] }, "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" }, "response_collection_id": { "type": "string", "format": "ulid", "description": "Collection id" }, "reason": { "type": "string", "description": "Failure reason" } } } } } ``` ##### Request application/json Copy ``` { "transaction_id": "01G92FSH5FYKQE6X22FECB95V2", "collection_id": "01G92FSX8A9YXPAMT6V97TH0VZ" } ``` ##### Response 202400 application/json Copy Accepted. ``` { "collection_id": "01G92FWG135BTEMQC3SSMA8Q7A" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `options` | `object` | Options | | `callback_url` | `string (url)` | Callback URL | ##### Response `202``application/json` 1 fields Accepted. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Response collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `GET` `/pdf-splitter/invocations` #### List PDF Splitting jobs `list_pdf_splitting_job` Provides the list of splitting jobs. ##### Response 200400 application/json Copy OK. ``` { "invocations": [ { "invocation_id": "01G92FWG135BTEMQC3SSMA8Q7A" }, { "invocation_id": "01G92FWG135BTEMQC3SSMA8Q7B" }, { "invocation_id": "01G92FWG135BTEMQC3SSMA8Q7C" } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Response `200``application/json` 2 fields OK. | Field | Type | Description | | --- | --- | --- | | `invocations`required | `object[]` | Invocations list. | | `invocation_id` | `string` | Invocation ID. | | `next_token` | `string` | Token to paginate | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/pdf-splitter/invocations/{invocation_id}` #### Get PDF Splitting job `get_pdf_splitting_job` Provides the splitting job information. ##### Response 200404 application/json Copy OK. ``` { "invocations": [ { "invocation_id": "01G92FWG135BTEMQC3SSMA8Q7A" }, { "invocation_id": "01G92FWG135BTEMQC3SSMA8Q7B" }, { "invocation_id": "01G92FWG135BTEMQC3SSMA8Q7C" } ] } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `invocation_id` required | `string` path | `12345` | Invocation ID | ##### Response `200``application/json` 5 fields OK. | Field | Type | Description | | --- | --- | --- | | `status`required | `string` | Job status`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` | | `input`required | `object` | Job input. | | `documents` | `object[]` | Input documents | | `blob_id` | `string` | Blob ID | | `callback_url` | `string (url)` | Callback URL | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `started_at`required | `string (date-time)` | Datetime when job was started in iso-format. | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Search `GET` `/search/indexes` #### Get Search Indexes `get_search_indexes` Get indexes This function retrieves list of indexes and their statuses. You can specify `index_name` parameter in query parameters and retrieve the status of particular index, indicating whether it is currently active and available for querying. ##### Response 200400404 application/json Copy queried ``` [ { "Options": { "IndexFieldName": "name", "IndexFieldType": "text-array" }, "Status": { "CreationDate": "2023-04-03T01:02:06.541Z", "UpdateDate": "2023-04-03T01:02:06.541Z", "UpdateVersion": 1, "State": "Active", "PendingDeletion": false } } ] ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Malformed query", "code": "MalformedQueryException" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `index_name` | `string` query | `name` | Name of the index | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Exception Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200``422``500` `POST` `/search/indexes` #### Create Search Index `create_search_index` Create index To create an index with text fields for indexing, you need to provide a request body in JSON format with the specified index_name. After creating the index, the status will initially be Processing. Only when the status changes to Active, the newly added field will be available for querying and uploading new documents. However, please note that the new field will not be indexed for previously added documents. It's also important to note that there is a quota of 200 indexing fields. ##### Request application/json Copy ``` { "index_name": "addresses/has_state_code/has_value" } ``` ##### Response 200400409 application/json Copy queried ``` { "IndexField": { "Status": { "CreationDate": "2023-04-03T01:02:06.541Z", "UpdateDate": "2023-04-03T01:02:06.541Z", "State": "Active" } } } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Malformed query", "code": "MalformedQueryException" } ``` application/json Copy Conflict ``` { "message": "Index name 'x' already exists" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `index_name`required | `string` | Name of the indexExample `name` | ##### Response `200``application/json` 1 fields queried | Field | Type | Description | | --- | --- | --- | | `IndexField` | `object` | Index field | | `Status` | `object` | Status | | `CreationDate` | `string` | Creation dateExample `2023-04-03T01:02:06.541Z` | | `UpdateDate` | `string` | Update dateExample `2023-04-03T01:02:06.541Z` | | `State` | `string` | State`Active``FailedToValidate``Processing``RequiresIndexDocuments`Example `Active` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Exception Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `POST` `/search/query` #### Query `perform_search_query` To search for a value in a field using fuzzy search, follow these guidelines: - If the value you provide contains a single word, fuzzy search will be performed based on the Levenshtein Distance with this word. This means that the search will return results that contains the word you provided, but with minor spelling variations due to insertions, deletions, or substitutions of characters. - If the value you provide is a phrase, separated with spaces, proximity search will be performed. This means that the search will return results that contain the words in your phrase in proximity to each other. The proximity between words is defined by a maximum number of words that can occur between them in the searched field. Optionally, you can also specify a `latest_transaction_collection` flag, which will return only the latest transaction collection for each result. This is useful when you want to get the latest transaction collection for each result, but don't want to perform a separate query for each result. ##### Request SimpleExamplelatest_transaction_collectiontransaction_label application/json Copy ``` { "fields": [ { "field": "addresses/has_state_name/has_value", "value": "CA", "distance": 10, "weight": 0.5 } ] } ``` application/json Copy ``` { "fields": [ { "field": "addresses/has_state_name/has_value", "value": "CA", "distance": 10, "weight": 0.5 } ], "latest_transaction_collection": true } ``` application/json Copy ``` { "fields": [ { "field": "addresses/has_state_name/has_value", "value": "CA", "distance": 10, "weight": 0.5 } ], "transaction_label": "01GZNQYD9H0J2Z57F4JJJTKQ1Q" } ``` ##### Response 200400 application/json Copy Queried response ``` [ { "transaction_id": "01GV5S3SYTEX8QSVEWSPVQHNQS", "score": 0.95, "collection_id": "01GV5S40XNZ47YYASFRE78GXW1" } ] ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Malformed query", "code": "MalformedQueryException" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `fields`required | `object[]` | List of fields to query | | `field` | `string` | Field to queryExample `addresses/has_state_code/has_value` | | `value` | `string` | Value to queryExample `CA` | | `distance` | `number` | Distance to queryExample `10` | | `weight` | `number` | Weight to queryExample `0.5` | | `latest_transaction_collection` | `boolean` | Whether to query the latest transaction collection. If true, results will only contain transaction/collection ID pairs where the collection is the latest in its transaction. Default is false.Example `true` | | `transaction_label` | `string` | When this parameter is set, the search results will only include transactions that have the specified transaction label.Example `my_label` | ##### Response `200``application/json` 3 fields Queried response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction_id of the resultExample `01GV5S3SYTEX8QSVEWSPVQHNQS` | | `score` | `number` | Score of the resultExample `0.95` | | `collection_id` | `string` | Collection_id of the resultExample `01GV5S40XNZ47YYASFRE78GXW1` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Exception Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` ### SUG `POST` `/sug/{container_name}` #### Create Item `create_item` Add item to specified container Endpoint to add an item to a specified container in the Staircase Universal Graph. The 'item' object in request must include the '@type' property and may also include the '@id' property. If the '@id' property is not provided, it will be generated automatically. The 'item' object may also include any additional properties, which will be added to the item. A successful request will return a JSON object containing the 'item' object with '@id', '@type', and any additional properties of the created item. ##### Request application/json Copy ``` { "item": { "@type": "Address", "street": "123 Main St", "city": "Anytown", "state": "CA", "zip": 12345 } } ``` ##### Response 201400404409 application/json Copy Created item successfully ``` { "item": { "@id": "1234567890", "@type": "Address", "street": "123 Main St", "city": "Anytown", "state": "CA", "zip": 12345 } } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` application/json Copy Conflict ``` { "message": "Item with @id 'x' already exists" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `container_name` required | `string` path | `addresses` | Name of the container where the item will be added | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `item` | `object` | Item that was created | | `@id` | `string` | ID of the created item | | `@type` | `string` | Type of the created item | ##### Response `201``application/json` 1 fields Created item successfully | Field | Type | Description | | --- | --- | --- | | `item`required | `object` | Item that was created | | `@id` | `string` | ID of the created item | | `@type` | `string` | Type of the created item | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `GET` `/sug/items/{id}` #### Get Item `get_item` Get item in Staircase Universal Graph Endpoint to get an item in the Staircase Universal Graph. A successful request will return a JSON object containing the 'item' object with '@id', '@type', and properties of the item ##### Response 200400404 application/json Copy Get item successfully ``` { "item": { "@id": "1234567890", "@type": "Address", "street": "123 Main St", "city": "Anytown", "state": "CA", "zip": 12345 }, "container_name": "addresses" } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `AJXZ159292` | Id of the item to get | | `id` required | `string` path | `AJXZ159292` | Id of the item to get | ##### Response `200``application/json` 2 fields Get item successfully | Field | Type | Description | | --- | --- | --- | | `item`required | `object` | Item that was created | | `@id` | `string` | ID of the created item | | `@type` | `string` | Type of the created item | | `container_name` | `string` | Name of the containerExample `container_name` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `POST` `/sug/bulk-upload` #### Bulk Upload `bulk_upload` Bulk Upload items in Staircase Universal Graph Endpoint to bulk upload items to the Staircase Universal Graph. The 'items' object in request must include the '@type' property and may also include the '@id' property. For all the items - if the `@id` property is not provided, it will be generated and set. Otherwise, if the item's `@type` is neither transaction or collection, the `@id` will be replaced with a newly generated one with keeping all the relationships in other items. If some property of the item is a relationship and it contains the value which is not an @id of any item in the same request, this values will not be changed because it is considered as an @id of the existing item in the graph. The 'items' object may also include any additional properties, which will be added to the item. A successful request will return a JSON object containing: - the `upload_id` which could be used to check the status of the upload. - the `items` array of completed items. ##### Request application/json Copy ``` { "items": [ { "@type": "person", "@id": "01GYSJNDZMZB37TNTWY8KVVSSC", "first_name": "John", "last_name": "Doe" }, { "@type": "address", "@id": "01GYSVT1BCQHEFDY86FKGGX8PD", "city": "LA" }, { "@type": "person_address_relation", "@id": "01GYSW9BAD87KKQM7F0GYK1AG3", "has_address": "01GYSVT1BCQHEFDY86FKGGX8PD", "has_person": "01GYSJNDZMZB37TNTWY8KVVSSC" } ] } ``` ##### Response 202400404409 application/json Copy Created item successfully ``` { "upload_id": "1234567890" } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` application/json Copy Conflict ``` { "message": "Item with @id 'x' already exists" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `items`required | `array` | Array of items to be uploaded | | `reassigned_ids` | `boolean` | Flag to reassign ids for items with existing ids. USE ONLY IF NEEDED. | ##### Response `202``application/json` 1 fields Created item successfully | Field | Type | Description | | --- | --- | --- | | `upload_id` | `string` | Id of the upload | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `GET` `/sug/bulk-upload/{upload_id}` #### Check Bulk Upload `get_bulk_upload` Check Bulk Upload Status Endpoint to check the status of a bulk upload to the Staircase Universal Graph. A successful request will return a JSON object containing the `upload_id` and `status` of the upload. ##### Response 200400404409 application/json Copy Created item successfully ``` { "upload_id": "1234567890", "status": "COMPLETED" } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` application/json Copy Conflict ``` { "message": "Item with @id 'x' already exists" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `upload_id` required | `string` path | `1234567890` | Id of the upload | ##### Response `200``application/json` 2 fields Created item successfully | Field | Type | Description | | --- | --- | --- | | `upload_id` | `string` | Id of the upload | | `status` | `string` | Status of the upload`COMPLETED``FAILED``IN_PROGRESS` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `POST` `/sug/construct` #### Construct data query `construct_data_query` This endpoint provides an advanced items data querying mechanism that supports filtering conditions, nested relationships, aggregation, and pagination. It generates SPARQL query language to fetch data from a persistence graph database. You can specify types, properties, optional properties, and conditions along with optional fields like relations, aggregate functions, and grouping. You can specify item properties as ["*"] to include all properties. Supported conditions functions are: eq, in, ne, gt, lt, gte, lte, contains. Relationships are defined in a list of dictionaries, each containing the type, name, properties, conditions, and any nested relations. Aggregation supports simple functions like 'max', 'min', "count", etc. on specific attributes. In addition to this, you can opt for echo functionality which would return the SPARQL query used for the data fetch. ##### Request BasicPersonInfoFilterByNameWithRelationsGroupByAgeIncludeAllPropertiesAggregationExampleOptionalPropertiesAllFieldsExample application/json Copy ``` { "type": "person", "properties": [ "first_name", "last_name" ] } ``` application/json Copy ``` { "type": "person", "properties": [ "first_name", "last_name" ], "conditions": { "first_name": { "condition": "eq", "value": "John" } } } ``` application/json Copy ``` { "type": "person", "properties": [ "first_name", "last_name" ], "relations": [ { "relationship": "earns", "type": "income", "properties": [ "annual_income" ], "conditions": { "annual_income": { "condition": "gt", "value": 50000 } }, "required": true } ] } ``` application/json Copy ``` { "type": "person", "properties": [ "age" ], "group_by": "age" } ``` application/json Copy ``` { "type": "person", "properties": [ "*" ] } ``` application/json Copy ``` { "type": "person", "properties": [ "last_name", "first_name" ], "aggregate": { "function": "max", "attribute": "last_name" }, "group_by": "first_name" } ``` application/json Copy ``` { "type": "person", "properties": [ "first_name", "last_name", "email" ], "optional_properties": [ "email" ] } ``` application/json Copy ``` { "type": "person", "properties": [ "first_name", "last_name", "email" ], "optional_properties": [ "email" ], "relations": [ { "relationship": "earns", "type": "income", "properties": [ "annual_income" ], "conditions": { "annual_income": { "condition": "gt", "value": 50000 } }, "required": true } ], "group_by": "first_name", "aggregate": { "function": "max", "attribute": "last_name" }, "pagination": { "limit": 10 }, "echo": true } ``` ##### Response 200400404409 application/json Copy Succeeded ``` { "items": [ { "@id": "01H7AAJJP33QV8V7EAG26MYZP1", "@type": "person", "first_name": "Leo", "last_name": "Messi", "person_identifier": "5ba3cf68-0eba-4011-a70b-a47899c2f986", "email": "messi@domain.com", "earns": { "@id": "01H7AAMTBJHDS4CB38PVZ62VCW", "@type": "income", "annual_income": 50001, "bonus_income_amount": 200, "income_identifier": "3b317e55-3614-4e97-b2df-e117b8834197" } } ], "pagination": { "limit": 10, "next_token": "39373833613763612d363461662d346231342d383035372d393535346138323363646337" } } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` application/json Copy Conflict ``` { "message": "Item with @id 'x' already exists" } ``` ##### Request body`application/json` 9 fields | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type of the main object you're constructing.Example `person` | | `properties` | `string[]` | Properties to include for each main object. Use * to include all properties. | | `optional_properties` | `string[]` | Optional properties to include for each main object. You can add property from properties parameter here to mark it as optional. | | `conditions` | `object` | Conditions for filtering the main objects. Key-value pairs define the attribute and its condition. | | `relations` | `object[]` | Array of relation objects to include related items in the output. | | `group_by` | `string` | Attribute to group the results by.Example `first_name` | | `aggregate` | `object` | Aggregation function to apply on the grouped results. | | `pagination` | `object` | Pagination options, including limit for paginated responses. | | `echo` | `boolean` | Echo the SPARQL query used for the data fetch. | ##### Response `200``application/json` 3 fields Succeeded | Field | Type | Description | | --- | --- | --- | | `items` | `object[]` | An array of item objects along with their relationship data. | | `@id` | `string` | The unique identifier of item. | | `pagination` | `object` | Pagination metadata for the list of items. | | `limit` | `integer` | The number of items returned per page. | | `next_token` | `integer` | Token to get the next set of items. | | `query` | `string` | The SPARQL query used for the data fetch. | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `GET` `/sug/{container_name}` #### List Items `List Items` List items of specified container Endpoint to list items of a specified container in the Staircase Universal Graph. A successful request will return an array of objects containing the property 'item' with an object with '@id', '@type', and any additional properties of item. ##### Response 200400404 application/json Copy Succeeded ``` { "item": { "@id": "1234567890", "@type": "Address", "street": "123 Main St", "city": "Anytown", "state": "CA", "zip": 12345 }, "version": 1 } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `container_name` required | `string` path | `addresses` | Container name | | `filter` | `string` query | `first_name+eq+John` | Filter to query items in container to be returned. Supported operations - eq, ne, gt, lt, gte, lte, startswith, endswith, contains. | | `group_by` | `string` query | `person_identifier` | Property to group items by for aggregation. Should be a property name, valid for this container or @type or @id. | | `agg_func` | `string` query | `max+@id` | Aggregation for group_by property. Should be in format `{func}+{field}`. Available functions are: min, max, sample. | | `limit` | `string` query | `123456789` | Number of items to return. Default is 100. | | `sort` | `string` query | `asc` | Direction of sorting by '@id'. Default is 'desc'. | ##### Response `200``application/json` 3 fields Succeeded | Field | Type | Description | | --- | --- | --- | | `items`required | `array` | Requested items | | `_links`required | `object` | Links to other resources | | `next` | `string` | Link to next page of resultsExample `https://api.staircaseapi.com/persistence/sug/addresses?filter=first_name+eq+John&next_token=123456789` | | `previous` | `string` | Link to previous page of resultsExample `https://api.staircaseapi.com/persistence/sug/addresses?filter=first_name+eq+John&next_token=123456789` | | `next_token` | `string` | Token to retrieve next page of resultsExample `123456789` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PATCH` `/sug/items/{id}` #### Update Item `update_itemNew` Update item in Staircase Universal Graph The API will create RDF triples with the predicate sc:has_data pointing to the new properties of the updated item. The API will create RDF triples with the predicate sc:has_target pointing to the new item representing the previous version. Consistency is ensured by making sure the RDF triples for sc:has_data and sc:has_target accurately reflect the versions, ensuring the current item points to the updated properties and the new versioned item represents the previous state. Item @id or @type can not be updated. If value of a field is `null`, the field will be removed from the item. ##### Request application/json Copy ``` { "item": { "street": "123 Main St", "city": "Anytown", "state": "CA", "zip": 12345 } } ``` ##### Response 200400404 application/json Copy Created item successfully ``` { "status": "success", "message": "Item updated successfully and previous version created.", "updated_item": { "@id": "AJXZ159292", "@type": "Address", "street": "123 Main St", "city": "Anytown", "state": "CA", "zip": 12345 }, "versioned_item": { "@id": "AJXZ159292_v1", "@type": "Address", "street": "456 Old St", "city": "Oldtown", "state": "CA", "zip": 67890, "sc:version": 1 } } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `AJXZ159292` | Id of the item to get | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `item` | `object` | Item data to update | ##### Response `200``application/json` 4 fields Created item successfully | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the updateExample `success` | | `message` | `string` | MessageExample `Item updated successfully and previous version created.` | | `updated_item` | `object` | Item that was created | | `@id` | `string` | ID of the created item | | `@type` | `string` | Type of the created item | | `versioned_item` | `object` | Item that was created | | `@id` | `string` | ID of the created item | | `@type` | `string` | Type of the created item | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` ### Transactions `POST` `/transactions` #### Create Transaction `create_transaction` Create empty transaction You can subscribe to all 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 ``` { "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 You can provide an trace ID to the transaction by providing `x-sc-trace-id` header or query parameter. If trace ID is not provided, it will be generated automatically. Created transaction guarantees that trace ID will be present in the response header named `x-sc-trace-id`. ##### Request application/json Copy ``` { "label": "first_transaction" } ``` ##### Response 201400 application/json Copy Transaction have been created ``` { "transaction_id": "01EZQ32PJQGKRA6HR8D72Q9FFF", "created_at": "2024-03-29T05:32:11.731227-04:00" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` | `string` query | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string (url)` | URL for receiving events about changes inside transaction | | `label` | `string` | Transaction label | ##### Response `201``application/json` 5 fields Transaction have been created | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `created_at` | `string` | Datetime, when transaction was created | | `callback_url` | `string` | Callback url | | `label` | `string` | Transaction label | | `_links` | `object` | Links | | `collections` | `string (url)` | Link to transaction collections | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/transactions/{transaction_id}` #### Retrieve Transaction `get_transaction` Retrieve transaction ##### Response 200400404 application/json Copy Transaction ``` { "transaction_id": "01EZQ32PJQGKRA6HR8D72Q9FFF", "created_at": "2024-03-29T05:32:11.731227-04:00" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 5 fields Transaction | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `created_at` | `string` | Datetime, when transaction was created | | `callback_url` | `string` | Callback url | | `label` | `string` | Transaction label | | `_links` | `object` | Links | | `collections` | `string (url)` | Link to transaction collections | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/transactions/{transaction_id}/data` #### Retrieve Transaction Data `get_transaction_data` Retrieve transaction data Merge data from all collections of transaction. Data will be merged, assuming, that borrower from every collection is the same borrower ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_ids` | `string` query | `01FEP1VDZE6BQ1Q4X52JNPE2X4,01FEP1VPG7WJVQ3F8B3Y9J2NX8` | List of collection ids, that you want to be merged. | | `types_to_merge` | `string` query | `borrower,loan` | Types for merge | | `save_to_collection` | `boolean` query | `false` | Indicates if output should be saved to collection | | `staircase_version` | `integer` query | `3` | Version of Staircase language for collections to be merged. Collections, that are not of this version will be filtered out | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 4 fields Transaction Data | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `GET` `/transactions/{transaction_id}/data/{merge_id}` #### Retrieve Merge `retrieve_merge` Retrieve merge status Retrieve status of async merge transaction operation for a given merge ID. ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `merge_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRDX5QEXEDVR` | Merge ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 5 fields Merge status | Field | Type | Description | | --- | --- | --- | | `merge_id` | `string` | Merge ID | | `status` | `string` | Merge status | | `transaction_id` | `string` | Transaction ID | | `error` | `string` | Error message if present | | `response_collection_id` | `string` | Collection ID of merged data | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `GET` `/transactions` #### Retrieve List of Transactions `retrieve_transactions` Retrieve transactions Retrieve list of transactions. Transactions can be filtered by transaction_id or created_at fields. Supported operations per fields: - transaction_id: - in: - description: Get only transactions with specified ids - example: transaction_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51 - created_at: - gt: - description: Get transactions, that was created after specified datetime in ISO format - example: created_at+gt+2021-03-30T04:27:15.372006-04:00 - lt: - description: Get transactions, that was created before specified datetime in ISO format - example: created_at+lt+2021-03-30T04:27:15.372006-04:00 - label: - eq: - description: Get transactions where label equals provided value - example: label+eq+byte-efb91c0c-e8d7-4bd5-a25c-07bdf58f3182 ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `filter` | `string` query | `transaction_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51` | Filter expression in format {field_name}+{operation}+{value} | | `sort` | `string` query | `asc` | Order of sorting | | `limit` | `number` query | `5` | Amount of items to show | | `after_id` | `string` query | `01EZQ32PJQGKRA6HR8D72Q9FFF` | id of last evaluated transaction | | `include_collections` | `boolean` query | `false` | If true, transaction collections will be included to the response body. | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 1 fields List of transactions | Field | Type | Description | | --- | --- | --- | | `transactions` | `object[]` | List of transactions | | `transaction_id` | `string` | Transaction id | | `created_at` | `string` | Datetime, when transaction was created | | `collections` | `array` | List of collections created inside transaction | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/transactions/{transaction_id}/data` #### Merge transaction `post_transaction_data` Retrieve transaction data Merge data from all collections of the transaction as well as collections data provided in the body. Data will be merged, assuming that every collection borrower is the same. Merging works only with collections with `"version": 2` in metadata, else it skips the collection without this parameter. You can specify `async` parameter to run the merge in asynchronous way and specify `callback_url` to receive the result in cloudevents format. ##### Request application/json Copy ``` { "merge_transaction_collections": false, "collection_ids": [ "01FDF10040SA2VTETKJQXJ3MQZ", "01FJCADX5QEXEDVRWNXAK206MA" ], "staircase_version": 3, "types_to_merge": [ "borrower", "address" ], "raw_collections": [ { "metadata": { "version": 2, "validation": true }, "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_staircase_document_category_type": { "has_value": "sc_core" }, "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" } } ] } } ] } ``` ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `raw_collections` | `array` | List of collections created inside transaction | | `collection_ids` | `string[]` | List of Collection IDs to be merged | | `types_to_merge` | `string[]` | List of Types to be merged | | `staircase_version` | `integer` | Version of Staircase language for collections to be merged. Collections, that are not of this version will be filtered out | | `merge_transaction_collections` | `boolean` | If `true`, existing transaction collections will be included in merge | | `async` | `boolean` | If `true`, merge will be performed asynchronously | | `callback_url` | `string (uri)` | URL to which the callback will be sent if `async` is `true` | ##### Response `201``application/json` 4 fields Transaction Data | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `202``application/json` 2 fields Merge transaction collections request accepted | Field | Type | Description | | --- | --- | --- | | `merge_id` | `string` | Merge ID | | `status` | `string` | Merge status | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/transactions/merge` #### Merge Transactions `merge_transactions` Merge transactions into one transaction. This endpoint will merge all transactions into one transaction. All collections from transactions will be moved to new transaction. If you want to merge specific collections, you can use `collections` field. Only collections, that has version 3 and are validated using `metadata.validation = true`, can be merged. This API can merge up to 1000 collections. ##### Request merge_with_transactionsmerge_with_collections application/json Copy ``` { "transaction_ids": [ "01FJCADX5QEXEDVRWNXAK206MA", "01FJCAQW7EYJAA6FY05WRKRM3T" ] } ``` application/json Copy ``` { "collections": [ { "transaction_id": "01FJCADX5QEXEDVRWNXAK206MA", "collection_id": "01FJCAQW7EYJAA6FY05WRKRM3T" } ] } ``` ##### Response 200 application/json200 application/json400404 application/json Copy New merged transaction ``` { "transaction_id": "01FJCADX5QEXEDVRWNXAK206MA", "created_at": "2024-03-29T05:32:11.731227-04:00", "label": null, "callback_url": null, "_links": { "collections": "https://documentation.straircaseapi.com/transactions/01FJCADX5QEXEDVRWNXAK206MA/collections" } } ``` application/json Copy New merged transaction ``` { "transaction_id": "01EZQ32PJQGKRA6HR8D72Q9FFF", "created_at": "2024-03-29T05:32:11.731227-04:00" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids`required | `string[]` | Transaction ids | | `collections` | `object[]` | Collections to merge into one transaction | | `transaction_id` | `string (ulid)` | Transaction id | | `collection_id` | `string (ulid)` | Collection id | ##### Response `200``application/json` 5 fields New merged transaction | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `created_at` | `string` | Datetime, when transaction was created | | `callback_url` | `string` | Callback url | | `label` | `string` | Transaction label | | `_links` | `object` | Links | | `collections` | `string (url)` | Link to transaction collections | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` ### Collections `POST` `/transactions/{transaction_id}/collections` #### Create Collection `create_collection` Create Collection. Collection data can be validated by setting validation flag to true and version in metadata. To validate version 2 Language is required to be installed on the environment. To validate version 3 Persistence Graph is required to be installed on the environment. Collections by default are saved to Persistence Graph. Collections created with version 2 or 3 of Staircase lexicon are dumped according to the version of Staircase lexicon. Collections created with version 0 of Staircase lexicon are dumped with prefix ``" ##### Request 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" } } ] } } ``` ##### Response 201400404 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" } } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | Collection data | | `metadata` | `object` | Collection metadata. Maximum allowable length of the dumped json object - 400 000 symbols. | | `version` | `integer` | Version of staircase language with what collection has been created.`0``2``3` | | `validation` | `boolean` | Flag that enables validation | | `linked_collections` | `object[]` | List of linked collections | | `collection_id` | `string (ulid)` | Collection ID of linked collection | | `label` | `string` | Label of linked collection | | `serialise_to_graph` | `boolean` | Flag that enables collection serialization to persistence graph | | `fuzzy_searchable` | `boolean` | Flag that enables fuzzy search for collection | ##### Response `201``application/json` 4 fields 201 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `413` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `get_collection` ##### Response 200400404 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" } } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | Collection ID | | `refs` | `boolean` query | `true` | If `true`, refs will not be resolved | | `flatten` | `boolean` query | `true` | If `true`, the collection will be flattened | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/transactions/{transaction_id}/collections/{collection_id}/graph` #### Perform Graph Query on Collection Level `collection_graph` Perform graph query on collection level This feature is experimental Collections created using v2 Staircase language represents data linked with `@id`, so it can be presented like graph F.e in collection below ``` { "metadata": { "version": 2 }, "data": { "addresses": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "address", "has_address_line_1_text": { "has_value": "1234 MAIN STREET" }, "has_address_line_2_text": { "has_value": "SUITE 30" }, "has_city_name": { "has_value": "LOS ANGELES" }, "has_full_address_text": { "has_value": "1234 Main St, Suite 30, Los Angeles, CA 90210" }, "has_postal_code": { "has_value": "90210" }, "has_state_code": { "has_value": "CA" } }, { "@id": "01F6N4YSTP8PRC75SBT40JH0CM", "@type": "address", "has_address_line_1_text": { "has_value": "410 TERRY AVE. NORTH" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "SEATTLE" }, "has_full_address_text": { "has_value": "None" }, "has_postal_code": { "has_value": "98109" }, "has_state_code": { "has_value": "WA" } } ], "people": [ { "@id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "@type": "borrower", "earns": [ "01F6N4YSTNWAVCPDK0GTA32B9Z" ], "has_first_name": { "has_value": "JOHN" }, "has_full_name": { "has_value": "JOHN DOE" }, "has_last_name": { "has_value": "DOE" }, "has_social_security_number": { "has_value": "999-00-0000" }, "with_address": [ "01F6N4YSSFY8EB5RAY0XNCQ7XD" ], "works_for": [ "01F6N4YSTM8EWPM80PFYJA15JP" ] } ] } } ``` As we can see, there is one borrower, and property `with_address` links us to address in LOS ANGELES. To query borrower information with his address info embed into it, we should construct shape query, where we will specify list of all properties, that we want to retrieve Show the rest ``` { "people": { "has_first_name": {}, "has_last_name": {}, "with_address": { "has_address_line_1_text": {}, "has_address_line_2_text": {}, "has_city_name": {}, "has_full_address_text": {}, "has_postal_code": {}, "has_state_code": {} } } } ``` As a result we will have ``` { "people": [ { "@id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "@type": "borrower", "has_first_name": { "has_value": "JOHN" }, "has_last_name": { "has_value": "DOE" }, "with_address": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "address", "has_address_line_1_text": { "has_value": "1234 MAIN STREET" }, "has_address_line_2_text": { "has_value": "SUITE 30" }, "has_city_name": { "has_value": "LOS ANGELES" }, "has_full_address_text": { "has_value": "1234 Main St, Suite 30, Los Angeles, CA 90210" }, "has_postal_code": { "has_value": "90210" }, "has_state_code": { "has_value": "CA" } } ] } ] } ``` So, for retrieving data you should specify the structure, that you want it to have, you will get only property, that you specified as keys and `{}` as a value. For referencable properties, there is no need to specify `has_value` property. ##### Request application/json Copy ``` { "people": { "has_first_name": {}, "earns": { "has_federal_tax_withheld_amount": {}, "has_dependent_care_benefits_amount": {} } } } ``` ##### Response 200400404 application/json Copy Resolved graph query ``` { "people": [ { "@id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "@type": "borrower", "earns": [ { "@id": "01F6N4YSTNWAVCPDK0GTA32B9Z", "@type": "employment_income", "has_dependent_care_benefits_amount": { "has_value": "1000.00" }, "has_federal_tax_withheld_amount": { "has_value": "6835.00" } } ], "has_first_name": { "has_value": "JOHN" } } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | Collection ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200` `POST` `/transactions/{transaction_id}/collections/{collection_id}/query` #### Query on Collection Level `query_collection` This endpoint provides query capabilities on collection level. You can write query in one of two formats: - JSONPath - JMESPath You can write queries, that will follow links in your collection to get results. For example, we have this collection: ``` { "addresses": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "mailing_address", "has_city_name": { "has_value": "LOS ANGELES" }, "has_state_code": { "has_value": "CA" } }, { "@id": "01FFFRTHRP2FPT481FVT1R1Z0Q", "@type": "mailing_address", "has_city_name": { "has_value": "SAN FRANCISCO" }, "has_state_code": { "has_value": "CA" } }, { "@id": "01F6N4YSTP8PRC75SBT40JH0CM", "@type": "residential_address", "has_city_name": { "has_value": "SEATTLE" }, "has_state_code": { "has_value": "WA" } }, { "@id": "01FFFR2XWQTBGNNXN68X32QS8Y", "@type": "mailing_address", "has_city_name": { "has_value": "NEW YORK" }, "has_state_code": { "has_value": "CA" } } ], "people": [ { "@id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "@type": "borrower", "has_first_name": { "has_value": "JOHN" }, "has_full_name": { "has_value": "JOHN DOE" }, "has_last_name": { "has_value": "DOE" }, "with_address": [ "01F6N4YSSFY8EB5RAY0XNCQ7XD", "01F6N4YSTP8PRC75SBT40JH0CM", "01FFFR2XWQTBGNNXN68X32QS8Y" ] }, { "@id": "01FFFQSWKY384GKNQFMET31HTX", "@type": "co_borrower", "has_first_name": { "has_value": "Rakhim" }, "has_full_name": { "has_value": "Rakhim Sterling" }, "has_last_name": { "has_value": "Sterling" }, "with_address": [ "01FFFQZ4BE5NRJDGP7FJ20XA0H" ] } ] } ``` As you see here we have two people, one borrower and one co-borrower. Three addresses is associated to borrower, two mailing and one residential. One mailing address is associated to co-borrower. Let's build query to retrieve city name of borrower mailing address. To do this, we need to get people, where type equals borrower and addresses, where type equals mailing address. JSONPath query: Show the rest ``` { "format": "jsonpath", "query": "$.people[?(@['@type'] = 'borrower')].with_address[?(@['@type'] = 'mailing_address')].has_city_name.has_value" } ``` Result: ``` { "result": ["LOS ANGELES", "NEW YORK"] } ``` Same query using JMESPath, but with grabing state code and reformatting output: ``` { "format": "jmespath", "query": "people[?\"@type\" == 'borrower'].with_address[] | [?\"@type\" == 'mailing_address'].{city: has_city_name.has_value, state_code: has_state_code.has_value}" } ``` Result: ``` { "result": [ { "city": "LOS ANGELES", "state_code": "CA" }, { "city": "NEW YORK", "state_code": "CA" } ] } ``` ##### Request jsonpathjmespath application/json Copy JSONPath query ``` { "format": "jsonpath", "query": "$.people[?(@['@type'] = 'borrower')].with_address[?(@['@type'] = 'mailing_address')].has_city_name.has_value" } ``` application/json Copy JMESPath query ``` { "format": "jmespath", "query": "people[?\"@type\" == 'borrower'].with_address[] | [?\"@type\" == 'mailing_address'].{city: has_city_name.has_value, state_code: has_state_code.has_value}" } ``` ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | Collection ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `format`required | `string` | Query format.`jmespath``jsonpath` | | `query`required | `string` | Query. | ##### Response `200``application/json` 1 fields Query results. | Field | Type | Description | | --- | --- | --- | | `result` | `one of` | Query results. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `get_collections` Retrieve Transaction Collections. If transaction was replaced by the new one, it will return collections from the new transaction. This behavior can be changed by providing `ignore_replacement` query parameter. 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 ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `filter` | `string` query | `collection_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51` | Filter expression in format {field_name}+{operation}+{value} | | `ignore_replacement` | `boolean` query | `true` | Ignores replacement for the transaction. | | `sort` | `string` query | `asc` | Order of sorting | | `limit` | `number` query | `5` | Amount of items to show | | `after_id` | `string` query | `01EZQ32PJQGKRA6HR8D72Q9FFF` | id of last evaluated collection | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | | `collections` | `object[]` | List of collections without 'data' field and with links to retrieve single collections. | | `transaction_id` | `string (ulid)` | Transaction id | | `collection_id` | `string (ulid)` | Collection id | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema Maximum allowable length of the dumped json object - 400 000 symbols. | | `_links` | `object` | Links | | `collection` | `string (url)` | Link to retrieve full collection. | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `update_collection` Update Collection. Collection data can not be updated, but it can be inserted, if previously it was an empty object. ##### Request application/json Copy ``` { "data": { "deal_sets": [ { "assets": [ { "account_identifier": "1523421245", "cash_or_market_value": 45000, "holder_name": "BankA", "type": "SavingsAccount" } ], "collaterals": [ { "address": { "city": "Winston Salem", "line_text": "1234 Main St", "postal_code": "27104", "state_code": "NC" }, "property_detail": { "attachment_type": "Detached", "construction_method_type": "SiteBuilt", "estate_type": "FeeSimple", "estimated_value": 225000, "financed_unit_count": 1, "is_existing_clean_energy_lien": false, "is_in_project": false, "is_mixed_usage": false, "is_pud": false, "usage_type": "PrimaryResidence" }, "property_valuations": { "property_valuation": [ { "property_valuation_detail": { "amount": 225000, "appraisal_identifier": "1100AA1111" } } ] }, "sales_contracts": { "sales_contract": [ { "sales_contract_detail": { "amount": 225000 } } ] } } ], "expenses": [ { "EXTENSION": "false", "monthly_payment": 127, "type": "JobRelatedExpenses" } ], "liabilities": [ { "account_identifier": "913432", "holder_name": "Toyota Credit", "is_exclusion": false, "is_payoff_status": false, "monthly_payment": 500, "type": "Installment", "unpaid_balance": 15838 } ], "loans": [ { "amortization": { "loan_period_count": 360, "loan_period_type": "Month", "type": "Fixed" }, "application_received_date": "2019-03-21", "cash_out_determination_type": null, "document_specific_data_sets": [ { "EXTENSION": "2250", "estimated_closing_costs": 6750, "mi_and_funding_fee_financed": 0, "prepaid_items_estimated": 2300 } ], "housing_expenses": [ { "payment": 506.69, "timing_type": "Proposed", "type": "FirstMortgagePrincipalAndInterest" }, { "payment": 153, "timing_type": "Proposed", "type": "HomeownersInsurance" }, { "payment": 188, "timing_type": "Proposed", "type": "RealEstateTax" }, { "payment": 123, "timing_type": "Proposed", "type": "Other", "type_other": "WaterSewerAssessment" } ], "is_balloon": false, "is_buydown_temporary_subsidy_funding": false, "is_construction": false, "is_interest_only": false, "is_prepayment_penalty": false, "loan_identifiers": [ { "identifier": "1122334455", "type": "LenderLoan" }, { "identifier": "111198756421356000", "type": "MERS_MIN" }, { "identifier": "1234567890", "type": "UniversalLoan" } ], "loan_product": { "description": "30YrFixed", "discount_points_total": 2100 }, "loan_statuses": [ { "identifier": "Underwriting" } ], "origination_systems": [ { "loan_vendor_identifier": "000000", "loan_version_identifier": "2.7" } ], "projected_reserves": 100000, "purchase_credits": [ { "amount": 1000, "source_type": "BorrowerPaidOutsideClosing", "type": "EarnestMoney" }, { "amount": 750, "source_type": "Lender", "type": "Other", "type_other": "ClosingCosts" } ], "qualifying_rate_percent": null, "terms_of_loan": { "base": 100000, "lien_priority_type": "FirstLien", "mortgage_type": "Conventional", "note_rate_percent": 4.5, "purpose_type": "Purchase" } } ] } ] } } ``` ##### Response 200400404 application/json Copy 200 response ``` { "transaction_id": "dfa22839-8ecd-40c0-9bcb-b70f78002cdb", "collection_id": "104592a7-fcbe-4fa3-92e9-90e2b648a0a4", "metadata": {}, "data": { "deal_sets": [ { "assets": [ { "account_identifier": "1523421245", "cash_or_market_value": 45000, "holder_name": "BankA", "type": "SavingsAccount" } ], "collaterals": [ { "address": { "city": "Winston Salem", "line_text": "1234 Main St", "postal_code": "27104", "state_code": "NC" }, "property_detail": { "attachment_type": "Detached", "construction_method_type": "SiteBuilt", "estate_type": "FeeSimple", "estimated_value": 225000, "financed_unit_count": 1, "is_existing_clean_energy_lien": false, "is_in_project": false, "is_mixed_usage": false, "is_pud": false, "usage_type": "PrimaryResidence" }, "property_valuations": { "property_valuation": [ { "property_valuation_detail": { "amount": 225000, "appraisal_identifier": "1100AA1111" } } ] }, "sales_contracts": { "sales_contract": [ { "sales_contract_detail": { "amount": 225000 } } ] } } ], "expenses": [ { "EXTENSION": "false", "monthly_payment": 127, "type": "JobRelatedExpenses" } ], "liabilities": [ { "account_identifier": "913432", "holder_name": "Toyota Credit", "is_exclusion": false, "is_payoff_status": false, "monthly_payment": 500, "type": "Installment", "unpaid_balance": 15838 } ], "loans": [ { "amortization": { "loan_period_count": 360, "loan_period_type": "Month", "type": "Fixed" }, "application_received_date": "2019-03-21", "cash_out_determination_type": null, "document_specific_data_sets": [ { "EXTENSION": "2250", "estimated_closing_costs": 6750, "mi_and_funding_fee_financed": 0, "prepaid_items_estimated": 2300 } ], "housing_expenses": [ { "payment": 506.69, "timing_type": "Proposed", "type": "FirstMortgagePrincipalAndInterest" }, { "payment": 153, "timing_type": "Proposed", "type": "HomeownersInsurance" }, { "payment": 188, "timing_type": "Proposed", "type": "RealEstateTax" }, { "payment": 123, "timing_type": "Proposed", "type": "Other", "type_other": "WaterSewerAssessment" } ], "is_balloon": false, "is_buydown_temporary_subsidy_funding": false, "is_construction": false, "is_interest_only": false, "is_prepayment_penalty": false, "loan_identifiers": [ { "identifier": "1122334455", "type": "LenderLoan" }, { "identifier": "111198756421356000", "type": "MERS_MIN" }, { "identifier": "1234567890", "type": "UniversalLoan" } ], "loan_product": { "description": "30YrFixed", "discount_points_total": 2100 }, "loan_statuses": [ { "identifier": "Underwriting" } ], "origination_systems": [ { "loan_vendor_identifier": "000000", "loan_version_identifier": "2.7" } ], "projected_reserves": 100000, "purchase_credits": [ { "amount": 1000, "source_type": "BorrowerPaidOutsideClosing", "type": "EarnestMoney" }, { "amount": 750, "source_type": "Lender", "type": "Other", "type_other": "ClosingCosts" } ], "qualifying_rate_percent": null, "terms_of_loan": { "base": 100000, "lien_priority_type": "FirstLien", "mortgage_type": "Conventional", "note_rate_percent": 4.5, "purpose_type": "Purchase" } } ] } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | Collection ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | Data for updating | | `metadata` | `object` | Metadata for updating. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `413``422` `POST` `/models/convert` #### Convert Nested Model `convert_nested_model` Convert nested models into flat Staircase collections This endpoint allows you to convert data structures with nested elements into a more manageable, flat format. It requires `data` field in it's body, and will flatten data according to V3 Lexicon ##### Request application/json Copy ``` { "data": { "liabilities": [ { "@type": "liability", "liability_account_identifier": "12340002", "has_liability_timeline": { "@type": "liability_timeline", "liability_unpaid_balance_amount": 2000 } } ] } } ``` ##### Response 200400404 application/json Copy New flattened data ``` { "data": { "liabilities": [ { "@id": "01HHEEBDS82E4FXB7XKB2EFN54", "@type": "liability", "has_liability_timeline": "01HHKJY1QNZ5MFPEAHS4KSRNCW", "liability_account_identifier": "12340002" } ], "liability_timelines": [ { "@id": "01HHKJY1QNZ5MFPEAHS4KSRNCW", "@type": "liability_timeline", "liability_unpaid_balance_amount": 2000 } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Data | ##### Response `200``application/json` 1 fields New flattened data | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Data | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PATCH` `/transactions/{transaction_id}/collections/{collection_id}` #### Patch Collection `patch_collection` Patch collection This endpoint provides ability to patch collection. Collections are immutable, so as a result you will have new collection created for you with applied changes. #### Operations ##### Remove This operation gives you the ability to remove elements and/or properties from your collection along with its relationships. You can explicitly specify the element ID you want to remove or apply the query. Read more about queries by the link. You can also specify depth for graph traversing and relationships, you don't want to remove. For examples, we use this collection Show the rest ``` { "metadata": { "version": 2 }, "data": { "addresses": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "address", "has_address_line_1_text": { "has_value": "1234 MAIN STREET" }, "has_address_line_2_text": { "has_value": "SUITE 30" }, "has_city_name": { "has_value": "LOS ANGELES" }, "has_full_address_text": { "has_value": "1234 Main St, Suite 30, Los Angeles, CA 90210" }, "has_postal_code": { "has_value": "90210" }, "has_state_code": { "has_value": "CA" } }, { "@id": "01F6N4YSTP8PRC75SBT40JH0CM", "@type": "address", "has_address_line_1_text": { "has_value": "410 TERRY AVE. NORTH" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "SEATTLE" }, "has_full_address_text": { "has_value": "None" }, "has_postal_code": { "has_value": "98109" }, "has_state_code": { "has_value": "WA" } } ], "documents": [ { "@id": "01F6N4YSRAQVA8FA1F5MKBYR55", "@type": "irs_w2", "has_data_owner_document_identifer": { "has_value": "None" }, "has_document_data_extraction_confidence_score": { "has_value": 72.453 }, "has_document_identifier": { "has_value": "z354-43431" }, "has_instance_identifier": { "has_value": "z354-43431" } } ], "employment": [ { "@id": "01F6N4YSXSGAGJ0BKKMB7606V0", "@type": "employment", "has_retirement_plan_participant_indicator": { "has_value": "true" }, "has_statutory_employee_indicator": { "has_value": "false" } } ], "income": [ { "@id": "01F6N4YSTNWAVCPDK0GTA32B9Z", "@type": "employment_income", "earned_from": [ "01F6N4YSXSGAGJ0BKKMB7606V0" ], "has_allocated_tips_amount": { "has_value": "" }, "has_dependent_care_benefits_amount": { "has_value": "1000.00" }, "has_federal_tax_withheld_amount": { "has_value": "6835.00" }, "has_gross_income_amount": { "data_sourced_from": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ], "has_data_extraction_confidence_score": 32.38, "has_value": "48500.00" }, "has_income_paid_by_third_parties_indicator": { "has_value": "false" }, "has_local_1_income_amount": { "has_value": "50000.00" }, "has_local_1_tax_withheld_amount": { "has_value": "750.00" }, "has_local_2_income_amount": { "has_value": "" }, "has_local_2_tax_withheld_amount": { "has_value": "" }, "has_locality_1_name": { "has_value": "MU" }, "has_locality_2_name": { "has_value": "" }, "has_medicare_income_amount": { "has_value": "50000.00" }, "has_medicare_tax_withheld_amount": { "has_value": "725.00" }, "has_nonqualified_retirement_plan_distribution_amount": { "has_value": "" }, "has_social_security_income_amount": { "has_value": "50000.00" }, "has_social_security_tax_withheld_amount": { "has_value": "3100.00" }, "has_social_security_tips_amount": { "has_value": "600.00" }, "has_state_1_income_amount": { "data_owned_by": [ "01F6N4YSTM8EWPM80PFYJA15JP" ], "data_sourced_from": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ], "has_data_extraction_confidence_score": 76.68, "has_value": "50000.00" }, "has_state_1_tax_withheld_amount": { "has_value": "1535.00" }, "has_state_2_income_amount": { "has_value": "" }, "has_state_2_tax_withheld_amount": { "has_value": "" } } ], "mortgage_products": [ { "@id": "01F6N4YSXSN7Y010QW2AG4M70W", "@type": "data_extraction", "product_used_for": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ] } ], "organizations": [ { "@id": "01F6N4YSTM8EWPM80PFYJA15JP", "@type": "organization", "has_organization_identifier": "23-5247235", "has_organization_name": { "has_value": "AMAZON , INC." }, "with_address": [ "01F6N4YSTP8PRC75SBT40JH0CM" ] } ], "people": [ { "@id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "@type": "borrower", "earns": [ "01F6N4YSTNWAVCPDK0GTA32B9Z" ], "has_first_name": { "has_value": "JOHN" }, "has_full_name": { "has_value": "JOHN DOE" }, "has_last_name": { "has_value": "DOE" }, "has_social_security_number": { "has_value": "999-00-0000" }, "with_address": [ "01F6N4YSSFY8EB5RAY0XNCQ7XD" ], "works_for": [ "01F6N4YSTM8EWPM80PFYJA15JP" ] } ] } } ``` ###### Remove element by `@id` To remove element and all connected elements we just need to specify `@id` of it. Let's remove the only organization we have in our collection. ``` { "element_id": "01F6N4YSTM8EWPM80PFYJA15JP", "op": "remove" } ``` As a result we have collection without organization and its address ``` { "metadata": { "version": 2 }, "data": { "addresses": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "address", "has_address_line_1_text": { "has_value": "1234 MAIN STREET" }, "has_address_line_2_text": { "has_value": "SUITE 30" }, "has_city_name": { "has_value": "LOS ANGELES" }, "has_full_address_text": { "has_value": "1234 Main St, Suite 30, Los Angeles, CA 90210" }, "has_postal_code": { "has_value": "90210" }, "has_state_code": { "has_value": "CA" } } ], "documents": [ { "@id": "01F6N4YSRAQVA8FA1F5MKBYR55", "@type": "irs_w2", "has_data_owner_document_identifer": { "has_value": "None" }, "has_document_data_extraction_confidence_score": { "has_value": 72.453 }, "has_document_identifier": { "has_value": "z354-43431" }, "has_instance_identifier": { "has_value": "z354-43431" } } ], "employment": [ { "@id": "01F6N4YSXSGAGJ0BKKMB7606V0", "@type": "employment", "has_retirement_plan_participant_indicator": { "has_value": "true" }, "has_statutory_employee_indicator": { "has_value": "false" } } ], "income": [ { "@id": "01F6N4YSTNWAVCPDK0GTA32B9Z", "@type": "employment_income", "earned_from": [ "01F6N4YSXSGAGJ0BKKMB7606V0" ], "has_allocated_tips_amount": { "has_value": "" }, "has_dependent_care_benefits_amount": { "has_value": "1000.00" }, "has_federal_tax_withheld_amount": { "has_value": "6835.00" }, "has_gross_income_amount": { "data_sourced_from": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ], "has_data_extraction_confidence_score": 32.38, "has_value": "48500.00" }, "has_income_paid_by_third_parties_indicator": { "has_value": "false" }, "has_local_1_income_amount": { "has_value": "50000.00" }, "has_local_1_tax_withheld_amount": { "has_value": "750.00" }, "has_local_2_income_amount": { "has_value": "" }, "has_local_2_tax_withheld_amount": { "has_value": "" }, "has_locality_1_name": { "has_value": "MU" }, "has_locality_2_name": { "has_value": "" }, "has_medicare_income_amount": { "has_value": "50000.00" }, "has_medicare_tax_withheld_amount": { "has_value": "725.00" }, "has_nonqualified_retirement_plan_distribution_amount": { "has_value": "" }, "has_social_security_income_amount": { "has_value": "50000.00" }, "has_social_security_tax_withheld_amount": { "has_value": "3100.00" }, "has_social_security_tips_amount": { "has_value": "600.00" }, "has_state_1_income_amount": { "data_sourced_from": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ], "has_data_extraction_confidence_score": 76.68, "has_value": "50000.00" }, "has_state_1_tax_withheld_amount": { "has_value": "1535.00" }, "has_state_2_income_amount": { "has_value": "" }, "has_state_2_tax_withheld_amount": { "has_value": "" } } ], "mortgage_products": [ { "@id": "01F6N4YSXSN7Y010QW2AG4M70W", "@type": "data_extraction", "product_used_for": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ] } ], "people": [ { "@id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "@type": "borrower", "earns": [ "01F6N4YSTNWAVCPDK0GTA32B9Z" ], "has_first_name": { "has_value": "JOHN" }, "has_full_name": { "has_value": "JOHN DOE" }, "has_last_name": { "has_value": "DOE" }, "has_social_security_number": { "has_value": "999-00-0000" }, "with_address": [ "01F6N4YSSFY8EB5RAY0XNCQ7XD" ] } ] } } ``` ###### Use depth Let's remove borrower, but keep all elements, connected with it in collection. To do it, we need to specify borrower ID and depth = 1. ``` { "op": "remove", "element_id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "depth": 1 } ``` As a result we have same collection, just without borrower element ``` { "metadata": { "version": 2 }, "data": { "addresses": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "address", "has_address_line_1_text": { "has_value": "1234 MAIN STREET" }, "has_address_line_2_text": { "has_value": "SUITE 30" }, "has_city_name": { "has_value": "LOS ANGELES" }, "has_full_address_text": { "has_value": "1234 Main St, Suite 30, Los Angeles, CA 90210" }, "has_postal_code": { "has_value": "90210" }, "has_state_code": { "has_value": "CA" } }, { "@id": "01F6N4YSTP8PRC75SBT40JH0CM", "@type": "address", "has_address_line_1_text": { "has_value": "410 TERRY AVE. NORTH" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "SEATTLE" }, "has_full_address_text": { "has_value": "None" }, "has_postal_code": { "has_value": "98109" }, "has_state_code": { "has_value": "WA" } } ], "documents": [ { "@id": "01F6N4YSRAQVA8FA1F5MKBYR55", "@type": "irs_w2", "has_data_owner_document_identifer": { "has_value": "None" }, "has_document_data_extraction_confidence_score": { "has_value": 72.453 }, "has_document_identifier": { "has_value": "z354-43431" }, "has_instance_identifier": { "has_value": "z354-43431" } } ], "employment": [ { "@id": "01F6N4YSXSGAGJ0BKKMB7606V0", "@type": "employment", "has_retirement_plan_participant_indicator": { "has_value": "true" }, "has_statutory_employee_indicator": { "has_value": "false" } } ], "income": [ { "@id": "01F6N4YSTNWAVCPDK0GTA32B9Z", "@type": "employment_income", "earned_from": [ "01F6N4YSXSGAGJ0BKKMB7606V0" ], "has_allocated_tips_amount": { "has_value": "" }, "has_dependent_care_benefits_amount": { "has_value": "1000.00" }, "has_federal_tax_withheld_amount": { "has_value": "6835.00" }, "has_gross_income_amount": { "data_sourced_from": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ], "has_data_extraction_confidence_score": 32.38, "has_value": "48500.00" }, "has_income_paid_by_third_parties_indicator": { "has_value": "false" }, "has_local_1_income_amount": { "has_value": "50000.00" }, "has_local_1_tax_withheld_amount": { "has_value": "750.00" }, "has_local_2_income_amount": { "has_value": "" }, "has_local_2_tax_withheld_amount": { "has_value": "" }, "has_locality_1_name": { "has_value": "MU" }, "has_locality_2_name": { "has_value": "" }, "has_medicare_income_amount": { "has_value": "50000.00" }, "has_medicare_tax_withheld_amount": { "has_value": "725.00" }, "has_nonqualified_retirement_plan_distribution_amount": { "has_value": "" }, "has_social_security_income_amount": { "has_value": "50000.00" }, "has_social_security_tax_withheld_amount": { "has_value": "3100.00" }, "has_social_security_tips_amount": { "has_value": "600.00" }, "has_state_1_income_amount": { "data_sourced_from": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ], "has_data_extraction_confidence_score": 76.68, "has_value": "50000.00" }, "has_state_1_tax_withheld_amount": { "has_value": "1535.00" }, "has_state_2_income_amount": { "has_value": "" }, "has_state_2_tax_withheld_amount": { "has_value": "" } } ], "mortgage_products": [ { "@id": "01F6N4YSXSN7Y010QW2AG4M70W", "@type": "data_extraction", "product_used_for": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ] } ], "organizations": [ { "@id": "01F6N4YSTM8EWPM80PFYJA15JP", "@type": "organization", "has_organization_identifier": "23-5247235", "has_organization_name": { "has_value": "AMAZON , INC." }, "with_address": [ "01F6N4YSTP8PRC75SBT40JH0CM" ] } ] } } ``` ###### Exclude relationships Let's remove borrower and everything connected, except his adress. To do this, we need to specify `with_address` relationship in `exclude_relationships` field ``` { "op": "remove", "element_id": "01F6N4YSSNTBT17Q5BXDD7R19Q", "exclude_relationships": [ "with_address" ] } ``` Output: ``` { "metadata": { "version": 2 }, "data": { "addresses": [ { "@id": "01F6N4YSSFY8EB5RAY0XNCQ7XD", "@type": "address", "has_address_line_1_text": { "has_value": "1234 MAIN STREET" }, "has_address_line_2_text": { "has_value": "SUITE 30" }, "has_city_name": { "has_value": "LOS ANGELES" }, "has_full_address_text": { "has_value": "1234 Main St, Suite 30, Los Angeles, CA 90210" }, "has_postal_code": { "has_value": "90210" }, "has_state_code": { "has_value": "CA" } }, { "@id": "01F6N4YSTP8PRC75SBT40JH0CM", "@type": "address", "has_address_line_1_text": { "has_value": "410 TERRY AVE. NORTH" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "SEATTLE" }, "has_full_address_text": { "has_value": "None" }, "has_postal_code": { "has_value": "98109" }, "has_state_code": { "has_value": "WA" } } ], "documents": [ { "@id": "01F6N4YSRAQVA8FA1F5MKBYR55", "@type": "irs_w2", "has_data_owner_document_identifer": { "has_value": "None" }, "has_document_data_extraction_confidence_score": { "has_value": 72.453 }, "has_document_identifier": { "has_value": "z354-43431" }, "has_instance_identifier": { "has_value": "z354-43431" } } ], "mortgage_products": [ { "@id": "01F6N4YSXSN7Y010QW2AG4M70W", "@type": "data_extraction", "product_used_for": [ "01F6N4YSRAQVA8FA1F5MKBYR55" ] } ] } } ``` ###### Query All capabilities mentioned eariler can be used with query mechanism. Instead of `element_id` you just need to provide query in the same format as in Query on Collection Level endpoint. With qeury you can remove either elements or proeprties. Elements example: ``` { "op": "remove", "query": { "format": "jmespath", "query": "people[?\"@type\" == 'borrower'].with_address[] | [?\"@type\" == 'mailing_address']" } } ``` Properties example: ``` { "op": "remove", "query": { "format": "jsonpath", "query": "$.people[?(@['@type'] = 'borrower')].with_address[?(@['@type'] = 'mailing_address')].has_city_name" } } ``` ##### Request application/json Copy Simple request ``` { "element_id": "01F6N4YSTM8EWPM80PFYJA15JP", "op": "remove" } ``` ##### Response 200400404 application/json Copy New collection ``` { "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" } } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | Collection ID | | `x-sc-trace-id` required | `string` header | `01FJCADX5QEXEDVRWNXAK206MA` | Trace ID of the transaction | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `op` | `string` | Remove`remove` | | `element_id` | `string` | Element ID | | `exclude_relationships` | `string[]` | Relationships to exclude | | `query` | `object` | query | | `format` | `string` | Query format.`jmespath``jsonpath` | | `query` | `string` | Query. | ##### Response `200``application/json` 4 fields New collection | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields The user has sent too many requests in a given amount of time ("rate limiting") | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Triggers `POST` `/triggers` #### Create Trigger `create_trigger` Create trigger Create a trigger with specific condition as a JMESPath expression. The condition is evaluated on every create/update action with the collections. If the condition is true, the webhook is triggered. The webhook request is sent in Cloudevents format and request contains x-api-key header with the api key of the environment, with collection_id, transaction_id, trigger and transaction label in data. Trigger might be configured to work for validated collections only by setting `"valid_collections_only": true`. In this case, the trigger is triggered only if collection has `"validation": true` in the metadata. ##### Request application/json Copy ``` { "trigger_name": "example_trigger", "condition": "contains(locations[].name, 'Some name')", "webhook_url": "https://example.com/webhook", "transaction_label": "example_transaction", "valid_collections_only": true } ``` ##### Response 201400409 application/json Copy Trigger created ``` { "trigger_id": 52341234, "trigger_name": "example_trigger", "condition": "contains(locations[].name, 'Some name')", "webhook_url": "https://example.com/webhook", "transaction_label": "example_transaction", "valid_collections_only": true } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Conflict ``` { "message": "Trigger name 'x' already exists" } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `trigger_name`required | `string` | Name of the triggerExample `name` | | `condition`required | `string` | Condition as jmespath query that returns a boolean responseExample `contains(locations[].name, 'Some name')` | | `webhook_url`required | `string (uri)` | Webhook URLExample `https://webhook.site/5f9b1b1f-1b1f-5f9b-1b1f-5f9b1b1f5f9b` | | `transaction_label` | `string` | Transaction label to filter transactions with labelExample `optional_label` | | `valid_collections_only` | `boolean` | Flag defining if the trigger is triggered only for collections with `"validation": true` in the `metadata`.Example `true` | ##### Response `201``application/json` 6 fields Trigger created | Field | Type | Description | | --- | --- | --- | | `trigger_name`required | `string` | Name of the triggerExample `name` | | `condition`required | `string` | Condition as jmespath query that returns a boolean responseExample `contains(locations[].name, 'Some name')` | | `webhook_url`required | `string (uri)` | Webhook URLExample `https://webhook.site/5f9b1b1f-1b1f-5f9b-1b1f-5f9b1b1f5f9b` | | `transaction_label` | `string` | Transaction label to filter transactions with labelExample `optional_label` | | `valid_collections_only` | `boolean` | Flag defining if the trigger is triggered only for collections with `"validation": true` in the `metadata`.Example `true` | | `trigger_id`required | `string` | ID of the triggerExample `5f9b1b1f-1b1f-5f9b-1b1f-5f9b1b1f5f9b` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Conflict | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `DELETE` `/triggers/{trigger_id}` #### Delete Trigger `delete_trigger` Delete trigger ##### Response 400404 application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Trigger not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `trigger_id` required | `string` path | `52341234-1234-1234-1234-123412341234` | Trigger ID | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `204``422``500` `PATCH` `/triggers/{trigger_id}` #### Patch Trigger `patch_trigger` Patch trigger Patch trigger with an JSON Patch format object. Remove operation limitations: - Supported only for `transaction_label` field. ##### Request application/json Copy ``` [ { "op": "replace", "path": "trigger_name", "value": "example_trigger" }, { "op": "replace", "path": "condition", "value": "contains(locations[].name, 'Some name')" }, { "op": "replace", "path": "webhook_url", "value": "https://example.com/webhook" }, { "op": "remove", "path": "transaction_label" } ] ``` ##### Response 200400404 application/json Copy Patched trigger object ``` { "trigger_id": 52341234, "trigger_name": "example_trigger", "condition": "contains(locations[].name, 'Some name')", "webhook_url": "https://example.com/webhook", "transaction_label": "example_transaction" } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Trigger not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `trigger_id` required | `string` path | `52341234-1234-1234-1234-123412341234` | Trigger ID | ##### Response `200``application/json` 6 fields Patched trigger object | Field | Type | Description | | --- | --- | --- | | `trigger_name`required | `string` | Name of the triggerExample `name` | | `condition`required | `string` | Condition as jmespath query that returns a boolean responseExample `contains(locations[].name, 'Some name')` | | `webhook_url`required | `string (uri)` | Webhook URLExample `https://webhook.site/5f9b1b1f-1b1f-5f9b-1b1f-5f9b1b1f5f9b` | | `transaction_label` | `string` | Transaction label to filter transactions with labelExample `optional_label` | | `valid_collections_only` | `boolean` | Flag defining if the trigger is triggered only for collections with `"validation": true` in the `metadata`.Example `true` | | `trigger_id`required | `string` | ID of the triggerExample `5f9b1b1f-1b1f-5f9b-1b1f-5f9b1b1f5f9b` | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422``500` `GET` `/triggers` #### List Triggers `list_triggers` List triggers List triggers and query specific filter with a trigger_id or trigger_name parameter in query string. Filtering with trigger_name return all triggers that match trigger_name, else an empty array. Querying with trigger_id returns Not Found if trigger with specific id does not exist. ##### Response 200400404 application/json Copy Triggers listed ``` [ { "trigger_id": 52341234, "trigger_name": "example_trigger", "condition": "contains(locations[].name, 'Some name')", "webhook_url": "https://example.com/webhook", "transaction_label": "example_transaction" } ] ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` application/json Copy Requested resource not found ``` { "message": "Trigger not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `trigger_id` | `string` query | `52341234-1234-1234-1234-123412341234` | Trigger id | | `trigger_name` | `string` query | `example_trigger` | Trigger name | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200``422``500` ### Operations `GET` `/data-share/public-key` ##### Response `200``application/json` 1 fields OK Response | Field | Type | Description | | --- | --- | --- | | `public_key` | `string` | — | `POST` `/data-share/share` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | — | | `collection_id`required | `string` | — | | `to_public_key`required | `string` | — | ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `share_id` | `string` | — | `GET` `/data-share/shared` #### List of colelctions, that was sahred with you ##### Response `200``application/json` 1 fields OK response | Field | Type | Description | | --- | --- | --- | | `collections` | `object[]` | — | | `transaction_id` | `string` | — | | `collection_id` | `string` | — | | `share_id` | `string` | — | ## Errors `400``403``404``406``409``413``422``429``500` ## More in Data - Previous product: ML - Next product: Rule --- # Rule # Rule A declarative rules engine underneath eligibility and validation across products, including model-assisted rule authoring. Rules are data. A rule names the fields it reads, the condition it tests and the result it produces, and the engine evaluates it against a canonical record — which is what lets an eligibility rule change without a deployment of the product that runs it. The same engine backs the conditional requirements in the model's semantic validation and the eligibility logic in the mortgage products. ## How it works Rule authoring is assisted rather than automated. A model drafts a rule from a stated requirement, and the draft is validated against the model's own schema before it is accepted — so a generated rule that references a field that does not exist fails at authoring time rather than at evaluation time. ## Operations ### Engine `POST` `/engine/data/jobs` #### Invoke Ruleset `invokeRuleset` Invoke Ruleset: processes the input collection(s) according to the Ruleset operation as below: - SELECTIVE_DATA_MERGE: merge collections in a new collection. - Input: Staircase Collection(s). - Process: Create new collection by running the ruleset on the input collections. - Output: A new collection generated from running the ruleset. - DATA_INFERRING: modify existing collection. - Input: Staircase Collection. - Process: Modify the collection by running the Ruleset. - Output: Modified collection. Callback URL: The callback is an POST HTTP call with a JSON request body with the following schema: Show the rest ``` { "type": "object", "$schema": "", "required": [ "job_id", "job_status" ], "properties": { "job_id": { "type": "string", "format": "ulid" }, "job_status": { "type": "string", "enum": [ "COMPLETED", "FAILED" ] }, "output": { "type": "object", "required": [ "data", "metadata" ], "properties": { "data": { "type": "object" }, "metadata": { "type": "object", "description": "Metadata about output data", "properties": { "status": { "type": "string", "description": "Status of the data validity", "enum": [ "HAS_VALIDATION_ERRORS" ] }, "status_message": { "type": "string", "description": "Status description" } } } } }, "failure_reason": { "type": "string" } } } ``` Example for completed job: ``` { "job_id": "01FMPQ735YKJ0TFBXX3YKVWK7P", "job_status": "COMPLETED", "output": { "metadata": { "status": "HAS_VALIDATION_ERRORS", "status_message": "Data has at least 1 object in $.data_validation_metadata with a has_validation_code >= 400" }, "data": { "documents": [ { "@id": "01FKYN27FT44KKTAEC58S6Y6FY", "@type": "closing_disclosure", "has_document_date": { "has_value": "2021-01-29" }, "has_document_misclassified_indicator": { "has_value": "false" } } ], "loan_terms": [ { "@id": "01FKYN27FH8P2WS39Z5KSV7CEA", "@type": "loan_terms", "has_hazard_insurance_escrow_required_indicator": { "has_value": "true" }, "has_initial_principal_and_interest_payment_amount": { "has_value": 98.3 }, "has_prepaid_taxes_months_count": { "has_value": "7" }, "has_tax_escrow_required_indicator": { "has_value": "true" } } ], "payments": [ { "@id": "01FKYN27FJN6M8MMFMH4PDSG5E", "@type": "loan_payment", "has_late_charge_rate_percent": { "has_data_extraction_confidence_score": 95, "has_value": "5" } } ] } } } ``` Example for failed job: ``` { "job_id": "01FMQCF7QW6BHZC7NC7XRRHRPN", "job_status": "FAILED", "failure_reason": "Unexpected error." } ``` Example callback for running Ruleset Invocation: The endpoint returns the job_id that can be tracked here ##### Request application/json Copy ``` { "ruleset_name": "selective_merge_ruleset", "input": { "data_objects": [ { "data": { "loans": [ { "@id": "01FKYN27FFCBT3GHGNGWQ9S6CK", "@type": "loan", "with_insurance": [ "01FKYN27FHSK0MFKHD9WXC819J" ], "with_loan_terms": [ "01FKYN27FH8P2WS39Z5KSV7CEB" ], "with_payment": [ "01FKYN27FJN6M8MMFMH4PDSG5E" ] } ], "insurance": [ { "@id": "01FKYN27FHSK0MFKHD9WXC819J", "@type": "mortgage_insurance", "has_insurance_escrowed_indicator": { "has_value": "true" } } ], "loan_terms": [ { "@id": "01FKYN27FH8P2WS39Z5KSV7CEB", "@type": "loan_terms", "has_hazard_insurance_escrow_required_indicator": { "has_value": "true" }, "has_initial_principal_and_interest_payment_amount": { "has_value": 91.5 }, "has_loan_amortization_type": { "has_value": null }, "has_prepaid_taxes_months_count": { "has_value": "7" }, "has_tax_escrow_required_indicator": { "has_value": "true" } } ], "payments": [ { "@id": "01FKYN27FJN6M8MMFMH4PDSG5E", "@type": "loan_payment", "has_late_charge_rate_percent": { "has_value": "5", "has_data_extraction_confidence_score": 95 } } ], "documents": [ { "@id": "01FKYN27FT44KKTAEC58S6Y6FY", "@type": "closing_disclosure", "has_document_date": { "has_value": "2021-01-29" }, "has_document_misclassified_indicator": { "has_value": "false" } } ], "mortgage_products": [ { "@id": "01FKYN27FX3A94JY49JYCW7RG0", "@type": "ide" } ] } } ], "collections": [ { "transaction_id": "01FJC4DRGV5KNWWJZ9Y3D4X3KG", "collection_id": "01FJC4E5E6M9ZJ5TRMJPRQ99C9" }, { "transaction_id": "01FJC4DRGV5KNWWJZ9Y3D4X3KG", "collection_id": "01FJC4E9BXJZA254VTENY1RW9H" }, { "transaction_id": "01FJC4DRGV5KNWWJZ9Y3D4X3KG", "collection_id": "01FJC4EGKZMA6T659B9XP64G4W" } ] }, "callback_url": "https://notify.me/please" } ``` ##### Response 201400 application/json Copy Created. ``` { "ruleset_name": "selective_merge_ruleset", "job_id": "01FJC4JGKFX3VYB0EZ75JNY4J6", "job_status": "STARTED", "input": { "data_objects": [ { "data": { "loans": [ { "@id": "01FKYN27FFCBT3GHGNGWQ9S6CK", "@type": "loan", "with_insurance": [ "01FKYN27FHSK0MFKHD9WXC819J" ], "with_loan_terms": [ "01FKYN27FH8P2WS39Z5KSV7CEB" ], "with_payment": [ "01FKYN27FJN6M8MMFMH4PDSG5E" ] } ], "insurance": [ { "@id": "01FKYN27FHSK0MFKHD9WXC819J", "@type": "mortgage_insurance", "has_insurance_escrowed_indicator": { "has_value": "true" } } ], "loan_terms": [ { "@id": "01FKYN27FH8P2WS39Z5KSV7CEB", "@type": "loan_terms", "has_hazard_insurance_escrow_required_indicator": { "has_value": "true" }, "has_initial_principal_and_interest_payment_amount": { "has_value": 91.5 }, "has_loan_amortization_type": { "has_value": null }, "has_prepaid_taxes_months_count": { "has_value": "7" }, "has_tax_escrow_required_indicator": { "has_value": "true" } } ], "payments": [ { "@id": "01FKYN27FJN6M8MMFMH4PDSG5E", "@type": "loan_payment", "has_late_charge_rate_percent": { "has_value": "5", "has_data_extraction_confidence_score": 95 } } ], "documents": [ { "@id": "01FKYN27FT44KKTAEC58S6Y6FY", "@type": "closing_disclosure", "has_document_date": { "has_value": "2021-01-29" }, "has_document_misclassified_indicator": { "has_value": "false" } } ], "mortgage_products": [ { "@id": "01FKYN27FX3A94JY49JYCW7RG0", "@type": "ide" } ] } } ], "collections": [ { "transaction_id": "01FJC4DRGV5KNWWJZ9Y3D4X3KG", "collection_id": "01FJC4E5E6M9ZJ5TRMJPRQ99C9" }, { "transaction_id": "01FJC4DRGV5KNWWJZ9Y3D4X3KG", "collection_id": "01FJC4E9BXJZA254VTENY1RW9H" }, { "transaction_id": "01FJC4DRGV5KNWWJZ9Y3D4X3KG", "collection_id": "01FJC4EGKZMA6T659B9XP64G4W" } ] } } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction IDExample `01GKMKNNBG21DZ5GZXAQVS7AQC` | | `ruleset_name`required | `string` | Ruleset nameExample `Some Ruleset` | | `input`required | `object` | Data for the processing | | `data_objects` | `object[]` | The array of data objects that need to be processed | | `data`required | `object` | The data in staircase v2 format | | `collections` | `object[]` | The array of collection IDs that need to be processed | | `transaction_id`required | `string (ulid)` | Transaction ID | | `collection_id`required | `string (ulid)` | Collection ID | | `callback_url` | `string (uri)` | The URL which is used to send the result of the job. | ##### Response `201``application/json` 5 fields Created. | Field | Type | Description | | --- | --- | --- | | `ruleset_name`required | `string` | Ruleset nameExample `Some Ruleset` | | `input`required | `object` | Data for the processing | | `data_objects` | `object[]` | The array of data objects that need to be processed | | `data`required | `object` | The data in staircase v2 format | | `collections` | `object[]` | The array of collection IDs that need to be processed | | `transaction_id`required | `string (ulid)` | Transaction ID | | `collection_id`required | `string (ulid)` | Collection ID | | `callback_url` | `string (uri)` | The URL which is used to send the result of the job. | | `job_id`required | `string (ulid)` | Identifier of the job | | `job_status`required | `string` | The status of the job`STARTED` | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400``422` `GET` `/engine/data/jobs/{job_id}` #### Get Ruleset Invocation Status `getRulesetInvocationStatus` Returns the status of invoking Ruleset associated with the input collection(s) and output collection. ##### Response 200400 application/json Copy Created. ``` { "job_id": "01FM2G606MNKG8YKD62EB64DDR", "job_status": "COMPLETED", "ruleset_name": "test4", "callback_url": "https://webhook.site/efc96f90-7e76-41bc-986f-5bcfaf1df8e3", "input": { "data_objects": [ { "data": { "loans": [ { "@id": "01FKYN27FFCBT3GHGNGWQ9S6CK", "@type": "loan", "with_insurance": [ "01FKYN27FHSK0MFKHD9WXC819J" ], "with_loan_terms": [ "01FKYN27FH8P2WS39Z5KSV7CEB" ], "with_payment": [ "01FKYN27FJN6M8MMFMH4PDSG5E" ] } ], "insurance": [ { "@id": "01FKYN27FHSK0MFKHD9WXC819J", "@type": "mortgage_insurance", "has_insurance_escrowed_indicator": { "has_value": "true" } } ], "loan_terms": [ { "@id": "01FKYN27FH8P2WS39Z5KSV7CEB", "@type": "loan_terms", "has_hazard_insurance_escrow_required_indicator": { "has_value": "true" }, "has_initial_principal_and_interest_payment_amount": { "has_value": 91.5 }, "has_loan_amortization_type": { "has_value": null }, "has_prepaid_taxes_months_count": { "has_value": "7" }, "has_tax_escrow_required_indicator": { "has_value": "true" } } ], "payments": [ { "@id": "01FKYN27FJN6M8MMFMH4PDSG5E", "@type": "loan_payment", "has_late_charge_rate_percent": { "has_value": "5", "has_data_extraction_confidence_score": 95 } } ], "documents": [ { "@id": "01FKYN27FT44KKTAEC58S6Y6FY", "@type": "closing_disclosure", "has_document_date": { "has_value": "2021-01-29" }, "has_document_misclassified_indicator": { "has_value": "false" } } ], "mortgage_products": [ { "@id": "01FKYN27FX3A94JY49JYCW7RG0", "@type": "ide" } ] } } ], "collections": [ { "collection_id": "01FM1Z95YK35V2V5MYBV52V1H0", "transaction_id": "01FM1Z7CAEHMA21C0GX78HGGSW" } ] }, "output": { "data": { "assets": [ { "@id": "01FFSP6DRCFJEHQK8ZH38HAH6X", "@type": "savings_account", "owned_by": [ "01FFSP6DRCYYGGY9AER4H7GZXZ" ] }, { "@id": "01FFSP6DRCFJEHQK8ZH38HAH6Z", "@type": "savings_account", "owned_by": [ "01FFSP6DRCYYGGY9AER4H7GZXY", "01FFSP6DRCYYGGY9AER4H7GZXX" ] }, { "@id": "01FFSP6DRCFJEHQK8ZH38HAH6Y", "@type": "savings_account", "owned_by": [ "01FFSP6DRCYYGGY9AER4H7GZXY - 01FFSP6DRCYYGGY9AER4H7GZXZ" ] } ], "people": [ { "@id": "01FFSP6DRCYYGGY9AER4H7GZXY", "@type": "borrower", "has_first_name": { "has_value": "John" }, "has_last_name": { "has_value": "Snow" }, "owns_asset": [ "01FFSP6DRCFJEHQK8ZH38HAH6Z", "01FFSP6DRCFJEHQK8ZH38HAH6Y" ] }, { "@id": "01FFSP6DRCYYGGY9AER4H7GZXZ", "@type": "borrower", "has_first_name": { "has_value": "Jane" }, "has_last_name": { "has_value": "Snow" }, "owns_asset": [ "01FFSP6DRCFJEHQK8ZH38HAH6X", "01FFSP6DRCFJEHQK8ZH38HAH6Y" ] }, { "@id": "01FFSP6DRCYYGGY9AER4H7GZXX", "@type": "borrower", "has_first_name": { "has_value": "Jack" }, "has_last_name": { "has_value": "Snow" }, "owns_asset": [ "01FFSP6DRCFJEHQK8ZH38HAH6Z" ] } ], "relationships": [ { "@type": "relationship", "link_from": [ "01FFSP6DRCFJEHQK8ZH38HAH6Z" ], "link_to": [ "01FFSP6DRCYYGGY9AER4H7GZXY" ], "relationship_link": "ASSET_ROLE" }, { "@type": "relationship", "link_from": [ "01FFSP6DRCFJEHQK8ZH38HAH6Y" ], "link_to": [ "01FFSP6DRCYYGGY9AER4H7GZXY" ], "relationship_link": "ASSET_ROLE" }, { "@type": "relationship", "link_from": [ "01FFSP6DRCFJEHQK8ZH38HAH6Z" ], "link_to": [ "01FFSP6DRCYYGGY9AER4H7GZXX" ], "relationship_link": "ASSET_ROLE" }, { "@type": "relationship", "link_from": [ "01FFSP6DRCFJEHQK8ZH38HAH6Y" ], "link_to": [ "01FFSP6DRCYYGGY9AER4H7GZXZ" ], "relationship_link": "ASSET_ROLE" }, { "@type": "relationship", "link_from": [ "01FFSP6DRCFJEHQK8ZH38HAH6X" ], "link_to": [ "01FFSP6DRCYYGGY9AER4H7GZXZ" ], "relationship_link": "ASSET_ROLE" } ] } } } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string` path | `01FJC4JGKFX3VYB0EZ75JNY4J6` | Identifier of the data processing job. | ##### Response `200``application/json` 8 fields Created. | Field | Type | Description | | --- | --- | --- | | `job_id`required | `string (ulid)` | Identifier of the job | | `job_status`required | `string` | The status of the job`COMPLETED``FAILED``IN_PROGRESS` | | `failure_reason` | `string` | The reason of a failing for jobs with status FAILED | | `ruleset_name`required | `string` | Ruleset nameExample `Some Ruleset` | | `transaction_id`required | `string (ulid)` | Transaction ID | | `input`required | `object` | Data for the processing | | `data_objects` | `object[]` | The array of data objects that need to be processed | | `data`required | `object` | The data in staircase v2 format | | `collections` | `object[]` | The array of collection IDs that need to be processed | | `transaction_id`required | `string (ulid)` | Transaction ID | | `collection_id`required | `string (ulid)` | Collection ID | | `callback_url` | `string (uri)` | The URL which is used to send the result of the job | | `output`required | `object` | The data from rules applying | | `data` | `object` | Raw result data | | `metadata` | `object` | Metadata about output data | | `status` | `string` | Status of the data validity`HAS_VALIDATION_ERRORS` | | `status_message` | `string` | Status description | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `GET` `/send-envelop` #### Get Ruleset Invocation Status `getRulesetInvocationStatus` Returns the status of invoking Ruleset associated with the input collection(s) and output collection. ##### Response application/json Copy Created. ``` { "job_id": "01FM2G606MNKG8YKD62EB64DDR" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string` path | `01FJC4JGKFX3VYB0EZ75JNY4J6` | Identifier of the data processing job. | ##### Response `200``application/json` 1 fields Created. | Field | Type | Description | | --- | --- | --- | | `job_id`required | `string (ulid)` | Identifier of the job | ### Rulesets `GET` `/rulesets` #### Get Rulesets `getRulesets` Get Rulesets returns a list of all the Rulesets. ##### Response application/json Copy OK. ``` { "count": 2, "rulesets": [ { "name": "selective_merge", "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE" }, { "name": "aus_relationships", "description": "The ruleset for setting relationships between entities in v2 to the separated object to be able to map it to v0.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ] } ``` ##### Response `200``application/json` 2 fields OK. | Field | Type | Description | | --- | --- | --- | | `count`required | `integer` | The number of returned rulesets | | `rulesets`required | `object[]` | Rulesets list | | `ruleset` | `object` | Ruleset. | | `name`required | `string` | Ruleset nameExample `Some Ruleset` | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation`required | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | | `_links` | `object` | Links to endpoints related to the ruleset | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | `GET` `/rulesets/{ruleset_name}` #### Get Ruleset `getRuleset` Get Ruleset returns the Ruleset information. ##### Response 200 Selective Merge Ruleset200 Data Inferring Ruleset400 application/json Copy OK. ``` { "name": "selective_merge", "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ] } ``` application/json Copy OK. ``` { "name": "validation_ruleset", "description": "The ruleset for validating if date of document is 2021 year.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | ##### Response `200``application/json` 2 fields OK. | Field | Type | Description | | --- | --- | --- | | `ruleset` | `object` | Ruleset. | | `name`required | `string` | Ruleset nameExample `Some Ruleset` | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation`required | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | | `_links` | `object` | Links to endpoints related to the ruleset | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `POST` `/rulesets` #### Create Ruleset `createRuleset` Creates Ruleset enable creation of Ruleset with the below attributes: - name: Name of the Ruleset. - description: Description of the Ruleset. - operation: Type of the operation that will be executed when Invoking the Ruleset, supported operations: - SELECTIVE_DATA_MERGE: merge collections in a new collection. - Input: Staircase Collection(s). - Process: Create new collection by running the ruleset on the input collections. - Output: A new collection generated from running the ruleset. - DATA_INFERRING: modify existing collection. - Input: Staircase Collection. - Process: Modify the collection by running the Ruleset. - Output: Modified collection. ##### Request Selective Merge RulesetData Inferring Ruleset application/json Copy ``` { "name": "selective_merge", "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ] } ``` application/json Copy ``` { "name": "validation_ruleset", "description": "The ruleset for validating if date of document is 2021 year.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ``` ##### Response 201 Selective Merge Ruleset201 Data Inferring Ruleset400 application/json Copy Created. ``` { "name": "selective_merge", "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ] } ``` application/json Copy Created. ``` { "name": "validation_ruleset", "description": "The ruleset for validating if date of document is 2021 year.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Ruleset nameExample `Some Ruleset` | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation`required | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | ##### Response `201``application/json` 4 fields Created. | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Ruleset nameExample `Some Ruleset` | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation`required | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `409``application/json` 1 fields Resource already exists. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `PATCH` `/rulesets/{ruleset_name}` #### Update Ruleset `updateRuleset` Update Ruleset updates specific Ruleset, method shall update: - Description; - Operation; - Global RDF Prefixes. ##### Request Selective Merge RulesetData Inferring Ruleset application/json Copy ``` { "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ] } ``` application/json Copy ``` { "description": "The ruleset for validating if date of document is 2021 year.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ``` ##### Response 200 Selective Merge Ruleset200 Data Inferring Ruleset400 application/json Copy OK. ``` { "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ] } ``` application/json Copy OK. ``` { "description": "The ruleset for validating if date of document is 2021 year.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation` | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | ##### Response `200``application/json` 3 fields OK. | Field | Type | Description | | --- | --- | --- | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation` | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `DELETE` `/rulesets/{ruleset_name}` #### Delete Ruleset `deleteRuleset` Delete Ruleset deletes a specific Ruleset. ##### Response 200 Selective Merge Ruleset200 Data Inferring Ruleset400 application/json Copy OK. ``` { "name": "selective_merge", "description": "The ruleset for smart selecting data.", "operation": "SELECTIVE_DATA_MERGE", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ] } ``` application/json Copy OK. ``` { "name": "validation_ruleset", "description": "The ruleset for validating if date of document is 2021 year.", "global_rdf_prefixes": [ { "prefix": "rdf", "IRI": "http://www.w3.org/1999/02/22-rdf-syntax-ns#" }, { "prefix": "", "IRI": "https://www.staircase.co/ontology/" }, { "prefix": "reserved", "IRI": "https://www.staircase.co/reserved/" } ], "operation": "DATA_INFERRING" } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | ##### Response `200``application/json` 4 fields OK. | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Ruleset nameExample `Some Ruleset` | | `description` | `string` | Ruleset descriptionExample `This ruleset can be used to select data from different collections.` | | `operation`required | `string` | The purpose of the ruleset usage`DATA_INFERRING``SELECTIVE_DATA_MERGE` | | `global_rdf_prefixes` | `object[]` | Array of RDF prefixes | | `prefix` | `string` | Prefix that can be used in rules definitions | | `IRI` | `string` | IRI that will be used instead of prefix in rules definitions | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` ### Rules `GET` `/rulesets/{ruleset_name}/rules` #### Get Rules `getRules` Get Rules Return all the rules associated with a Ruleset. If Rules count > 200, response body will contain pagination link(s). ##### Response 200 Selective Merge Rules200 Data Inferring Rules (Validation)400 application/json Copy OK. ``` { "count": 2, "rules": [ { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :documents ?document .\n ?document ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MIN(?document_date_value) as ?earliest_date_value)\n WHERE\n {\n ?document :has_document_date / :has_value ?document_date_value .\n }\n }\n ?document :has_document_date / :has_value ?earliest_date_value .\n ?document ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } }, { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :loan_terms ?loan_term .\n ?loan_term ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MAX(?payment_amount_value) as ?max_payment_amount_value)\n WHERE\n {\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?payment_amount_value .\n }\n }\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?max_payment_amount_value .\n ?loan_term ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ] } ``` application/json Copy OK. ``` { "count": 4, "rules": [ { "id": "PERCENT_IS_INTEGER_CONVERTABLE", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_DATA_FORMAT\" ;\n :has_validation_description \"Value is not integer.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n FILTER NOT EXISTS\n {\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value))\n }\n}\n" } }, { "id": "NOT_LATER_THAN_TODAY", "definition": { "raw_sparql": "INSERT\n{\n\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Date is later than date of rule applying date.\"\n ]\n}\nWHERE\n{\n [] :documents / :has_document_date ?target_node .\n ?target_node :has_value ?document_date_value .\n BIND (NOW() as ?now)\n FILTER(\n ?document_date_value > CONCAT(\n STR(YEAR(?now)), \"-\", STR(MONTH(?now)), \"-\", STR(DAY(?now))\n )\n )\n}\n" } }, { "id": "LOAN_AMORTIZATION_TYPE_IS_MISSING", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 404 ;\n :has_validation_code_type \"MISSING_DATA\" ;\n :has_validation_description \"Data is missing.\"\n ]\n}\nWHERE\n{\n [] :loan_terms / :has_loan_amortization_type ?target_node .\n FILTER NOT EXISTS { ?target_node :has_value ?value }\n}\n" } }, { "id": "PERCENT_IS_GREATER_THAN_100", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Value is greater than 100.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value) > 100)\n}\n" } } ] } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | | `sort` | `string` query | `asc` | Sorting direction | | `after_id` | `string` query | `a0533c96-937e-42cg-83b8-b63efe3cac8a` | Pagination marker. ID of the last rule from previous response. | ##### Response `200``application/json` 3 fields OK. | Field | Type | Description | | --- | --- | --- | | `count`required | `integer` | The number of returned rules | | `_links`required | `object` | Pagination links | | `next` | `string` | Next page | | `previous` | `string` | Previous page | | `rules`required | `array` | Rules list | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `GET` `/rulesets/{ruleset_name}/rules/{rule_id}` #### Get Rule `getRule` Get Rule returns a specific Rule by ID and associated Ruleset name. ##### Response 200 Selective Merge Rule 1200 Selective Merge Rule 2200 Constructing Entity Rule200 Data Validation Rule 1200 Data Validation Rule 2200 Data Validation Rule 3200 Data Validation Rule 4400 application/json Copy OK. ``` { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :documents ?document .\n ?document ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MIN(?document_date_value) as ?earliest_date_value)\n WHERE\n {\n ?document :has_document_date / :has_value ?document_date_value .\n }\n }\n ?document :has_document_date / :has_value ?earliest_date_value .\n ?document ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ``` application/json Copy OK. ``` { "id": "loan_terms_selection_rule", "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :loan_terms ?loan_term .\n ?loan_term ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MAX(?payment_amount_value) as ?max_payment_amount_value)\n WHERE\n {\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?payment_amount_value .\n }\n }\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?max_payment_amount_value .\n ?loan_term ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ``` application/json Copy OK. ``` { "definition": { "raw_sparql": "PREFIX: \nPREFIX rdf: \nPREFIX reserved: \n\nCONSTRUCT\n{\n reserved:root :documents [\n :has_document_date [\n :has_value ?document_date_value ;\n :has_data_extraction_confidence_score ?max_document_date_confidence_score\n ] ;\n :has_document_misclassified_indicator [\n :has_value ?document_misclassified_indicator_value ;\n :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score\n ]\n ]\n}\nWHERE\n{\n # GET DOCUMENT DATE DATA BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score) as ?max_document_date_confidence_score)\n WHERE\n {\n ?any_document :has_document_date / :has_data_extraction_confidence_score ?confidence_score .\n }\n }\n ?any_document :has_document_date ?end_node .\n ?end_node :has_data_extraction_confidence_score ?max_document_date_confidence_score .\n ?end_node :has_value ?document_date_value .\n\n\n # GET MISCLASSIFIED INDICATOR BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score_2) as ?max_document_misclassified_indicator_confidence_score)\n WHERE\n {\n ?any_document_2 :has_document_misclassified_indicator / :has_data_extraction_confidence_score ?confidence_score_2 .\n }\n }\n ?any_document_2 :has_document_misclassified_indicator ?end_node_2 .\n ?end_node_2 :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score .\n ?end_node_2 :has_value ?document_misclassified_indicator_value .\n}\n" } } ``` application/json Copy OK. ``` { "id": "PERCENT_IS_INTEGER_CONVERTABLE", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_DATA_FORMAT\" ;\n :has_validation_description \"Value is not integer.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n FILTER NOT EXISTS\n {\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value))\n }\n}\n" } } ``` application/json Copy OK. ``` { "id": "NOT_LATER_THAN_TODAY", "definition": { "raw_sparql": "INSERT\n{\n\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Date is later than date of rule applying date.\"\n ]\n}\nWHERE\n{\n [] :documents / :has_document_date ?target_node .\n ?target_node :has_value ?document_date_value .\n BIND (NOW() as ?now)\n FILTER(\n ?document_date_value > CONCAT(\n STR(YEAR(?now)), \"-\", STR(MONTH(?now)), \"-\", STR(DAY(?now))\n )\n )\n}\n" } } ``` application/json Copy OK. ``` { "id": "LOAN_AMORTIZATION_TYPE_IS_MISSING", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 404 ;\n :has_validation_code_type \"MISSING_DATA\" ;\n :has_validation_description \"Data is missing.\"\n ]\n}\nWHERE\n{\n [] :loan_terms / :has_loan_amortization_type ?target_node .\n FILTER NOT EXISTS { ?target_node :has_value ?value }\n}\n" } } ``` application/json Copy OK. ``` { "id": "PERCENT_IS_GREATER_THAN_100", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Value is greater than 100.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value) > 100)\n}\n" } } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | | `rule_id` required | `string` path | `my_rule` | Rule id (name) | ##### Response `200``application/json` 4 fields OK. | Field | Type | Description | | --- | --- | --- | | `id` | `string` | Rule ID. Can be specified to identify it later. Otherwise, it will be set automatically. | | `description` | `string` | Description of rule. | | `local_rdf_prefixes` | `object[]` | Array of RDF prefixes. | | `prefix`required | `string` | Prefix that can be used in rule definition. | | `IRI`required | `string` | IRI that will be used instead of prefix in rule definition. | | `definition`required | `object` | Definition of rule. | | `raw_sparql`required | `string` | Raw SPARQL query (or insert) expression. | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `POST` `/rulesets/{ruleset_name}/rules` #### Create Or Update Rules `createOrUpdateRules` Create or Update Rules Create Or Update Rules enables creating or updating multiple Rules using the same request. The endpoint shall check the pre-existence of Rule by ID. If the id doesn't exist, the rule will be created. ##### Request Selective Merge RulesConstructing Entity RulesData Validation Rules application/json Copy ``` { "rules": [ { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :documents ?document .\n ?document ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MIN(?document_date_value) as ?earliest_date_value)\n WHERE\n {\n ?document :has_document_date / :has_value ?document_date_value .\n }\n }\n ?document :has_document_date / :has_value ?earliest_date_value .\n ?document ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } }, { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :loan_terms ?loan_term .\n ?loan_term ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MAX(?payment_amount_value) as ?max_payment_amount_value)\n WHERE\n {\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?payment_amount_value .\n }\n }\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?max_payment_amount_value .\n ?loan_term ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ] } ``` application/json Copy ``` { "rules": [ { "definition": { "raw_sparql": "PREFIX: \nPREFIX rdf: \nPREFIX reserved: \n\nCONSTRUCT\n{\n reserved:root :documents [\n :has_document_date [\n :has_value ?document_date_value ;\n :has_data_extraction_confidence_score ?max_document_date_confidence_score\n ] ;\n :has_document_misclassified_indicator [\n :has_value ?document_misclassified_indicator_value ;\n :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score\n ]\n ]\n}\nWHERE\n{\n # GET DOCUMENT DATE DATA BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score) as ?max_document_date_confidence_score)\n WHERE\n {\n ?any_document :has_document_date / :has_data_extraction_confidence_score ?confidence_score .\n }\n }\n ?any_document :has_document_date ?end_node .\n ?end_node :has_data_extraction_confidence_score ?max_document_date_confidence_score .\n ?end_node :has_value ?document_date_value .\n\n\n # GET MISCLASSIFIED INDICATOR BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score_2) as ?max_document_misclassified_indicator_confidence_score)\n WHERE\n {\n ?any_document_2 :has_document_misclassified_indicator / :has_data_extraction_confidence_score ?confidence_score_2 .\n }\n }\n ?any_document_2 :has_document_misclassified_indicator ?end_node_2 .\n ?end_node_2 :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score .\n ?end_node_2 :has_value ?document_misclassified_indicator_value .\n}\n" } } ] } ``` application/json Copy ``` { "rules": [ { "id": "PERCENT_IS_INTEGER_CONVERTABLE", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_DATA_FORMAT\" ;\n :has_validation_description \"Value is not integer.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n FILTER NOT EXISTS\n {\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value))\n }\n}\n" } }, { "id": "NOT_LATER_THAN_TODAY", "definition": { "raw_sparql": "INSERT\n{\n\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Date is later than date of rule applying date.\"\n ]\n}\nWHERE\n{\n [] :documents / :has_document_date ?target_node .\n ?target_node :has_value ?document_date_value .\n BIND (NOW() as ?now)\n FILTER(\n ?document_date_value > CONCAT(\n STR(YEAR(?now)), \"-\", STR(MONTH(?now)), \"-\", STR(DAY(?now))\n )\n )\n}\n" } }, { "id": "LOAN_AMORTIZATION_TYPE_IS_MISSING", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 404 ;\n :has_validation_code_type \"MISSING_DATA\" ;\n :has_validation_description \"Data is missing.\"\n ]\n}\nWHERE\n{\n [] :loan_terms / :has_loan_amortization_type ?target_node .\n FILTER NOT EXISTS { ?target_node :has_value ?value }\n}\n" } }, { "id": "PERCENT_IS_GREATER_THAN_100", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Value is greater than 100.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value) > 100)\n}\n" } } ] } ``` ##### Response 200 Selective Merge Rules200 Constructing Entity Rules200 Data Validation Rules400 application/json Copy OK. Created or updated. ``` { "rules": [ { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :documents ?document .\n ?document ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MIN(?document_date_value) as ?earliest_date_value)\n WHERE\n {\n ?document :has_document_date / :has_value ?document_date_value .\n }\n }\n ?document :has_document_date / :has_value ?earliest_date_value .\n ?document ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } }, { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :loan_terms ?loan_term .\n ?loan_term ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MAX(?payment_amount_value) as ?max_payment_amount_value)\n WHERE\n {\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?payment_amount_value .\n }\n }\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?max_payment_amount_value .\n ?loan_term ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ] } ``` application/json Copy OK. Created or updated. ``` { "rules": [ { "definition": { "raw_sparql": "PREFIX: \nPREFIX rdf: \nPREFIX reserved: \n\nCONSTRUCT\n{\n reserved:root :documents [\n :has_document_date [\n :has_value ?document_date_value ;\n :has_data_extraction_confidence_score ?max_document_date_confidence_score\n ] ;\n :has_document_misclassified_indicator [\n :has_value ?document_misclassified_indicator_value ;\n :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score\n ]\n ]\n}\nWHERE\n{\n # GET DOCUMENT DATE DATA BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score) as ?max_document_date_confidence_score)\n WHERE\n {\n ?any_document :has_document_date / :has_data_extraction_confidence_score ?confidence_score .\n }\n }\n ?any_document :has_document_date ?end_node .\n ?end_node :has_data_extraction_confidence_score ?max_document_date_confidence_score .\n ?end_node :has_value ?document_date_value .\n\n\n # GET MISCLASSIFIED INDICATOR BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score_2) as ?max_document_misclassified_indicator_confidence_score)\n WHERE\n {\n ?any_document_2 :has_document_misclassified_indicator / :has_data_extraction_confidence_score ?confidence_score_2 .\n }\n }\n ?any_document_2 :has_document_misclassified_indicator ?end_node_2 .\n ?end_node_2 :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score .\n ?end_node_2 :has_value ?document_misclassified_indicator_value .\n}\n" } } ] } ``` application/json Copy OK. Created or updated. ``` { "rules": [ { "id": "PERCENT_IS_INTEGER_CONVERTABLE", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_DATA_FORMAT\" ;\n :has_validation_description \"Value is not integer.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n FILTER NOT EXISTS\n {\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value))\n }\n}\n" } }, { "id": "NOT_LATER_THAN_TODAY", "definition": { "raw_sparql": "INSERT\n{\n\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Date is later than date of rule applying date.\"\n ]\n}\nWHERE\n{\n [] :documents / :has_document_date ?target_node .\n ?target_node :has_value ?document_date_value .\n BIND (NOW() as ?now)\n FILTER(\n ?document_date_value > CONCAT(\n STR(YEAR(?now)), \"-\", STR(MONTH(?now)), \"-\", STR(DAY(?now))\n )\n )\n}\n" } }, { "id": "LOAN_AMORTIZATION_TYPE_IS_MISSING", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 404 ;\n :has_validation_code_type \"MISSING_DATA\" ;\n :has_validation_description \"Data is missing.\"\n ]\n}\nWHERE\n{\n [] :loan_terms / :has_loan_amortization_type ?target_node .\n FILTER NOT EXISTS { ?target_node :has_value ?value }\n}\n" } }, { "id": "PERCENT_IS_GREATER_THAN_100", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Value is greater than 100.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value) > 100)\n}\n" } } ] } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `rules`required | `array` | Rules list | ##### Response `200``application/json` 1 fields OK. Created or updated. | Field | Type | Description | | --- | --- | --- | | `rules`required | `array` | Rules list | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `409``application/json` 1 fields Resource already exists. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` `DELETE` `/rulesets/{ruleset_name}/rules/{rule_id}` #### Delete Rule `deleteRule` Delete Rules Delete Rule deletes a specific Rule using Rule ID and Ruleset name. ##### Response 200 Selective Merge Rule 1200 Selective Merge Rule 2200 Constructing Entity Rule200 Data Validation Rule 1200 Data Validation Rule 2200 Data Validation Rule 3200 Data Validation Rule 4400 application/json Copy Deleted. ``` { "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :documents ?document .\n ?document ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MIN(?document_date_value) as ?earliest_date_value)\n WHERE\n {\n ?document :has_document_date / :has_value ?document_date_value .\n }\n }\n ?document :has_document_date / :has_value ?earliest_date_value .\n ?document ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ``` application/json Copy Deleted. ``` { "id": "loan_terms_selection_rule", "definition": { "raw_sparql": "CONSTRUCT\n{\n reserved:root :loan_terms ?loan_term .\n ?loan_term ?p ?o .\n ?o ?po ?oo .\n}\nWHERE\n{\n {\n SELECT (MAX(?payment_amount_value) as ?max_payment_amount_value)\n WHERE\n {\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?payment_amount_value .\n }\n }\n ?loan_term :has_initial_principal_and_interest_payment_amount / :has_value ?max_payment_amount_value .\n ?loan_term ?p ?o .\n OPTIONAL { ?o ?po ?oo . }\n}\n" } } ``` application/json Copy Deleted. ``` { "definition": { "raw_sparql": "PREFIX: \nPREFIX rdf: \nPREFIX reserved: \n\nCONSTRUCT\n{\n reserved:root :documents [\n :has_document_date [\n :has_value ?document_date_value ;\n :has_data_extraction_confidence_score ?max_document_date_confidence_score\n ] ;\n :has_document_misclassified_indicator [\n :has_value ?document_misclassified_indicator_value ;\n :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score\n ]\n ]\n}\nWHERE\n{\n # GET DOCUMENT DATE DATA BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score) as ?max_document_date_confidence_score)\n WHERE\n {\n ?any_document :has_document_date / :has_data_extraction_confidence_score ?confidence_score .\n }\n }\n ?any_document :has_document_date ?end_node .\n ?end_node :has_data_extraction_confidence_score ?max_document_date_confidence_score .\n ?end_node :has_value ?document_date_value .\n\n\n # GET MISCLASSIFIED INDICATOR BY MAX CONFIDENCE SCORE\n {\n SELECT (MAX(?confidence_score_2) as ?max_document_misclassified_indicator_confidence_score)\n WHERE\n {\n ?any_document_2 :has_document_misclassified_indicator / :has_data_extraction_confidence_score ?confidence_score_2 .\n }\n }\n ?any_document_2 :has_document_misclassified_indicator ?end_node_2 .\n ?end_node_2 :has_data_extraction_confidence_score ?max_document_misclassified_indicator_confidence_score .\n ?end_node_2 :has_value ?document_misclassified_indicator_value .\n}\n" } } ``` application/json Copy Deleted. ``` { "id": "PERCENT_IS_INTEGER_CONVERTABLE", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_DATA_FORMAT\" ;\n :has_validation_description \"Value is not integer.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n FILTER NOT EXISTS\n {\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value))\n }\n}\n" } } ``` application/json Copy Deleted. ``` { "id": "NOT_LATER_THAN_TODAY", "definition": { "raw_sparql": "INSERT\n{\n\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Date is later than date of rule applying date.\"\n ]\n}\nWHERE\n{\n [] :documents / :has_document_date ?target_node .\n ?target_node :has_value ?document_date_value .\n BIND (NOW() as ?now)\n FILTER(\n ?document_date_value > CONCAT(\n STR(YEAR(?now)), \"-\", STR(MONTH(?now)), \"-\", STR(DAY(?now))\n )\n )\n}\n" } } ``` application/json Copy Deleted. ``` { "id": "LOAN_AMORTIZATION_TYPE_IS_MISSING", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 404 ;\n :has_validation_code_type \"MISSING_DATA\" ;\n :has_validation_description \"Data is missing.\"\n ]\n}\nWHERE\n{\n [] :loan_terms / :has_loan_amortization_type ?target_node .\n FILTER NOT EXISTS { ?target_node :has_value ?value }\n}\n" } } ``` application/json Copy Deleted. ``` { "id": "PERCENT_IS_GREATER_THAN_100", "definition": { "raw_sparql": "INSERT\n{\n ?target_node :with_data_validation_metadata [\n rdf:type :data_validation_metadata ;\n :has_validation_code 400 ;\n :has_validation_code_type \"INVALID_BUSINESS_SENSE\" ;\n :has_validation_description \"Value is greater than 100.\"\n ]\n}\nWHERE\n{\n [] :payments / :has_late_charge_rate_percent ?target_node .\n ?target_node :has_value ?value .\n FILTER (xsd:integer(?value) > 100)\n}\n" } } ``` text/html Copy Bad request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ruleset_name` required | `string` path | `my_ruleset` | Ruleset name | | `rule_id` required | `string` path | `my_rule` | Rule id (name) | ##### Response `200``application/json` 4 fields Deleted. | Field | Type | Description | | --- | --- | --- | | `id` | `string` | Rule ID. Can be specified to identify it later. Otherwise, it will be set automatically. | | `description` | `string` | Description of rule. | | `local_rdf_prefixes` | `object[]` | Array of RDF prefixes. | | `prefix`required | `string` | Prefix that can be used in rule definition. | | `IRI`required | `string` | IRI that will be used instead of prefix in rule definition. | | `definition`required | `object` | Definition of rule. | | `raw_sparql`required | `string` | Raw SPARQL query (or insert) expression. | ##### Response `403``application/json` 1 fields Forbidden. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Other responses `400` ### Operations `POST` `/rule-engine` #### Create Rule Engine `post-rule-engine` Create Rule Engine creates views of products, risk factors and other business intelligence that have been evaluated by a set of rules affecting the decisioning process. ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Rule Engine request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Rule Engine request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ## Errors `400``403``404``409``422` ## More in Data - Previous product: Persistence - Next product: Site --- # Site # Site The documentation platform, run as a product: ontology-driven navigation, per-product pages, content management and glossary enforcement. Site generated developer documentation from the ontology rather than from hand-written navigation. Families, categories and products produced the sidebar; each product carried an overview and a quickstart; component ordering was configuration. Content came from a managed store, and terminology was checked against a glossary at authoring time, so the same term meant the same thing across products. ## How it works Navigation generated from the ontology cannot drift from it. A product added to the catalogue appeared; one removed disappeared. A hand-maintained sidebar fails silently and keeps looking correct. ## Operations ### Advertisement[new] `POST` `/advertisers` #### Register Advertiser `registerAdvertiser` This endpoint registers the Advertiser. #### Redirect URL `redirect_url` is used to redirect the user to specified location upon interaction with the advertiser's ad. #### Advertiser Language Here user has to specify earlier registered language with predefined rule sets that allow translation of advertising data to Staircase lexicon. Please refer to Language documentation. ##### Request application/json Copy ``` { "advertiser_id": "e0e44570-6666-0001-000a-000a00aa0a0a", "advertiser_name": "cordless_media", "redirect_url": "https://staircase.co/", "advertiser_language": "cordless-media-language" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `advertiser_id`required | `string` | Advertiser Name | | `advertiser_name`required | `string` | Advertiser Name | | `redirect_url`required | `string (uri)` | URL to which user is redirected upon interaction with ad | | `advertiser_language`required | `string` | Language of the Advertisers that has registered rule sets allowing translation to Staircase lexicon | ##### Response `201``application/json` 1 fields Advertiser Registered | Field | Type | Description | | --- | --- | --- | | `advertiser_id` | `string` | Advertiser ID | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Other responses `403` `GET` `/advertisers` #### List Advertisers `listAdvertisers` Retrieves and lists all registered Advertisers. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | Used for pagination purposes | ##### Response `200``application/json` 1 fields Advertisers Retrieved | Field | Type | Description | | --- | --- | --- | | `advertisers` | `array` | Array of Advertisers | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Other responses `403` `DELETE` `/advertisers/{advertiser_id}` #### Delete Advertiser `deleteAdvertiser` Deletes Advertiser referenced by `advertiser_id`. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `advertiser_id` required | `string` path | `advertiser_id` | Advertiser ID referencing a registered advertiser | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Other responses `204``403` `GET` `/advertisers/{advertiser_id}/advertising_data` #### Redirect From Advertiser `persistAdvertisingData` This endpoint accepts advertising data and persists it in the Staircase Persistence product. A Transaction with a specific label is created, to which a Collection containing the advertising data is being attached. #### Input Data The advertising data is accepted through the query parameters of this endpoint. #### Data Formatting The provided advertising data is updated to contain the Advertiser information that can be queried on later. #### Open Endpoint This endpoint does not require `x-api-key` header. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `advertiser_id` required | `string` path | `advertiser_id` | Advertiser ID referencing a registered advertiser | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Other responses `302``403` `POST` `/advertisers/{advertiser_id}/advertising_data/transactions/{transaction_id}` #### Persist Advertiser Data[new] `persistAdvertisingDataDirect` Persist Advertiser Data This endpoint accepts advertising data and persists it in the Staircase Persistence product. A Transaction with a specific label is provided by the user. An additional Collection, containing the advertising data is being attached. #### Input Data The advertising data is accepted through the payload in the body of the request. Request body is required to be a valid JSON object, and must be present. #### Data Formatting The provided advertising data is updated to contain the Advertiser information that can be queried on later. ##### Request application/json Copy ``` { "campaign_identifier": "campaign_identifier", "keyword_match_type": "exact" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `advertiser_id` required | `string` path | `advertiser_id` | Advertiser ID referencing a registered advertiser | | `transaction_id` required | `string` path | `transaction_id` | Transaction ID | ##### Response `202``application/json` 1 fields Advertising data has been persisted | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction IDExample `01H7B8YQYCWRGNHXF8GY5CSZNM` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Error. | | `message` | `string` | Error message. | ##### Other responses `403` ### Traffic Control[new] `POST` `/configurations` #### Create Traffic Configuration[new] `createTrafficConfiguration` Create Traffic Configuration This endpoint creates a traffic split configuration by exposing interface for user to define weighted distribution of users hitting the configuration among different sites. Since traffic statistics is collected, an initial revision of the configuration is created and attached to it. Any following updates to the configuration will create a new revision and point such to it to logically separate the incoming traffic statistics based on the ratios in the current revision. #### Warning Sum of ratios given for each url should make up to 1. ##### Request application/json Copy ``` { "sites_settings": [ { "url": "https://google.com", "ratio": 0.8 }, { "url": "https://bing.com", "ratio": 0.2 } ] } ``` ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `sites_settings`required | `object[]` | Array of sites with their settings. | | `url`required | `string (uri)` | Url of site to which redirection will occur. | | `ratio`required | `number (float)` | Ratio weight of the provided url with respect to other sites. | ##### Response `201``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `traffic_configuration_id` | `string` | Idenfitier of the configuration created. | ##### Other responses `422` `GET` `/configurations` #### List Traffic Configurations[new] `listTrafficConfigurations` List Traffic Configurations Lists all created traffic configurations. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | The response can include a limited number of results along with a `next_token` value. You can use this `next_token` value in a subsequent API request to retrieve the next batch of items. `next_token` is located under the `page` object in the response. | | `limit` | `integer` query | `10` | Items limit | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `traffic_configurations` | `array` | Configurations list | ##### Other responses `422` `GET` `/configurations/{traffic_configuration_id}` #### Retrieve Traffic Configuration[new] `retrieveTrafficConfiguration` Retrieve Traffic Configuration Retrieve traffic configuration with the latest revision information. User can specify a different revision of the same configuration to be displayed via query parameters. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `traffic_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Traffic Configuration ID | | `revision_id` | `string` query | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Revision ID of the configuration to display | ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `traffic_configuration_id` | `string (uuid)` | Configuration ID | | `revision_id` | `string` | Revision ID | | `sites_settings` | `object[]` | Array of sites with their settings. | | `url`required | `string (uri)` | Url of site to which redirection will occur. | | `ratio`required | `number (float)` | Ratio weight of the provided url with respect to other sites. | | `traffic_stats` | `object[]` | Array of sites with their statistics. | | `url`required | `string (uri)` | Site url | | `hits`required | `integer` | Number of redirects to this site | ##### Other responses `422` `PUT` `/configurations/{traffic_configuration_id}` #### Update Traffic Configuration[new] `updateTrafficConfiguration` Update Traffic Configuration Updates provided traffic configuration with new site settings. Creates a separate revision and points the configuration to it. ##### Request application/json Copy ``` { "sites_settings": [ { "url": "https://google.com", "ratio": 0.8 }, { "url": "https://bing.com", "ratio": 0.2 } ] } ``` ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `traffic_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Traffic Configuration ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `sites_settings`required | `object[]` | Array of sites with their settings. | | `url`required | `string (uri)` | Url of site to which redirection will occur. | | `ratio`required | `number (float)` | Ratio weight of the provided url with respect to other sites. | ##### Other responses `204``422` `GET` `/configurations/{traffic_configuration_id}/revisions` #### Retrieve Configuration Revisions[new] `retrieveConfigurationRevisions` Retrieve Configuration Revisions Retrieves all revisions information for the provided traffic configuration. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `traffic_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Traffic Configuration ID | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | The response can include a limited number of results along with a `next_token` value. You can use this `next_token` value in a subsequent API request to retrieve the next batch of items. `next_token` is located under the `page` object in the response. | | `limit` | `integer` query | `10` | Items limit | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | | `revisions`required | `array` | Revisions list | ##### Other responses `422` `GET` `/configurations/{traffic_configuration_id}/url` #### Split Traffic[new] `splitTraffic` Split Traffic This endpoint redirects the user to one of the urls defined in the traffic configuration provided in path with the choice being made based on the ratios provided. The latest revision of the configuration is used to determine configuration parameters. #### Query Parameters Query parameters passed to this endpoint are preserved and appended to the url selected from the configuration. #### Notes on Implementation Target url is selected using weighted random selection algorithm, which tends to get more accurate in user distribution with the increasing sample size. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `traffic_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Traffic Configuration ID | ##### Other responses `302``422` ### Documentation `POST` `/documentation` #### Publish product definition `publishDocumentation` Publish an API definition to an environment. API definitions describe service inputs, outputs, error codes and example request / responses. Documentation can be published from source artifact which passed Assessment or using bundle from Marketplace. Also, direct URL to swagger file can be used for publishing. In this case swagger file URL should return content with 200 response. ##### Request ArtifactExampleSwaggerExample application/json Copy ``` { "artifact_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } ``` application/json Copy ``` { "swagger_url": "https://documentation.staircaseapi.com/swagger.yml" } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `201``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `publish_id` | `string` | Publish ID corresponding to the publish process.Example `e0f01bac-8a0b-4a61-9e0a-180f28106f7f` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `POST` `/ontology` #### Publish products ontology `publishOntology` Publish products ontology. It will be used to show ordered product families, categories, and products in the navigation bar. When ontology contains not published product, then it will not be shown in the navigation bar. When ontology does not have a product, it will be shown at the end of the list. ##### Request application/json Copy ``` { "DevOps": { "Ship": [ "Build", "Deploy" ], "Distribute": [ "Marketplace", "Environment", "Documentation" ] } } ``` ##### Response 200400 application/json Copy Success response ``` { "DevOps": { "Ship": [ "Build", "Deploy" ], "Distribute": [ "Marketplace", "Environment", "Documentation" ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``403` `GET` `/documentation/{publish_id}` #### Retrieve publish status `getPublishStatus` Retrieve the status of a given publish_id. Status is SUCCEEDED, FAILED or IN PROGRESS. ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `publish_id` required | `string` path | `45cc7cea-4626-40b2-b237-01799d037cg2` | Publish id of returned by the publish documentation endpoint. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `200``application/json` 2 fields Success response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the publish process.`FAILED``FAULT``IN_PROGRESS``IN_REVIEW``REJECTED``STOPPED``SUCCEEDED``TIMED_OUT`Example `IN_PROGRESS` | | `status_msg` | `string` | Message with details about the publish process status.Example `The bundle review process is starting.` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/ontology` #### Retrieve products ontology `getOntology` Retrieve products ontology. ##### Response 200400 application/json Copy Success response ``` { "DevOps": { "Ship": [ "Build", "Deploy" ], "Distribute": [ "Marketplace", "Environment", "Documentation" ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``403` `GET` `/content/{product_name}/try-it-data/{openapi_path}` #### Get Try It data `getTryItData` Retrieve the data for try it functionality. Also, it contains examples of request body. ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | | `openapi_path` required | `string` path | `publishDocumentation` | Path which was specified as 'operationId' in api method definition in product swagger file. | ##### Response `200``application/json` 5 fields Success response | Field | Type | Description | | --- | --- | --- | | `method` | `string` | API method type.`DELETE``GET``PATCH``POST``PUT` | | `path` | `string` | API method path.Example `/transactions/{transaction_id}/collections` | | `url` | `string` | URL of service.Example `https://documentation-test.staircaseapi.com/employment` | | `body_examples` | `object[]` | Body payload examples. | | `name` | `string` | Example name.Example `FullExample` | | `value` | `object` | Example value. | | `parameters` | `object` | Parameters definition. | | `header` | `object[]` | Header parameters. | | `name` | `string` | Parameter name.Example `x-api-key` | | `description` | `string` | Parameter description.Example `Environment api key.` | | `type` | `string` | Parameter type.Example `string` | | `example` | `string` | Parameter example.Example `3d54e011-9a17-4357-bf7a-10a854e4ae15` | | `default` | `string` | Parameter default value. | | `required` | `boolean` | Is parameter required.Example `true` | | `path` | `object[]` | Query parameters. | | `name` | `string` | Parameter name.Example `transaction_id` | | `description` | `string` | Parameter description.Example `Employment transaction id.` | | `type` | `string` | Parameter type.Example `string` | | `example` | `string` | Parameter example.Example `189ec86a-2b8d-41ed-bb0e-91b4a7fc0efc` | | `default` | `string` | Parameter default value. | | `required` | `boolean` | Is parameter required.Example `true` | | `query` | `object[]` | Path parameters. | | `name` | `string` | Parameter name.Example `returnResult` | | `description` | `string` | Parameter description.Example `Is need to return result in response.` | | `type` | `string` | Parameter type.Example `boolean` | | `example` | `string` | Parameter example.Example `true` | | `default` | `string` | Parameter default value.Example `false` | | `required` | `boolean` | Is parameter required.Example `false` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/sidebar` #### Get sidebar `getSideBar` Retrieve the sidebar data. ##### Response `200``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `products_side_bar` | `object` | List of products for sidebar. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/products` #### List all products `getProducts` Retrieve the list of published products. ##### Response application/json Copy Success response. ``` [ "Build", "Deploy", "Test" ] ``` ##### Response `200``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `products_published` | `string[]` | List of published products. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/{product_name}/guides` #### Get How To guide `getGuides` Get How To guide. ##### Response 200400 application/json Copy Success response ``` [ { "name": "How to build a service", "md_url": "https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/How to build a service.md", "html_url": "https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/How to build a service.html", "pdf_url": "https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/How to build a service.pdf" } ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Title.Example `How to build a service` | | `md_url` | `string` | URL to guide in MD format.Example `https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/How to build a service.md` | | `html_url` | `string` | URL to guide in HTML format.Example `https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/How to build a service.html` | | `pdf_url` | `string` | URL to guide in PDF format.Example `https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/How to build a service.pdf` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/{product_name}/static` #### Get static files `getStatic` Get product static files. ##### Response 200400 application/json Copy Success response ``` { "static_files": { "Employment.svg": "https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/Employment.svg", "Preview_Blue.svg": "https://content.template.staircaseapi.com/Employment/4c026275-00be-472a-a6a6-83a27970762a/public/Preview_Blue.svg" } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `static_files` | `object` | List of static files. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/{product_name}/overview` #### Get overview `getOverview` Get product overview HTML content. ##### Response 200400 application/json Copy Success response ``` { "overview": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `overview` | `string` | HTML content of overview page.Example `

` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/{product_name}/overview_embedded` #### Get overview embedded `getOverviewEmbedded` Get product overview embedded HTML content. ##### Response 200400 application/json Copy Success response ``` { "overview_embedded": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `overview_embedded` | `string` | HTML content of embedded overview page.Example `

` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `DELETE` `/content/{product_name}/openapi` #### Delete Open API definition `deleteOpenApi` Delete Open API definition. ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Builder` | Product name which was specified as 'x-product-name' in product swagger file. | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `GET` `/content/{product_name}/openapi` #### Get Open API definition `getOpenApi` Get Open API definition. ##### Response 200400 application/json Copy Success response ``` { "openapi_fields": { "openapi": "3.0.1", "x-explorer-enabled": true, "info": { "title": "Build", "x-product-category": "Ship", "x-product-family": "DevOps", "x-product-name": "Build", "version": "1.0.0" }, "servers": [ { "url": "https://documentation.staircaseapi.com/infra-builder" } ], "security": [ { "ApiKeyAuth": [] } ], "paths": { "/builds": { "post": { "x-product-component": "Product", "x-product-endpoint": "Build Product", "x-product-sequence": 1, "summary": "Create/Run service builder for services.", "description": "Build a deployable artifact for a product. The artifact must be provided via a URL. A callback will be sent to the URL specified in property.", "requestBody": { "description": "Run Specification", "content": { "application/json": { "schema": { "type": "object", "title": "Service Build Schema", "properties": { "bundle_id": { "type": "string", "format": "uuid", "description": "Usually a hash of the commit but can be any UUID." }, "source_url": { "type": "string", "description": "URL to source code.", "format": "uri" }, "callback_url": { "type": "string", "format": "uri", "default": "null", "description": "Callback URL where are you waiting for build status" } }, "required": [ "source_url" ], "example": { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } }, "example": { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } } } }, "responses": { "201": { "description": "Build created", "content": { "application/json": { "schema": { "type": "object", "properties": { "build_id": { "type": "string", "format": "uuid", "description": "Unique build_id which can be used for tracking build status. Usually it is a UUID." } }, "example": { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } }, "example": { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } } } } } } } } } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `openapi_fields` | `object` | Open API definition. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/{product_name}/openapi/paths` #### Get all Open API paths `getOpenApiPaths` Get all Open API path definitions. ##### Response 200400 application/json Copy Success response ``` { "openapi_paths": { "method": "get", "service_name": "Build", "base_path": "infra-builder", "env_domain": "template.staircaseapi.com", "path": "/builds/{build_id}", "sidebar_path": "/docs/DevOps/Ship/Build/get-build-status", "operation_id": null, "description": "**Retrieve Service Build Status**", "summary": "Get build status", "request_body": null, "responses": [ { "response_code": "200", "content": { "application/json": { "schema": { "type": "object", "properties": { "build_id": { "type": "string", "description": "Unique build id which was returned when build was started", "format": "uuid" }, "status": { "type": "string", "description": "Build status (IN_PROGRESS, FAILED, SUCCEEDED)" }, "artifacts_url": { "type": "string", "format": "url", "description": "Artifact URL if build was successfully completed" }, "logs": { "type": "array", "description": "Build Logs which can be used for build problem investigation", "items": { "type": "string" } }, "metadata": { "type": "object", "description": "Metadata generated by build" } } }, "example": { "build_id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-4850-8e86-abfdfd3b0a76/build.zip", "logs": [] } } }, "description": "200 response" } ], "parameters": [ { "in": "path", "children": [ { "name": "build_id", "description": "Unique build id which was returned when build was started", "type": "string", "required": true, "example": "", "default": "" } ] } ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `openapi_paths` | `object` | Open API paths definition. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/{product_name}/openapi/paths/{path}` #### Get Open API paths `getOpenApiPath` Get Open API path definitions. ##### Response 200400 application/json Copy Success response ``` { "openapi_paths": { "method": "get", "service_name": "Build", "base_path": "infra-builder", "env_domain": "template.staircaseapi.com", "path": "/builds/{build_id}", "sidebar_path": "/docs/DevOps/Ship/Build/get-build-status", "operation_id": null, "description": "**Retrieve Service Build Status**", "summary": "Get build status", "request_body": null, "responses": [ { "response_code": "200", "content": { "application/json": { "schema": { "type": "object", "properties": { "build_id": { "type": "string", "description": "Unique build id which was returned when build was started", "format": "uuid" }, "status": { "type": "string", "description": "Build status (IN_PROGRESS, FAILED, SUCCEEDED)" }, "artifacts_url": { "type": "string", "format": "url", "description": "Artifact URL if build was successfully completed" }, "logs": { "type": "array", "description": "Build Logs which can be used for build problem investigation", "items": { "type": "string" } }, "metadata": { "type": "object", "description": "Metadata generated by build" } } }, "example": { "build_id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-4850-8e86-abfdfd3b0a76/build.zip", "logs": [] } } }, "description": "200 response" } ], "parameters": [ { "in": "path", "children": [ { "name": "build_id", "description": "Unique build id which was returned when build was started", "type": "string", "required": true, "example": "", "default": "" } ] } ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | | `path` required | `string` path | `publishDocumentation` | Path which was specified as 'operationId' in api method definition in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `openapi_paths` | `object` | Open API paths definition. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/content/paths` #### List all Open API paths `getContentPaths` Get all Open API path definitions. ##### Response application/json Copy Success response ``` { "products_paths": { "/builds": { "post": { "x-product-component": "Product", "x-product-endpoint": "Build Product", "x-product-sequence": 1, "tags": [ "Build" ], "summary": "Create/Run service builder for services.", "description": "Build a deployable artifact for a product. The artifact must be provided via a URL. A callback will be sent to the URL specified in property.", "requestBody": { "description": "Run Specification", "content": { "application/json": { "schema": { "type": "object", "title": "Service Build Schema", "properties": { "bundle_id": { "type": "string", "format": "uuid", "description": "Usually a hash of the commit but can be any UUID." }, "source_url": { "type": "string", "description": "URL to source code.", "format": "uri" }, "callback_url": { "type": "string", "format": "uri", "default": "null", "description": "Callback URL where are you waiting for build status" } }, "required": [ "source_url" ], "example": { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } }, "example": { "source_url": "https://code-manager-dev-root.s3.amazonaws.com/service-builder-api/2f867413-2f16-4c73-86ec-3086c0d4a33c/source.zip" } } } }, "responses": { "201": { "description": "Build created", "content": { "application/json": { "schema": { "type": "object", "properties": { "build_id": { "type": "string", "format": "uuid", "description": "Unique build_id which can be used for tracking build status. Usually it is a UUID." } }, "example": { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } }, "example": { "build_id": "13bd5b51-1a41-4510-9baa-d7f7e24c89a3" } } } } } } }, "/builds/{build_id}": { "get": { "x-product-component": "Product", "x-product-endpoint": "Retrieve Product Build Status", "x-product-sequence": 2, "tags": [ "Build" ], "summary": "Get build status", "description": "**Retrieve Service Build Status**\n", "parameters": [ { "name": "build_id", "description": "Unique build id which was returned when build was started", "required": true, "in": "path", "schema": { "type": "string" } } ], "responses": { "200": { "description": "200 response", "content": { "application/json": { "schema": { "type": "object", "properties": { "build_id": { "type": "string", "description": "Unique build id which was returned when build was started", "format": "uuid" }, "status": { "type": "string", "description": "Build status (IN_PROGRESS, FAILED, SUCCEEDED)" }, "artifacts_url": { "type": "string", "format": "url", "description": "Artifact URL if build was successfully completed" }, "logs": { "type": "array", "description": "Build Logs which can be used for build problem investigation", "items": { "type": "string" } }, "metadata": { "type": "object", "description": "Metadata generated by build" } } }, "example": { "build_id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-4850-8e86-abfdfd3b0a76/build.zip" } } } } } } } } } ``` ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `products_paths` | `object` | Open all API paths definitions. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/collection/{product_name}` #### Get Postman Collection `getPostmanCollection` Get Postman Collection. ##### Response 200400 application/json Copy Success response ``` { "item": [ { "id": "09b9a1ae-9fb4-4391-82b6-67fd6d244f01", "name": "builds", "item": [ { "id": "888efd45-186c-4fb3-b1ed-573efd38340b", "name": "Retrieve Product Build Status", "request": { "name": "Retrieve Product Build Status", "description": { "content": "**Retrieve Service Build Status** retrieves metadata generated by the build.\n\n- Metadata is available only for builds that succeed (status==SUCCEEDED).\n- The *artifact_url* key in the response body contains the URL to the artifact that was built. This URL only supports the GET method and is valid for one hour. A new request to this endpoint will provide a new *artifact_url*.\n- The response to a GET request for artifact_url will contain headers describing the artifact metadata. Only header names that start with x-amz-meta-service- are considered service metadata.\n- Regardless of status response contains build execution logs\n", "type": "text/plain" }, "url": { "path": [ "builds", ":build_id" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [ { "disabled": false, "type": "any", "value": "", "key": "build_id", "description": "(Required) Unique build id which was returned when build was started" } ] }, "header": [ { "disabled": false, "description": "(Required) API Key", "key": "x-api-key", "value": "" } ], "method": "GET", "auth": null }, "response": [ { "id": "872b2b15-1fcf-48d5-bebd-950b1e4baccb", "name": "200 response", "originalRequest": { "url": { "path": [ "builds", ":build_id" ], "host": [ "{{baseUrl}}" ], "query": [], "variable": [ { "type": "any", "key": "build_id" } ] }, "header": [ { "disabled": false, "description": "(Required) API Key", "key": "x-api-key", "value": "" } ], "method": "GET", "body": {} }, "status": "OK", "code": 200, "header": [ { "key": "Content-Type", "value": "application/json" } ], "body": "", "cookie": [], "_postman_previewlanguage": "json" } ], "event": [] } ], "event": [] } ] } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Documentation` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `item` | `object[]` | List of postman items. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Setup[new] `PUT` `/integrations/datocms/credentials` #### Update DatoCMS Token[warning] `updateDatoCMStoken` Update DatoCMS Token Update your DatoCMS connection Every DatoCMS project comes with two API tokens by default: one is read-only, and the other gives full read-write permissions to the project. ! Note: Establishing connection Site requires only read-only token, but both variants acceptable. You can find your DatoCMS Project's tokens at: ``` ].admin.datocms.com/admin/access_tokens ``` ##### Request application/json Copy ``` { "token": "" } ``` ##### Response 201400 application/json Copy Example response ``` { "message": "Created" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `token` | `string` | DatoCMS token | ##### Response `201``application/json` 1 fields Example response | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `PUT` `/integrations/writercom/credentials` #### Set Writer.com Credentials[warning] `updateWriterComCredentials` Update Writer.com credentials Update your Writer.com connection ##### Request application/json Copy ``` { "token": "", "team_id": "23gdqae9013f7baf9f2025306e98283", "organization_id": "4saa3e9013f7baf9f20e256322283" } ``` ##### Response 201400 application/json Copy Example response ``` { "message": "Created" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `token` | `string` | Writer.com token | | `team_id` | `string` | Writer.com team_id | | `organization_id` | `string` | Writer.com organization_id | ##### Response `201``application/json` 1 fields Example response | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Integration: DatoCMS[new] `GET` `/integrations/datocms/fields/{field_id}` #### Retrieve DatoCMS Field `retrieveDatoCMSField` Retrieve DatoCMS Field ! Note: You can find all possible DatoCMS field types here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` { "type": "field", "id": "124", "attributes": { "label": "Title", "field_type": "string", "localized": "true", "default_value": { "en": "A default value", "it": "Un valore di default" }, "api_key": "title", "hint": "This field will be used as post title", "validators": { "required": {} }, "appearance": { "editor": "single_line", "parameters": { "heading": false }, "addons": [ { "id": "1555", "field_extension": "lorem_ipsum", "parameters": {} } ] }, "position": 1 }, "relationships": { "item_type": { "data": { "type": "item_type", "id": "53311" } }, "fieldset": { "data": null } } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `field_id` required | `string` path | `4934786` | DatoCMS Field ID or Field api_key | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS field ID or api_key | | `type`required | `string` | DatoCMS field type | | `relationships` | `object` | DatoCMS field relationships | | `attributes` | `object` | DatoCMS field attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/models` #### Retrieve DatoCMS Models `retrieveDatoCMSModels` Retrieve DatoCMS Models Returns an array of DatoCMS model objects. ! Note: You can learn more about DatoCMS models here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` [ { "type": "item_type", "id": "124", "attributes": { "name": "Blog post", "api_key": "post", "collection_appearance": "compact", "singleton": false, "all_locales_required": false, "sortable": true, "modular_block": false, "draft_mode_active": false, "tree": false, "ordering_direction": null, "ordering_meta": "created_at", "has_singleton_item": false, "hint": "Blog posts will be shown in our website under the Blog section" }, "relationships": { "singleton_item": { "data": null }, "fields": { "data": [ { "type": "field", "id": "3535555" } ] }, "fieldsets": { "data": [ { "type": "fieldset", "id": "23555" } ] }, "title_field": { "data": null }, "image_preview_field": { "data": null }, "excerpt_field": { "data": null }, "ordering_field": { "data": null }, "workflow": { "data": null } } } ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS model ID or api_key | | `type`required | `string` | DatoCMS model type | | `relationships` | `object` | DatoCMS model relationships | | `attributes` | `object` | DatoCMS model attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/models/{model_id}` #### Retrieve DatoCMS Model `retrieveDatoCMSModel` Retrieve DatoCMS Model Returns DatoCMS model object. ! Note: You can learn more about DatoCMS models here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` { "type": "item_type", "id": "124", "attributes": { "name": "Blog post", "api_key": "post", "collection_appearance": "compact", "singleton": false, "all_locales_required": false, "sortable": true, "modular_block": false, "draft_mode_active": false, "tree": false, "ordering_direction": null, "ordering_meta": "created_at", "has_singleton_item": false, "hint": "Blog posts will be shown in our website under the Blog section" }, "relationships": { "singleton_item": { "data": null }, "fields": { "data": [ { "type": "field", "id": "3535555" } ] }, "fieldsets": { "data": [ { "type": "fieldset", "id": "23555" } ] }, "title_field": { "data": null }, "image_preview_field": { "data": null }, "excerpt_field": { "data": null }, "ordering_field": { "data": null }, "workflow": { "data": null } } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `model_id` required | `string` path | `1153125` | DatoCMS Model ID or Model api_key | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS model ID or api_key | | `type`required | `string` | DatoCMS model type | | `relationships` | `object` | DatoCMS model relationships | | `attributes` | `object` | DatoCMS model attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/models/{model_id}/fields` #### Retrieve DatoCMS Model Fields `retrieveDatoCMSModelFields` Retrieve DatoCMS Model Fields Returns an array of DatoCMS field objects. ! Note: You can find all possible DatoCMS field types here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` [ { "type": "field", "id": "124", "attributes": { "label": "Title", "field_type": "string", "localized": "true", "default_value": { "en": "A default value", "it": "Un valore di default" }, "api_key": "title", "hint": "This field will be used as post title", "validators": { "required": {} }, "appearance": { "editor": "single_line", "parameters": { "heading": false }, "addons": [ { "id": "1555", "field_extension": "lorem_ipsum", "parameters": {} } ] }, "position": 1 }, "relationships": { "item_type": { "data": { "type": "item_type", "id": "53311" } }, "fieldset": { "data": null } } } ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `model_id` required | `string` path | `1153125` | DatoCMS Model ID or Model api_key | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS field ID or api_key | | `type`required | `string` | DatoCMS field type | | `relationships` | `object` | DatoCMS field relationships | | `attributes` | `object` | DatoCMS field attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/page-details/{page_id}` #### Retrieve page details from DatoCMS `retrieveDatoCMSPageDetails` Retrieve page details from DatoCMS ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` { "type": "field", "id": "124", "attributes": { "label": "Title", "field_type": "string", "localized": "true", "default_value": { "en": "A default value", "it": "Un valore di default" }, "api_key": "title", "hint": "This field will be used as post title", "validators": { "required": {} }, "appearance": { "editor": "single_line", "parameters": { "heading": false }, "addons": [ { "id": "1555", "field_extension": "lorem_ipsum", "parameters": {} } ] }, "position": 1 }, "relationships": { "item_type": { "data": { "type": "item_type", "id": "53311" } }, "fieldset": { "data": null } } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `page_id` required | `—` path | `pricing-page` | Page ID | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS field ID or api_key | | `type`required | `string` | DatoCMS field type | | `relationships` | `object` | DatoCMS field relationships | | `attributes` | `object` | DatoCMS field attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/records` #### Retrieve DatoCMS Records `retrieveDatoCMSRecords` Retrieve DatoCMS Records Returns an array of DatoCMS record objects. ! Note: You can learn more about DatoCMS records here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` [ { "type": "item", "id": "124", "attributes": { "title": "My first blog post!", "content": "Lorem ipsum dolor sit amet...", "category": "24" }, "relationships": { "creator": { "data": [ { "type": "account", "id": "3535555" } ] }, "item_type": { "data": [ { "type": "item_type", "id": "23555" } ] } }, "meta": { "created_at": "2020-04-21T07:57:11.124Z", "updated_at": "2020-04-21T07:57:11.124Z", "published_at": "2020-04-21T07:57:11.124Z", "first_published_at": "2020-04-21T07:57:11.124Z", "publication_scheduled_at": "2020-04-21T07:57:11.124Z", "unpublishing_scheduled_at": "2020-04-21T07:57:11.124Z", "status": "draft", "is_current_version_valid": true, "is_published_version_valid": true, "current_version": "4234", "stage": "" } } ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 10 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `nested` | `string` query | `true` | For Modular Content fields and Structured Text fields. If set, returns full payload for nested blocks instead of IDs | | `filter[ids]` | `string` query | `124214,21421` | Record (or block record) IDs to fetch, comma separated. If you use this filter, you must not use filter[type] or filter[fields] | | `filter[type]` | `string` query | `item` | Record (or block record) IDs to fetch, comma separated. If you use this filter, you must not use filter[type] or filter[fields] | | `filter[query]` | `string` query | `search query` | Textual query to match. You must not use filter[ids]. If locale is defined, search within that locale. Otherwise, environment's main locale will be used. | | `filter[fields]` | `string` query | `field` | Same as GraphQL API records filters. Use snake_case for fields names. If locale is defined, search within that locale. Otherwise, environment's main locale will be used. | | `locale` | `string` query | `en` | When filter[query] or field[fields] is defined, filter by this locale. Default: environment's main locale | | `order_by` | `string` query | `id_DESC` | Fields used to order results. You must specify also filter[type] with one element only to be able use this option. Format: _<(ASC|DESC)>, where can be either the API key of a model's field, or one of the following meta columns: id, _updated_at, _created_at, _status, _published_at, _first_published_at, _publication_scheduled_at, _unpublishing_scheduled_at, _is_valid, position (only for sortable models). You can pass multiple comma separated rules. | | `version` | `string` query | `current` | Whether you want the currently published versions (published, default) of your records, or the latest available (current) | | `page[offset]` | `string` query | `10` | Index of first record to fetch (defaults to 0) | | `page[limit]` | `string` query | `50` | Number of records to fetch (defaults to 30, maximum is 500) | ##### Response `200``application/json` 5 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS record ID or api_key | | `type`required | `string` | DatoCMS record type | | `relationships` | `object` | DatoCMS record relationships | | `attributes` | `object` | DatoCMS record attributes | | `meta` | `object` | DatoCMS record metadata | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/records/{record_id}` #### Retrieve DatoCMS Record `retrieveDatoCMSRecord` Retrieve DatoCMS Record Returns DatoCMS record objects. ! Note: You can learn more about DatoCMS records here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` { "type": "item", "id": "124", "attributes": { "title": "My first blog post!", "content": "Lorem ipsum dolor sit amet...", "category": "24" }, "relationships": { "creator": { "data": [ { "type": "account", "id": "3535555" } ] }, "item_type": { "data": [ { "type": "item_type", "id": "23555" } ] } }, "meta": { "created_at": "2020-04-21T07:57:11.124Z", "updated_at": "2020-04-21T07:57:11.124Z", "published_at": "2020-04-21T07:57:11.124Z", "first_published_at": "2020-04-21T07:57:11.124Z", "publication_scheduled_at": "2020-04-21T07:57:11.124Z", "unpublishing_scheduled_at": "2020-04-21T07:57:11.124Z", "status": "draft", "is_current_version_valid": true, "is_published_version_valid": true, "current_version": "4234", "stage": "" } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `record_id` required | `string` path | `4934786` | DatoCMS Record ID or Record api_key | | `nested` | `string` query | `true` | For Modular Content fields and Structured Text fields. If set, returns full payload for nested blocks instead of IDs | | `version` | `string` query | `current` | Whether you want the currently published versions (published, default) of your records, or the latest available (current) | ##### Response `200``application/json` 5 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS record ID or api_key | | `type`required | `string` | DatoCMS record type | | `relationships` | `object` | DatoCMS record relationships | | `attributes` | `object` | DatoCMS record attributes | | `meta` | `object` | DatoCMS record metadata | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/records/{record_id}/apply-glossary` #### Apply Writer.com glossary to DatoCMS Record `applyGlossaryToDatoCMSRecord` Apply Writer.com glossary to DatoCMS Record It will apply Writer.com values to the record structure ##### Response 200400 application/json Copy Success response ``` { "type": "item", "id": "124", "attributes": { "title": "My first blog post!", "content": "Lorem ipsum dolor sit amet...", "category": "24" }, "relationships": { "creator": { "data": [ { "type": "account", "id": "3535555" } ] }, "item_type": { "data": [ { "type": "item_type", "id": "23555" } ] } }, "meta": { "created_at": "2020-04-21T07:57:11.124Z", "updated_at": "2020-04-21T07:57:11.124Z", "published_at": "2020-04-21T07:57:11.124Z", "first_published_at": "2020-04-21T07:57:11.124Z", "publication_scheduled_at": "2020-04-21T07:57:11.124Z", "unpublishing_scheduled_at": "2020-04-21T07:57:11.124Z", "status": "draft", "is_current_version_valid": true, "is_published_version_valid": true, "current_version": "4234", "stage": "" } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `record_id` required | `string` path | `4934786` | DatoCMS Record ID or Record api_key | ##### Response `200``application/json` 5 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS record ID or api_key | | `type`required | `string` | DatoCMS record type | | `relationships` | `object` | DatoCMS record relationships | | `attributes` | `object` | DatoCMS record attributes | | `meta` | `object` | DatoCMS record metadata | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/uploads` #### Retrieve DatoCMS Uploads `retrieveDatoCMSUploads` Retrieve DatoCMS Uploads Returns an array of DatoCMS upload objects. ! Note: You can learn more about DatoCMS uploads here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` [ { "type": "upload", "id": "124", "attributes": { "size": "444", "width": "30", "height": 30, "path": "/45/1496845848-digital-cats.jpg", "basename": "digital-cats", "filename": "digital-cats.jpg", "url": "https://www.datocms-assets.com/45/1496845848-digital-cats.jpg", "format": "Mark Smith", "author": "Mark Smith", "copyright": "2020 Staircase", "notes": "Nyan the cat", "md5": "873c296d0f2b7ee569f2d7ddaebc0d33", "duration": 62, "frame_rate": 30, "blurhash": "LEHV6nWB2yk8pyo0adR*.7kCMdnj", "mux_playback_id": "a1B2c3D4e5F6g7H8i9", "mux_mp4_highest_res": "high", "default_field_metadata": { "en": { "title": "this is the default title", "alt": "this is the default alternate text", "custom_data": { "foo": "bar" }, "focal_point": { "x": "0.5,", "y": 0.5 } } }, "is_image": true, "created_at": "2020-04-21T07:57:11.124Z", "updated_at": "2020-04-21T07:57:11.124Z", "mime_type": "image/jpeg", "tags": [ "cats" ], "smart_tags": [ "staircase_cats" ], "exit_info": { "iso": 10000, "model": "ILCE-7", "flash_mode": 16, "focal_length": 35, "exposure_time": 0.0166667 }, "colors": [ { "red": 206, "green": 203, "blue": 167, "alpha": 255 }, { "red": 158, "green": 163, "blue": 93, "alpha": 235 } ] }, "relationships": { "creator": { "data": { "type": "account", "id": "53311" } } } } ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `filter[ids]` | `string` query | `124214,21421` | Record (or block record) IDs to fetch, comma separated. If you use this filter, you must not use filter[type] or filter[fields] | | `filter[query]` | `string` query | `search query` | Textual query to match. You must not use filter[ids]. If locale is defined, search within that locale. Otherwise, environment's main locale will be used. | | `filter[fields]` | `string` query | `field` | Same as GraphQL API records filters. Use snake_case for fields names. If locale is defined, search within that locale. Otherwise, environment's main locale will be used. | | `locale` | `string` query | `en` | When filter[query] or field[fields] is defined, filter by this locale. Default: environment's main locale | | `order_by` | `string` query | `id_DESC` | Fields used to order results. Format: _<(ASC|DESC)>. You can pass multiple comma separated rules. | | `page[offset]` | `string` query | `10` | Index of first record to fetch (defaults to 0) | | `page[limit]` | `string` query | `50` | Number of records to fetch (defaults to 30, maximum is 500) | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS upload ID or api_key | | `type`required | `string` | DatoCMS upload type | | `relationships` | `object` | DatoCMS upload relationships | | `attributes` | `object` | DatoCMS upload attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/integrations/datocms/uploads/{upload_id}` #### Retrieve DatoCMS Upload `retrieveDatoCMSUpload` Retrieve DatoCMS Upload Returns DatoCMS upload object. ! Note: You can learn more about DatoCMS uploads here ! Required: You should set up your token first ##### Response 200400 application/json Copy Success response ``` { "type": "upload", "id": "124", "attributes": { "size": "444", "width": "30", "height": 30, "path": "/45/1496845848-digital-cats.jpg", "basename": "digital-cats", "filename": "digital-cats.jpg", "url": "https://www.datocms-assets.com/45/1496845848-digital-cats.jpg", "format": "Mark Smith", "author": "Mark Smith", "copyright": "2020 Staircase", "notes": "Nyan the cat", "md5": "873c296d0f2b7ee569f2d7ddaebc0d33", "duration": 62, "frame_rate": 30, "blurhash": "LEHV6nWB2yk8pyo0adR*.7kCMdnj", "mux_playback_id": "a1B2c3D4e5F6g7H8i9", "mux_mp4_highest_res": "high", "default_field_metadata": { "en": { "title": "this is the default title", "alt": "this is the default alternate text", "custom_data": { "foo": "bar" }, "focal_point": { "x": "0.5,", "y": 0.5 } } }, "is_image": true, "created_at": "2020-04-21T07:57:11.124Z", "updated_at": "2020-04-21T07:57:11.124Z", "mime_type": "image/jpeg", "tags": [ "cats" ], "smart_tags": [ "staircase_cats" ], "exit_info": { "iso": 10000, "model": "ILCE-7", "flash_mode": 16, "focal_length": 35, "exposure_time": 0.0166667 }, "colors": [ { "red": 206, "green": 203, "blue": 167, "alpha": 255 }, { "red": 158, "green": 163, "blue": 93, "alpha": 235 } ] }, "relationships": { "creator": { "data": { "type": "account", "id": "53311" } } } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `upload_id` required | `string` path | `4934786` | DatoCMS Upload ID or Upload api_key | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | DatoCMS upload ID or api_key | | `type`required | `string` | DatoCMS upload type | | `relationships` | `object` | DatoCMS upload relationships | | `attributes` | `object` | DatoCMS upload attributes | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Integration: Writer.com[new] `GET` `/integrations/writercom/snippets` #### Retrieve Writer.com Snippets `retrieveWriterComSnippets` Retrieve Writer.com Snippets Returns an array of Writer.com snippet objects. ! Required: You should set up your credentials first ##### Response 200400 application/json Copy Success response ``` [ {} ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 7 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `shortcut` | `string` query | `string` | Shortcut | | `search` | `string` query | `search string` | Search | | `tags` | `string[]` query | — | Tags | | `sortField` | `string` query | `type` | Sort Field | | `sortOrder` | `string` query | `asc` | Sort Order | | `offset` | `integer` query | `5` | Offset | | `limit` | `integer` query | `20` | Limit | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``403` `GET` `/integrations/writercom/terms` #### Retrieve Writer.com Terms `retrieveWriterComTerms` Retrieve Writer.com Terms Returns an array of Writer.com terms objects. ! Required: You should set up your credentials first ##### Response 200400 application/json Copy Success response ``` [ {} ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 8 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` | `string` query | `approved` | Type | | `term` | `string` query | `term` | Term | | `Part of speech` | `string` query | `type` | Part of speech | | `tags` | `string[]` query | — | Tags | | `sortField` | `string` query | `type` | Sort Field | | `sortOrder` | `string` query | `asc` | Sort Order | | `offset` | `integer` query | `5` | Offset | | `limit` | `integer` query | `20` | Limit | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``403` ### App Configurations[new] `PUT` `/ordered-flows` #### Register Configuration[updated] `registerAppConfiguration` Register Configuration Part of Site product, component name: Site-App-Flows registered on `marketplace.staircaseapi.com`. #### Update Or Add Flow Enables you to glue the Console applications into a standalone application or a flow of applications. ##### Specification The Site Flow Configuration is a flow specification designed to define the structure of a web application's layout. By using Site Flows, you can dynamically configure the layout of the application, including authentication settings, appearance of various layout elements, and the sequence of apps that appear in the main layout. Show the rest The flexibility provided by the endpoint allows developers to quickly update the application's appearance and functionality without needing to modify the underlying code. ##### Layout types | Configuration key | Layout Element | Description | | --- | --- | --- | | `authentication` | Authentication | Defines whether authentication is enabled or disabled for the application. | | `left_sidebar` | Left Sidebar | Represents the settings and appearance of the left sidebar in the layout. | | `right_sidebar` | Right Sidebar | Represents the settings and appearance of the right sidebar in the layout. | | `header` | Header | Represents the settings and appearance of the header in the layout. | | `hero` | Hero | Represents the settings and appearance of the hero in the layout. | | `footer` | Footer | Represents the settings and appearance of the footer in the layout. | | `main` | Main | Represents the settings and appearance of the main layout, which can be either a sequence of apps or a standalone app. | | `favicon` | Favicon | A symbol or graphic associated with a website. In a typical browser stands right before the tab title. | | `layout` | Layout | Represents the settings and appearance of the layout. | ##### Main Layout ###### Rendering Main layout can be rendered in two different ways, and is defined via `rendering_type` field under `main` layout configuration. | Rendering Type | Description | | --- | --- | | `flow` | Allows defining an interactive set of app configurations called a `flow`. | | `list` | Allows having unordered list of app configurations. Except for the default (first) screen. | ##### Window titling The default title of the browser window must be defined in `main` layout configuration. However, it can be overwritten by optionally configured title of an individual app configurations. #### Analytics The analytics settings can be defined in the flow configuration along with layout configuration. Analytics configuration resides under `analytics` key in the flow configuration. List of partners which analytics can be enabled for a site: | Partner | Configuration key | Description | Value Example | | --- | --- | --- | --- | | Google Analytics | `google_analytics_tag` | Google Analytics tag can be retrieved from Google Analytics. | `G-A1BCD2EF3H` | | Google Analytics | `google_analytics_server_url` | Google Analytics Server URL. Can be retrived from Google Analytics Server Side | | | Mouseflow | `mouseflow_project_identifier` | Mouseflow can be enabled by providing an identifier retrieved from the project. | `0710f46a-9441-11ee-8acf-6ae56c4923a6` | | GA Tracking | `google_analytics_tracking_parameters` | Google Analytics tracking parameters can be enabled by providing a list of parameters. | `["utm_campaign","guid"]` | | Facebook tracking | `facebook_pixel_id` | ID of Facebook tracing pixel | `["utm_campaign","guid"]` | | Facebook tracking | `facebook_pixel_domain_verification` | facebook-domain-verification content for meta tag in head | `["utm_campaign","guid"]` | | Site Advertisement | `advertiser_correlation_key` | Site Advertisement can be enabled by providing a correlation key. `utm_source` is the only allowed value. | `e0e44570-6666-0001-000a-000a00aa0a0a` | | **Google Tag Manager ** | `google_tag_manager_id` | Google Tag Manager ID can be retrieved from Google Tag Manager. | `GTM-XXXXXX` | ##### GA Tracking ``` { "analytics": { "google_analytics_tracking_parameters": ["utm_campaign", "guid"] } } ``` When the user navigates to ``, Site will send a `staircase_page_view` event to Google Analytics with the following parameters: ``` { "utm_campaign": "email", "guid": "98903487222" } ``` ##### Site Advertisement ``` { "analytics": { "advertiser_correlation_key": "utm_source" } } ``` Defines the query parameter to look up advertiser's information at. When user visit ``, Site will perform Persist Advertiser Data with `utm_source`'s value as an `advertiser_id`. The data will be collected from query parameters and passed on for the further translation. ##### Consent Cookie consent is automatically enabled for any site that has analytics enabled. It is fully managed by the Site product and does not require any additional configuration. However, it can be customized with the consent configuration under `cookie_consent` key. ###### Cookie Consent Configuration Example ``` { ... "analytics": { "google_analytics_tag": "G-9TJJ8RPE4H" }, "cookie_consent": { "popup": { "title": "Got time for cookies?", "button_ok": "Sure" } } } ``` Review the schema of `cookie_consent` for more customization options. #### Error Pages | Error page | Description | | --- | --- | | forbidden | Access Denied: The user's IP address is not from the United States. | Error page content can include full HTML markup, including CSS and JavaScript. Avoid bloating the page with unnecessary resources, as it will affect the page load time. Note: the Site product restricts access to visitors with IP addresses from the United States only. Traffic from IP addresses outside the U.S. is not permitted. ##### Example ``` { ... "layout_configuration": { ... }, "analytics": { ... }, "error_pages": { "forbidden": { "page_content": "Access Restricted

Access Restricted

Sorry, this content is not available in your region.

Your IP address has been identified as not originating from the United States. For compliance reasons, we cannot grant access to users outside this region.

If you believe you have received this message in error, please contact support atsupport@example.com.

" } } } ``` ##### (IMPORTANT) Custom Domains When you change `error_pages` in the Site configuration, remember to sync the Site deployments. - Register Configuration with `error_pages` configuration. - Deploy Configuration to the distribution network. - Synchronize custom Site. #### Open Graph Protocol Site provides a way to define OGP tags inside the Site configuration. We follow for the most part with slight modifications. Namely: - `og:type` can only be set to `website` as is required. - `og:description` is a required parameter. - `og:locale` can only be set to `en_US` and is required - `og:site_name` is required for ANY website. In the original OGP these fields are optional. For a configuration example navigate to a request payload example named "Open Graph Tags". ##### Best Practices for OGP Images - Aspect Ratio: The most widely recommended aspect ratio for OG images is 1.91:1. This ratio is optimal for platforms like Facebook, LinkedIn, and Twitter. - Dimensions: - Minimum Size: At minimum, your image should be 600 x 315 pixels (width x height). However, this is quite small and might not look great on high-resolution displays. - Optimal Size: A more commonly recommended size is 1200 x 630 pixels. This size tends to work well on most social networks and provides a good balance between file size and image quality. - Maximum Size: For some platforms like Facebook, the maximum image size can be up to 4096 x 4096 pixels, but such large images are rarely necessary and can increase page load times. - File Size: Keep an eye on the image file size. It's generally recommended to keep it under 300 KB to ensure fast loading times, as large images can slow down your page's performance. - File Type: Use JPEG for photographic images to save bandwidth, or PNG for images with text, logos, or simple graphics where clarity is important. #### Path Mappings Path mappings can be defined in the flow configuration along with layout configuration. Path mappings allow you to define a set of rules that will be applied to the behavior of the Site when the certain URL path is provided. If the URL path matches the rule, the user will be redirected to the specified URL path. Request URL attributes such as query parameters will be preserved, but are not allowed to be defined in source path. Note: Requests without `Host` header provided will not be eligible for a proper redirect response. As those requests will be considered malicious. Path mappings configuration resides under `path_mapping` key in the flow configuration. ##### Examples The redirect response example (the actual response may vary): ``` HTTP/2 302 server: CloudFront date: Wed, 19 Jul 2023 04:21:00 GMT content-length: 75 cache-control: public, max-age=86400, immutable location: * Connection #0 to host staircase.co left intact

You are being redirected...

``` Take a closer look at `Cache-Control`. The maximum caching age value is set by the server and cannot be changed. The server will direct the viewer to cache the response for 24 hours. ##### Validation rules For the URL path: - Must not contain leading or trailing slashes. E.g., `/about-us/` must be corrected to `about-us`. - Must be already URL encoded. E.g., `about us` must be corrected to `about%20us`. - Must not contain anything other than alphanumeric characters, forward slash, period, and dash. It should match `^[a-z0-9]+([./-][a-z0-9]+)*$` regular expression. - Must not contain query parameters. E.g., `about-us?utm_source=google` must be corrected to `about-us`. For the complete URL: - Must contain the `URL` schema. E.g., `example.staircase.co` must be corrected to ``. - Must not contain query parameters. E.g., `must be corrected to`. - Must not contain fragment identifiers. E.g., `must be corrected to`. ##### Use cases ##### Internal redirects Redirect to a different URL on the same domain name. ###### Problem statement We need to redirect all requests from the old pricing.html page to the new pricing page located at a different URL path, ensuring this redirection is permanent. ###### Configuration ``` { ... "layout_configuration": { ... }, "analytics": { ... }, "path_mappings": [ { "from_path": "pricing.html", "to_path": "pricing" }, { "from_path": "legal-terms.html", "to_path": "legal" } ] } ``` We have added a new path mapping rule to the flow configuration, which will redirect all requests from `pricing.html` to `pricing` path. ##### External redirects Redirect to a different URL on a different domain name. ###### Problem statement We would like to move part of the existing application, to a completely new site configuration, under the different domain name. It's currently hosted on `and we would like to move it to`. ###### Configuration ``` { ... "layout_configuration": { ... }, "analytics": { ... }, "path_mappings": [ { "from_path": "exchange", "to_path": "" } ] } ``` We have added a new path mapping rule to the flow configuration, which will redirect all requests from `exchange` to `` path. ##### Notes ###### Custom Domains When you change `path_mapping` in the Site configuration, remember to sync the Site deployments. - Register Configuration with `path_mappings` configuration. - Deploy Configuration to the distribution network. - Synchronize custom Site. #### Custom Authentication Site provides a way to manage the authentication of the user using custom console app. Authentication requirement can be defined in the Site configuration as following using `authentication_action`. ##### Communication ###### Query Parameters The following parameters are loaded | Parameter | Description | | --- | --- | | `next_console_app_configuration_id` | The next console app configuration that should be loaded on Site, once the user was authenticated | | `authentication_action` | Authentication intent defined in the Site configuration or requested by another console app via the Site Event. | | `authentication_state` | Authentication state key. A short random string generated by Site, the Authentication app is expected to put this key in the redirect URLs for `SignUp` and `Sign In by SSO` authentication flows | | `authentication_origin` | Authentication origin. The current Site URL instantiating the authentication flow. | ###### Events The following event is expected to be emitted by the custom console app to the Site. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "authentication_completed": { "type": "boolean", "description": "Describes whether the authentication flow has been completed.", "enum": [true] }, "next_console_app_configuration_id": { "type": "string", "description": "Describes the console app configuration. Tells the Site to load an app marked by this field." }, "auth": { "type": "object", "description": "What authentication context screen to load.", "properties": { "access_token": {"type": "string"}, "id_token": {"type": "string"}, "refresh_token": {"type": "string"} } } }, "required": [ "listener", "next_console_app_configuration_id", "auth", "authentication_completed" ] } ``` ###### Cookies When the user is redirected back to site after Sign In by SSO or Sign Up authentication flow, site instructs browser to store a cookie named `accessToken` with the value of the access token provided in the URL hash. e.g., when visiting site with ``, the Site will instruct user's browser engine to store a cookie named `accessToken` with a value `1234`. Additionally, cookie will have the following attributes: - `Domain` – the domain name will be bound to the environment FQDN currently serving the backend APIs. e.g., `production.staircaseapi.com` - `Path` – the path will be bound to the root path `/`. - `Secure` – the cookie will be marked as secure to be transmitted to HTTPS origins exclusively. - `HttpOnly` – the cookie will not be accessible via JavaScript. It can only by the CDN request interceptor (CloudFront functions), or an API accessible under the same domain name. - `SameSite` – the value will be set to `None` to avoid improper cookie setting given the iframe context. - `Expires` – the value will be set to expire in 6 hours from when the request has been made. Currently, the `__sc.acact` cookie (represent the access token) set by site is considered as a third-party cookie, so you must apply caution when using API calls for authentication. ##### Example ``` { "authentication": { "enabled": true, "show_authentication_on_load": false, "console_app_configuration": { ... } } "layout_configuration": { "main": { ... "console_app_configurations": [ { "console_app_configuration_id": "6374c7f8-13fa-454a-8587-bd2972434bbb", "temporary__console_app_url": "/6374c7f8-13fa-454a-8587-bd2972434bbb-copy34/", "authentication_action": "signin", "url_suffix": "/conversations" } ] } } } ``` Before accessing `/conversations` the user, if not already authenticated, will be redirected to the `/signin` path and the custom console app will be loaded for authentication. ##### Advanced ###### State Exchange Custom authentication apps should utilize `authentication_state` to provide smooth user experience. Upon loading in an iframe, the app receives a query parameter: `authentication_state`, a short string of random characters. It's crucial to retain the authentication state, particularly when the authentication flow is interrupted by external redirections. Common scenarios include Sign Up processes, and authentications via SSO providers like Google, Amazon, or Facebook. The app should provider users with a link for redirection whenever necessary based on the authentication scenario. The Sign Up process is notable as it requires redirection from an email link for account activation. The site expects the "return" of the state key in the URL hash. ###### Example ``` Login using Google ``` In this example: - The app is loaded in an iframe and receives the authentication_state parameter. - During the authentication flow, a redirection for Google login is required. The user is provided a link to login via Google. - Upon clicking the link, the user completes the Google login process. - The user is redirected back to test.staircase.co with the URL hash `#state=p1d048R`. - The site, having associated this state with the data in local storage, uses it to load the most recently used console app. This scenario emphasizes the importance of managing the `authentication_state` parameter effectively to maintain a smooth user experience in cases involving external redirections like authentication via SSO. ###### Soft Authentication Everything described above is considered as a soft authentication. It does force authentication on the user, but it does not validate the user's identity. The user can easily bypass the authentication. Soft authentication is useful for when it's not required to validate the user's identity. ###### Authorization Forced validation cannot be achieved via the Site configuration. There will always be a way to bypass the authentication, instead apps must apply the Cookie validation logic to ensure the user is authenticated. The cookie validation can simply be achieved by validating the JWT token stored in the `__sc.acact` cookie, which represent access token from Access. If the app has an API it communicates with to retrieve the data that should not be generally available, the API must implement the access token validation logic to ensure the user is authenticated. The Site product enables such functionality by setting `HttpOnly` cookies accessible to every API that the console app consumes. #### Console App and Site Communications The Site allows two-way communication between the Site and the Apps using `postMessage` method. ##### Console App to Site Embedded Apps can communicate with the Site using `window.parent.postMessage(payloadObject, "*");`. `postMessage` was introduced to eliminate API calls from the Apps to Site endpoints. A unit of communication is a "message", which in itself is a JavaScript object with a required property `listener`. The value for the `listener` must correspond to the Site product identifier. Fact: Site product identifier is `e9cc145f-9d03-422e-ba71-1852885998e6` The list of events accepted by Site is described below. ###### Relocate the User ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "relocation_action": { "type": "string", "description": "Describes the action to be taken by the Site.", "enum": [ "REPLACE_CURRENT_URL", "OPEN_NEW_TAB", "OPEN_DEFAULT" ] }, "relocation_url": { "type": "string", "description": "The URL to be loaded by the Site." } }, "required": [ "listener", "relocation_action", "relocation_url" ] } ``` ###### Toggle Popup Note: `layout_configuration` should contain `popup` definition for the toggle to work. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "style": { "type": "object", "description": "Styling attributes. Standard CSS attributes.", "additionalProperties": { "type": "string" } }, "showPopup": { "type": "boolean", "description": "Marks the popup state. Use `true` – to show, `false` – to hide popup." } }, "required": [ "listener", "style", "showPopup" ] } ``` ###### Load Authentication Page ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "auth_screen": { "type": "string", "description": "What authentication context screen to load.", "enum": [ "signin", "signup", "forgot-password", "forgot-password-update" ] } }, "required": [ "listener", "auth_screen" ] } ``` The feature can also be accessed via the configuration via `authentication_action` field under `layout_configuration.main.console_app_configurations[*]`. ###### Logout the User Note: You can define `logout_url` under `layout_configuration.authentication` to redirect the user to the desired URL after the authentication reset. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "logout": { "type": "boolean", "description": "Whether to logout the user. Can only be `true`.", "enum": [ true ] } }, "required": [ "listener", "logout" ] } ``` ###### Load Console App Note: `console_app_configuration_id` should be present among console app configurations registered for the active flow configuration, and not just any console app configuration identifier. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "console_app_configuration_id": { "type": "string", "description": "Describes the console app configuration. Tells the Site to load an app marked by this field." } }, "required": [ "listener", "console_app_configuration_id" ] } ``` ###### Change Browser Tab URL Note: `url_suffix` property should be a path, not a full URL. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "url_suffix": { "type": "string", "description": "URL to be set in user's browser tab." } }, "required": [ "listener", "url_suffix" ] } ``` Warning: This feature is exclusive to site configurations with a single console app configuration. ###### Send Custom Tracking Event Sends a custom tracking event to the analytics provider. Right now only Google Tag Manager and Facebook Pixel are supported. It is recommended to use Google Tag Manager and manage data destinations from there, including Facebook Note: This will work only if the `analytics` configuration is present in the flow configuration. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "externalFeedbackProvider": { "type": "string", "enum": ["pixel", "gtm"] }, "type": { "type": "string", "example": "trackCustom" }, "action": { "type": "string" }, "data": { "type": "object" } }, "required": [ "listener", "externalFeedbackProvider", "action", "data" ] } ``` ###### Restyle Console App ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "style": { "type": "object", "additionalProperties": true, "description": "Apply different than original styles dynamically using a set of key-value pairs where the keys are CSS properties" }, "target": { "type": "string", "description": "A site component placeholder, which requires a change in styling.", "enum": ["header", "left_sidebar", "right_sidebar", "footer", "hero", "main"] } }, "required": [ "listener", "style", "target" ] } ``` ###### Dynamically Resizing Main Layout In order to keep the footer on the bottom of the page, the main layout height should be adjusted dynamically. To its dynamic height. The following example demonstrates how to use `ResizeObserver` to monitor document height changes, and send a message to the Site to adjust the height of the main layout. ``` const emitResizeSelfDimensions = ({height}) => { const resizeMeEvent = { listener: "e9cc145f-9d03-422e-ba71-1852885998e6", style: {height}, target: "main" }; window.parent.postMessage(resizeMeEvent, '*'); } const resizeObserver = new ResizeObserver( entries => { for (let entry of entries) { const newHeight = entry.contentRect.height; emitResizeSelfDimensions({height: newHeight}); } } ) resizeObserver.observe(document.body) ``` Important: Site automatically applies `margin-top` and `z-index` for the header, so it's kept on top while scrolling. ###### Pass on the Data When the `payload` property is passed together with `direction` or `console_app_configuration_id` fields, Site converts that value into the URL-encoded string and passes it to the console app configuration as a query parameter. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "console_app_configuration_id": { "type": "string", "description": "Describes the console app configuration. Tells the Site to load an app marked by this field." }, "direction": { "type": "string", "description": "Describes the direction of the flow. Tells the Site what to load next.", "enum": ["backward", "forward"] }, "payload": { "type": "object", "additionalProperties": { "type": "string" } } }, "required": [ "listener" ] } ``` ###### Refresh access and ID tokens Site allows refreshing the access and ID tokens by sending a message to the Site if refresh token is persisted. Note, that currently refresh token is generated by Access only for email-password flow and is not provided for SSO. If your application uses custom auth app, that app have to send refresh token to the Site ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "eventType": { "type": "string", "description": "Event type.", "enum": [ "refreshAccessToken" ] } }, "required": [ "listener", "eventType" ] } ``` ###### Data-driven Site Flow If none of `console_app_configuration_id` or `direction` were provided, the Site will treat the flow as conditionally driven. It will go through every console app configuration until it matches provided data to a specified condition. ##### Site to Console App Embedded Apps can listen to the Site event using `window.addEventListener`. In the case of Site to Console App communication the value for the `listener` corresponds to the console application configuration receiving the message. Every message sent by the Site to the Console App has a fixed structure. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Console application configuration identifier." }, "eventType": { "type": "string", "description": "Describes the event type that has occurred.", "enum": [ "main_app_change" ] }, "eventPayload": { "type": "object", "description": "Event payload. Varies depending on the event type." } }, "required": [ "listener", "eventType" ] } ``` ###### The Main Console App Has Changed The current main application configuration has changed to a different one. Warning: When a non-main console application configuration with `inherit_main_url: true` gets initialized, it is not guaranteed that the event will be emitted to the console application through the Site. Instead, the console application can rely on `main_url_path` passed as a query parameter when loading the console application. Same goes for `is_authenticated` ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Console application configuration identifier." }, "eventType": { "type": "string", "description": "Describes the event type that has occurred.", "enum": ["main_app_change"] }, "eventPayload": { "type": "object", "description": "Event payload. Can contain additional properties depending on the `change_reload_url_params` definition in the console app configuration.", "required": ["console_app_configuration_id", "is_authenticated"], "properties": { "main_url_path": { "type": "string", "description": "URL path of the main console app configuration. Provided if `inherit_url_path` is enabled." }, "console_app_configuration_id": { "type": "string", "description": "Console app configuration identifier of the switched app." }, "is_authenticated": { "type": "boolean", "description": "Correlation flag. Indicates whether the user is authenticated or not." } } } }, "required": [ "listener", "eventType", "eventPayload" ] } ``` Warning: Do not use `is_authenticated` flag for authorization purposes. It's only meant to be used to correlate the state between site and console applications. ##### Ratio Based Application Loading Main console application configuration can be configured to load different applications based on the ratio. The main use-case for the ratio based application loading is A/B testing on the level of the application configuration. When rendering such application, the Site will randomly select one of the application configurations (defined in `ratio_based_console_app_configurations` under the main application configuration) based on the ratio defined in the configuration. Site uses weighted random selection to determine which application configuration to load. Note: Defining the ratio based applications still requires defining the `console_app_configuration_id` and `temporary__console_app_url` properties. ###### Validation Rules The following rules are designed to ensure the ratio based application loading is configured correctly: - `ratio_based_console_app_configurations` must contain the original application configuration in the list of the alternative application configurations. - Each application configuration under `ratio_based_console_app_configurations` must contain the `ratio`. - The ratio for each application configuration must be a positive number greater than `0.0` and less than `1.0`. - The sum of all ratios must be equal to `1.0`. Navigate to endpoint request payload Flow with A/B Applications example to see the example of the ratio based application site configuration. ##### Conditional flows Conditional flows are a particular way of Site flows where the logic of which App should be displayed depends on the data passed in `postMessage`. First, the Site configuration should contain `condition` property set on all Apps except the first one. An example: ``` ... "console_app_configurations": { "console_app_configuration_id": "6374c7f8-13fa-454a-8587-bd2972434bbb", "temporary__console_app_url": "", "url_suffix": "/welcome" }, { "console_app_configuration_id": "6374c7f8-13fa-454a-8587-bd2972434ccc", "temporary__console_app_url": "", "url_suffix": "/option-one", "condition": { "path": "optionSelected", "operation": "equal", "value": "1" } }, { "console_app_configuration_id": "6374c7f8-13fa-454a-8587-bd2972434ddd", "temporary__console_app_url": "", "url_suffix": "/option-two", "condition": { "path": "optionSelected", "operation": "equal", "value": "2" } } } ... ``` When the Site is opened, the `/welcome` page will be displayed. Let's assume that `/welcome` page contains some form and, depending on the value selected by the User, one of the other two Apps should be displayed. After the User submits the value on `/welcome` App, the App invokes `window.parent.postMessage({"listener": "e9cc145f-9d03-422e-ba71-1852885998e6", "payload": {"optionSelected": submitedValue}}, "*");` with `submitedValue`. The Site receives the payload, checks for the conditions and if the `submitedValue` is equal to 1 displays `/option-one` App or `/option-two` if the `submitedValue` is equal to 2. The Site passes to the App `optionSelected` as a query parameter, for example, if `submitedValue` was equal to 2 it will load the App like ``. Note: - if the condition passed in `postMessage` payload does not match any of the conditions in the Site configuration, the User will remain on the same App - if multiple Apps conditions match the passed payload, the first one will be displayed - the Site does not do casting when comparing conditions and treats all values as strings ###### Using complex conditions The Site allows conditions to be complex using `and` and `or` operations. Example of such Site configuration: ``` ... { "console_app_configuration_id": "6374c7f8-13fa-454a-8587-bd2972434ddd", "temporary__console_app_url": "", "url_suffix": "/option-two", "condition": { "and": [ { "path": "optionSelected", "operation": "equal", "value": "1" }, { "path": "userAge", "operation": "greatherThan", "value": "21" } } } } ... ``` In this case, conditions are matched if only both `optionSelected` equals 1 and `userAge` is greater than 21. Similarly, using `or` operator instead of `and` will be matched if one of the conditions is meet. #### User State & Workflows Warning: Workflows can only be used for flows with authentication enabled. If the site visitor is not authenticated and tries entering the workflow, they will be directed to the authentication page. Workflows help in consistently saving user state data between various console app settings. A workflow is essentially a blueprint detailing the user's journey. You have the option to set up to 10 distinct workflows for each site configuration. It's crucial that every workflow is marked with a unique identifier and its corresponding path. When a user wraps up a state (in this case, a console app), the app then signals the completion to the Site. Subsequently, the Site initiates the loading of the forthcoming state. Should a user return to the site, the Site will automatically load their most recent state, presenting it directly to the user. ##### Defining a Workflow The framework to define a workflow resemble the [States Language seen in AWS Step Functions. However, it's a more condensed structure. Key distinctions include: - The `Type` property of a State can solely be `App`. - The `Resource` pertains to a console app configuration ID. - Every `States` should possess a distinctive `Resource` property. ##### Events for Workflows ###### State Done Tells site to load the Next app in the workflow. If the current state is terminal (`End: true`) nothing is changed. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "state_done": { "type": "boolean", "description": "Represents the state completion by the user. Can only be `true`.", "enum": [ true ] } }, "required": [ "listener", "state_done" ] } ``` ###### Switch Workflow Tells site to load to switch from one workflow to a different one. If the workflow specified does not exist – nothing will change. ``` { "$schema": "", "type": "object", "properties": { "listener": { "type": "string", "description": "Site product identifier.", "enum": [ "e9cc145f-9d03-422e-ba71-1852885998e6" ] }, "workflow_id": { "type": "string", "description": "Represents the workflow identifier." } }, "required": [ "listener", "workflow_id" ] } ``` ##### URL Paths & Workflow Each workflow is tied to a specific path. When a user accesses a URL that matches this path, they are directed into that particular workflow. Note that a workflow will absorb all `url_suffix`es defined for states in `Resource`. This implies that if a `url_suffix` is set, it must be distinctly different from other `url_suffix` definitions. See an example for a workflow definition in an example named "Stateful". Important: Modify identifiers for both site and console app configurations before using examples below. ##### Custom domain for backend and console apps The Site product allows you to use a custom domain for the backend and console apps. To use a custom domain you need to add `backend.domain_name` to your site configuration. Site will use this domain to load the console apps and to make requests to the backend. Example: ``` { "backend": { "domain_name": "api.example.com" } } ``` ##### Request SimpleOpen Graph TagsA/B AppsAnalytics EnabledStateful application/json Copy ``` { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174000", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174001", "layout_configuration": { "authentication": { "enabled": false }, "left_sidebar": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174002", "temporary__console_app_url": "/left-sidebar-url", "style": { "width": "250px", "height": "100%" } }, "header": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174003", "temporary__console_app_url": "/header-url", "style": { "width": "100%", "height": "50px" } }, "hero": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174013", "temporary__console_app_url": "/hero-url", "style": { "width": "100%", "height": "50px" } }, "footer": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174004", "temporary__console_app_url": "/footer-url", "style": { "width": "100%", "height": "30px" } }, "main": { "title": "My website", "style": { "width": "100%", "height": "80px", "padding": "10px 20px" }, "rendering_type": "flow", "console_app_configurations": [ { "title": "Credentials", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174006", "temporary__console_app_url": "/app1", "url_suffix": "/credentials" }, { "title": "Configuration Settings", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174007", "temporary__console_app_url": "/app2", "url_suffix": "/configuration-settings" }, { "title": "Partner Options", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174008", "temporary__console_app_url": "/app3", "url_suffix": "/partner-options" } ] } } } ``` application/json Copy ``` { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174007", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174005", "analytics": { "google_analytics_tag": "G-A1BCD2EF3H" }, "open_graph_tags": { "title": "Staircase", "description": "Staircase is a platform for building and deploying web applications.", "image": "https://www.datocms-assets.com/media/example-icons-favicon-dark.ico", "type": "website", "url": "https://www.staircase.co", "site_name": "Staircase", "locale": "en_US" }, "layout_configuration": { "authentication": { "enabled": false }, "main": { "title": "Constant Feedback (Beta)", "rendering_type": "list", "console_app_configurations": [ { "title": "Options", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174006", "temporary__console_app_url": "/a827000000" }, { "title": "Application submission", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa1748931", "temporary__console_app_url": "/a0987627892", "url_suffix": "/application" } ] } } } ``` application/json Copy ``` { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174000", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174001", "layout_configuration": { "authentication": { "enabled": false }, "main": { "title": "A/B Website", "rendering_type": "list", "console_app_configurations": [ { "console_app_configuration_id": "145e8795-eb14-24t3-a2-aaaa174006", "temporary__console_app_url": "https://bing.com", "ratio_based_console_app_configurations": [ { "ratio": 0.5, "console_app_configuration": { "console_app_configuration_id": "145e8795-eb14-24t3-a2-aaaa174006", "temporary__console_app_url": "https://bing.com" } }, { "ratio": 0.5, "console_app_configuration": { "console_app_configuration_id": "245e8795-eb14-24t3-a2-aaaa174007", "temporary__console_app_url": "https://google.com" } } ] } ] } } } ``` application/json Copy ``` { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174007", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174005", "analytics": { "google_analytics_tag": "G-A1BCD2EF3H", "mouseflow_project_identifier": "0710f46a-9441-11ee-8acf-6ae56c4923a6" }, "layout_configuration": { "authentication": { "enabled": false }, "main": { "title": "Constant Feedback (Beta)", "rendering_type": "list", "console_app_configurations": [ { "title": "Options", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174006", "temporary__console_app_url": "/a827000000" }, { "title": "Application submission", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa1748931", "temporary__console_app_url": "/a0987627892", "url_suffix": "/application" } ] } } } ``` application/json Copy ``` { "site_flow_configuration_id": "27372a78-0aae-4bbd-a9be-80688d6346cc", "site_flow_product_id": "a699d986-08b7-4012-bb6f-421d7ae2ce4f", "layout_configuration": { "authentication": { "enabled": true, "show_authentication_on_load": false }, "main": { "title": "Milestone", "rendering_type": "flow", "console_app_configurations": [ { "console_app_configuration_id": "0231ae28-b9cc-4d89-bbaf-ca344d215a7f", "temporary__console_app_url": "/0231ae28-b9cc-4d89-bbaf-ca344d215a7f/", "url_suffix": "/contract" }, { "console_app_configuration_id": "56773f9b-4cea-4faa-b028-670f254fc59e", "temporary__console_app_url": "/56773f9b-4cea-4faa-b028-670f254fc59e/", "url_suffix": "/agree" }, { "console_app_configuration_id": "3e12cbff-fb66-41f3-96be-30835c6d0317", "temporary__console_app_url": "/3e12cbff-fb66-41f3-96be-30835c6d0317/", "url_suffix": "/filter" }, { "console_app_configuration_id": "d901517a-a530-488e-bc4d-3005b4d2288f", "temporary__console_app_url": "/d901517a-a530-488e-bc4d-3005b4d2288f/", "url_suffix": "/subscribe" }, { "console_app_configuration_id": "37556e03-9681-461f-ade3-4b38c6a8e2ef", "temporary__console_app_url": "/37556e03-9681-461f-ade3-4b38c6a8e2ef/", "url_suffix": "/milestone" }, { "console_app_configuration_id": "675ba25d-2b29-40b3-8d83-d93d31b88cb3", "temporary__console_app_url": "/675ba25d-2b29-40b3-8d83-d93d31b88cb3/", "url_suffix": "/profile-settings" } ] } }, "workflows": [ { "id": "12345678-82eb-4522-bc47-f0fcfdd00001", "path": "/", "definition": { "StartAt": "Contracting", "States": { "Contracting": { "Type": "App", "Resource": "0231ae28-b9cc-4d89-bbaf-ca344d215a7f", "Next": "Agreement" }, "Agreement": { "Type": "App", "Resource": "56773f9b-4cea-4faa-b028-670f254fc59e", "Next": "Observatory" }, "Observatory": { "Type": "App", "Resource": "37556e03-9681-461f-ade3-4b38c6a8e2ef", "End": true } } } }, { "id": "12345678-82eb-4522-bc47-f0fcfdd00002", "definition": { "StartAt": "Filters", "States": { "Filters": { "Type": "App", "Resource": "3e12cbff-fb66-41f3-96be-30835c6d0317", "Next": "Subscriptions" }, "Subscriptions": { "Type": "App", "Resource": "d901517a-a530-488e-bc4d-3005b4d2288f", "End": true } } } } ] } ``` ##### Response 400422 application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 10 fields | Field | Type | Description | | --- | --- | --- | | `site_flow_configuration_id` | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `site_flow_product_id` | `string` | The ID of the site flow product.Example `6c5f392f-1ee7-41-9a3d-3b2d08b954fd` | | `analytics` | `object` | Analytics configuration. | | `google_analytics_tag` | `string` | Google Analytics tag.Example `G-A1BCD2EF3H` | | `google_analytics_server_url` | `string` | Google Analytics Container Server URL.Example `https://ss-tagging.moore-dev.staircaseapi.com` | | `advertiser_correlation_key` | `string` | Advertiser correlation key.`utm_source`Example `utm_source` | | `mouseflow_project_identifier` | `string` | Mouseflow project identifier.Example `0710f46a-9441-11ee-8acf-6ae56c4923a6` | | `google_analytics_tracking_parameters` | `string[]` | List of GA custom tracking parameters. | | `facebook_pixel_id` | `string` | Facebook pixel ID.Example `1234567890123456` | | `facebook_pixel_domain_verification` | `string` | Facebook tracking domain name verification to be put in meta head tag.Example `1234567890123456` | | `google_tag_manager_id` | `string` | Google Tag Manager ID.Example `GTM-123456` | | `layout_configuration` | `object` | Site layout configuration. | | `favicon` | `object` | Favicon schema. | | `blob_id` | `string` | Blob identifier from Persistence.Example `01H0JANT98QNERDF7EV0S2JJJJ` | | `blob_url`required | `string` | Blob URL.Example `https://cdn.edge.staircaseapi.com/media/si_oi9ju8hy7t627892iju4872h4ucnhwebf32eicmcmji349mmc33im3/favicon-dark.ico` | | `authentication` | `object` | Authentication schema. | | `enabled` | `boolean` | Whether authentication is enabled.Example `true` | | `show_authentication_on_load` | `boolean` | Should the authentication immediately on site load, default TrueExample `true` | | `console_app_configuration` | `object` | — | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `style_mobile` | `object` | — | | `title` | `string` | The title of the app.Example `My App` | | `logout_url` | `string (uri)` | The logout URL. The user will land on this page when logout is requested by the app.Example `https://staircase.co` | | `access_app_name` | `string` | Access application name. This will be passed to custom auth app via query arguments. Required, when custom auth app is enabled.Example `Staircase` | | `popup` | `object` | Popup layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `left_sidebar` | `object` | Left sidebar layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `right_sidebar` | `object` | Right sidebar layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `header` | `object` | Header layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `hero` | `object` | Hero layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `footer` | `object` | Footer layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `main`required | `object` | Main layout schema. | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `title` | `string` | The title of the app.Example `My App` | | `rendering_type` | `string` | Rendering strategy applied to `console_app_configurations`.`flow``list`Example `flow` | | `console_app_configurations` | `array` | The sequence of apps. | | `change_reload_url_params` | `object` | Dictionary of URL parameters that will be passed as URL query paramerters to `on_change_reload`. Maximum 3 properties can be added. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the main app.Example `true` | | `path_mappings` | `array` | Path mappings configuration. | | `workflows` | `array` | Workflows configuration. | | `error_pages` | `object` | Error pages schema. | | `forbidden` | `object` | Error page schema. | | `page_content`required | `string` | Error page content in HTMLExample `

Oops! Something went wrong. Please, refresh or make sure you're accessing this site from the US.

` | | `cookie_consent` | `object` | Cookie consent schema. | | `popup` | `object` | Cookie consent popup schema. | | `title` | `string` | Cookie consent popup title.Example `Cookie consent` | | `short_text` | `string` | Cookie consent popup short text.Example `We use cookies to improve your experience on our website.` | | `button_ok` | `string` | Cookie consent popup OK button text.Example `OK` | | `button_manage_preferences` | `string` | Cookie consent popup manage preferences button text.Example `Manage preferences` | | `preference_center` | `object` | Cookie consent preference center schema. | | `button_save_preferences` | `string` | Cookie consent preference center save preferences button text.Example `Save preferences` | | `title` | `string` | Cookie consent preference center title.Example `Cookie consent` | | `privacy_policy_url` | `string (uri)` | Privacy policy URL.Example `https://www.staircase.co/privacy-policy` | | `custom_css` | `string` | Custom CSS for the cookie consent popup.Example `body { background-color: #000; }` | | `browser_cookie_domain` | `string` | Browser cookie domain.Example `staircase.co` | | `browser_cookie_expiration_days` | `integer` | Cookie expiration in days.Example `365` | | `open_graph_tags` | `object` | Open Graphs tags schema. | | `title`required | `string` | Open Graphs tags title.Example `Staircase` | | `description`required | `string` | Open Graphs tags description.Example `Staircase is a platform for building and deploying web applications.` | | `image`required | `string (uri)` | Open Graphs tags image.Example `https://cdn.edge.staircaseapi.com/media/si_oi9ju8hy7t627892iju4872h4ucnhwebf32eicmcmji349mmc33im3/favicon-dark.ico` | | `type`required | `string` | Open Graphs tags type.`website`Example `website` | | `url`required | `string (uri)` | Open Graphs tags URL.Example `https://www.staircase.co` | | `site_name`required | `string` | Open Graphs tags site name.Example `Staircase` | | `locale`required | `string` | Open Graphs tags locale.`en_US`Example `en_US` | | `backend` | `object` | Backend configuration schema. | | `domain_name` | `string` | Domain name of the backend.Example `service.staircase.co` | ##### Response `201``application/json` 10 fields Success | Field | Type | Description | | --- | --- | --- | | `site_flow_configuration_id` | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `site_flow_product_id` | `string` | The ID of the site flow product.Example `6c5f392f-1ee7-41-9a3d-3b2d08b954fd` | | `analytics` | `object` | Analytics configuration. | | `google_analytics_tag` | `string` | Google Analytics tag.Example `G-A1BCD2EF3H` | | `google_analytics_server_url` | `string` | Google Analytics Container Server URL.Example `https://ss-tagging.moore-dev.staircaseapi.com` | | `advertiser_correlation_key` | `string` | Advertiser correlation key.`utm_source`Example `utm_source` | | `mouseflow_project_identifier` | `string` | Mouseflow project identifier.Example `0710f46a-9441-11ee-8acf-6ae56c4923a6` | | `google_analytics_tracking_parameters` | `string[]` | List of GA custom tracking parameters. | | `facebook_pixel_id` | `string` | Facebook pixel ID.Example `1234567890123456` | | `facebook_pixel_domain_verification` | `string` | Facebook tracking domain name verification to be put in meta head tag.Example `1234567890123456` | | `google_tag_manager_id` | `string` | Google Tag Manager ID.Example `GTM-123456` | | `layout_configuration` | `object` | Site layout configuration. | | `favicon` | `object` | Favicon schema. | | `blob_id` | `string` | Blob identifier from Persistence.Example `01H0JANT98QNERDF7EV0S2JJJJ` | | `blob_url`required | `string` | Blob URL.Example `https://cdn.edge.staircaseapi.com/media/si_oi9ju8hy7t627892iju4872h4ucnhwebf32eicmcmji349mmc33im3/favicon-dark.ico` | | `authentication` | `object` | Authentication schema. | | `enabled` | `boolean` | Whether authentication is enabled.Example `true` | | `show_authentication_on_load` | `boolean` | Should the authentication immediately on site load, default TrueExample `true` | | `console_app_configuration` | `object` | — | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `style_mobile` | `object` | — | | `title` | `string` | The title of the app.Example `My App` | | `logout_url` | `string (uri)` | The logout URL. The user will land on this page when logout is requested by the app.Example `https://staircase.co` | | `access_app_name` | `string` | Access application name. This will be passed to custom auth app via query arguments. Required, when custom auth app is enabled.Example `Staircase` | | `popup` | `object` | Popup layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `left_sidebar` | `object` | Left sidebar layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `right_sidebar` | `object` | Right sidebar layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `header` | `object` | Header layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `hero` | `object` | Hero layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `footer` | `object` | Footer layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `main`required | `object` | Main layout schema. | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `title` | `string` | The title of the app.Example `My App` | | `rendering_type` | `string` | Rendering strategy applied to `console_app_configurations`.`flow``list`Example `flow` | | `console_app_configurations` | `array` | The sequence of apps. | | `change_reload_url_params` | `object` | Dictionary of URL parameters that will be passed as URL query paramerters to `on_change_reload`. Maximum 3 properties can be added. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the main app.Example `true` | | `path_mappings` | `array` | Path mappings configuration. | | `workflows` | `array` | Workflows configuration. | | `error_pages` | `object` | Error pages schema. | | `forbidden` | `object` | Error page schema. | | `page_content`required | `string` | Error page content in HTMLExample `

Oops! Something went wrong. Please, refresh or make sure you're accessing this site from the US.

` | | `cookie_consent` | `object` | Cookie consent schema. | | `popup` | `object` | Cookie consent popup schema. | | `title` | `string` | Cookie consent popup title.Example `Cookie consent` | | `short_text` | `string` | Cookie consent popup short text.Example `We use cookies to improve your experience on our website.` | | `button_ok` | `string` | Cookie consent popup OK button text.Example `OK` | | `button_manage_preferences` | `string` | Cookie consent popup manage preferences button text.Example `Manage preferences` | | `preference_center` | `object` | Cookie consent preference center schema. | | `button_save_preferences` | `string` | Cookie consent preference center save preferences button text.Example `Save preferences` | | `title` | `string` | Cookie consent preference center title.Example `Cookie consent` | | `privacy_policy_url` | `string (uri)` | Privacy policy URL.Example `https://www.staircase.co/privacy-policy` | | `custom_css` | `string` | Custom CSS for the cookie consent popup.Example `body { background-color: #000; }` | | `browser_cookie_domain` | `string` | Browser cookie domain.Example `staircase.co` | | `browser_cookie_expiration_days` | `integer` | Cookie expiration in days.Example `365` | | `open_graph_tags` | `object` | Open Graphs tags schema. | | `title`required | `string` | Open Graphs tags title.Example `Staircase` | | `description`required | `string` | Open Graphs tags description.Example `Staircase is a platform for building and deploying web applications.` | | `image`required | `string (uri)` | Open Graphs tags image.Example `https://cdn.edge.staircaseapi.com/media/si_oi9ju8hy7t627892iju4872h4ucnhwebf32eicmcmji349mmc33im3/favicon-dark.ico` | | `type`required | `string` | Open Graphs tags type.`website`Example `website` | | `url`required | `string (uri)` | Open Graphs tags URL.Example `https://www.staircase.co` | | `site_name`required | `string` | Open Graphs tags site name.Example `Staircase` | | `locale`required | `string` | Open Graphs tags locale.`en_US`Example `en_US` | | `backend` | `object` | Backend configuration schema. | | `domain_name` | `string` | Domain name of the backend.Example `service.staircase.co` | ##### Other responses `400``422` `GET` `/ordered-flows/{site_flow_configuration_id}` #### View Configuration `getAppConfiguration` #### View Configuration Retrieves the definition. ##### Response 200400404 application/json Copy Success ``` { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174000", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174001", "layout_configuration": { "authentication": { "enabled": false }, "left_sidebar": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174002", "temporary__console_app_url": "/left-sidebar-url", "style": { "width": "250px", "height": "100%" } }, "header": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174003", "temporary__console_app_url": "/header-url", "style": { "width": "100%", "height": "50px" } }, "hero": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174013", "temporary__console_app_url": "/hero-url", "style": { "width": "100%", "height": "50px" } }, "footer": { "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174004", "temporary__console_app_url": "/footer-url", "style": { "width": "100%", "height": "30px" } }, "main": { "title": "My website", "style": { "width": "100%", "height": "80px", "padding": "10px 20px" }, "rendering_type": "flow", "console_app_configurations": [ { "title": "Credentials", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174006", "temporary__console_app_url": "/app1", "url_suffix": "/credentials" }, { "title": "Configuration Settings", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174007", "temporary__console_app_url": "/app2", "url_suffix": "/configuration-settings" }, { "title": "Partner Options", "console_app_configuration_id": "345e8795-eb14-24t3-a2-aaaa174008", "temporary__console_app_url": "/app3", "url_suffix": "/partner-options" } ] } } } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_flow_configuration_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_flow_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site flow configuration ID. | ##### Response `200``application/json` 10 fields Success | Field | Type | Description | | --- | --- | --- | | `site_flow_configuration_id` | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `site_flow_product_id` | `string` | The ID of the site flow product.Example `6c5f392f-1ee7-41-9a3d-3b2d08b954fd` | | `analytics` | `object` | Analytics configuration. | | `google_analytics_tag` | `string` | Google Analytics tag.Example `G-A1BCD2EF3H` | | `google_analytics_server_url` | `string` | Google Analytics Container Server URL.Example `https://ss-tagging.moore-dev.staircaseapi.com` | | `advertiser_correlation_key` | `string` | Advertiser correlation key.`utm_source`Example `utm_source` | | `mouseflow_project_identifier` | `string` | Mouseflow project identifier.Example `0710f46a-9441-11ee-8acf-6ae56c4923a6` | | `google_analytics_tracking_parameters` | `string[]` | List of GA custom tracking parameters. | | `facebook_pixel_id` | `string` | Facebook pixel ID.Example `1234567890123456` | | `facebook_pixel_domain_verification` | `string` | Facebook tracking domain name verification to be put in meta head tag.Example `1234567890123456` | | `google_tag_manager_id` | `string` | Google Tag Manager ID.Example `GTM-123456` | | `layout_configuration` | `object` | Site layout configuration. | | `favicon` | `object` | Favicon schema. | | `blob_id` | `string` | Blob identifier from Persistence.Example `01H0JANT98QNERDF7EV0S2JJJJ` | | `blob_url`required | `string` | Blob URL.Example `https://cdn.edge.staircaseapi.com/media/si_oi9ju8hy7t627892iju4872h4ucnhwebf32eicmcmji349mmc33im3/favicon-dark.ico` | | `authentication` | `object` | Authentication schema. | | `enabled` | `boolean` | Whether authentication is enabled.Example `true` | | `show_authentication_on_load` | `boolean` | Should the authentication immediately on site load, default TrueExample `true` | | `console_app_configuration` | `object` | — | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `style_mobile` | `object` | — | | `title` | `string` | The title of the app.Example `My App` | | `logout_url` | `string (uri)` | The logout URL. The user will land on this page when logout is requested by the app.Example `https://staircase.co` | | `access_app_name` | `string` | Access application name. This will be passed to custom auth app via query arguments. Required, when custom auth app is enabled.Example `Staircase` | | `popup` | `object` | Popup layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `left_sidebar` | `object` | Left sidebar layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `right_sidebar` | `object` | Right sidebar layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `header` | `object` | Header layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `hero` | `object` | Hero layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `footer` | `object` | Footer layout schema. | | `console_app_configuration_id` | `string` | The ID of the console app configuration.Example `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `temporary__console_app_url` | `string (uri)` | The temporary URL of the console app.Example `/app/4ed4be4e-4c4e-4f72-af36-7928d3e1c9ac` | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `main`required | `object` | Main layout schema. | | `style` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `style_mobile` | `object` | — | | `width` | `string` | The width of an element.Example `100%` | | `height` | `string` | The height of an element.Example `50px` | | `padding` | `string` | The padding of an element.Example `10px 20px` | | `margin` | `string` | The margin of an element.Example `5px` | | `display` | `string` | Display value of element.`flex``none`Example `flex` | | `on_change_reload` | `string[]` | The locations to reload when the app changes. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the layout placeholder app.Example `true` | | `title` | `string` | The title of the app.Example `My App` | | `rendering_type` | `string` | Rendering strategy applied to `console_app_configurations`.`flow``list`Example `flow` | | `console_app_configurations` | `array` | The sequence of apps. | | `change_reload_url_params` | `object` | Dictionary of URL parameters that will be passed as URL query paramerters to `on_change_reload`. Maximum 3 properties can be added. | | `inherit_url_path` | `boolean` | Pass url_path from Site to the main app.Example `true` | | `path_mappings` | `array` | Path mappings configuration. | | `workflows` | `array` | Workflows configuration. | | `error_pages` | `object` | Error pages schema. | | `forbidden` | `object` | Error page schema. | | `page_content`required | `string` | Error page content in HTMLExample `

Oops! Something went wrong. Please, refresh or make sure you're accessing this site from the US.

` | | `cookie_consent` | `object` | Cookie consent schema. | | `popup` | `object` | Cookie consent popup schema. | | `title` | `string` | Cookie consent popup title.Example `Cookie consent` | | `short_text` | `string` | Cookie consent popup short text.Example `We use cookies to improve your experience on our website.` | | `button_ok` | `string` | Cookie consent popup OK button text.Example `OK` | | `button_manage_preferences` | `string` | Cookie consent popup manage preferences button text.Example `Manage preferences` | | `preference_center` | `object` | Cookie consent preference center schema. | | `button_save_preferences` | `string` | Cookie consent preference center save preferences button text.Example `Save preferences` | | `title` | `string` | Cookie consent preference center title.Example `Cookie consent` | | `privacy_policy_url` | `string (uri)` | Privacy policy URL.Example `https://www.staircase.co/privacy-policy` | | `custom_css` | `string` | Custom CSS for the cookie consent popup.Example `body { background-color: #000; }` | | `browser_cookie_domain` | `string` | Browser cookie domain.Example `staircase.co` | | `browser_cookie_expiration_days` | `integer` | Cookie expiration in days.Example `365` | | `open_graph_tags` | `object` | Open Graphs tags schema. | | `title`required | `string` | Open Graphs tags title.Example `Staircase` | | `description`required | `string` | Open Graphs tags description.Example `Staircase is a platform for building and deploying web applications.` | | `image`required | `string (uri)` | Open Graphs tags image.Example `https://cdn.edge.staircaseapi.com/media/si_oi9ju8hy7t627892iju4872h4ucnhwebf32eicmcmji349mmc33im3/favicon-dark.ico` | | `type`required | `string` | Open Graphs tags type.`website`Example `website` | | `url`required | `string (uri)` | Open Graphs tags URL.Example `https://www.staircase.co` | | `site_name`required | `string` | Open Graphs tags site name.Example `Staircase` | | `locale`required | `string` | Open Graphs tags locale.`en_US`Example `en_US` | | `backend` | `object` | Backend configuration schema. | | `domain_name` | `string` | Domain name of the backend.Example `service.staircase.co` | ##### Other responses `400``404` `POST` `/event-loop/poll/{site_flow_configuration_id}` #### Check Session `pollSessionProgress` This endpoint generates a new session and transaction IDs, Session ID is used to differentiate between different sessions of the same user who is coming from the same resource, and possibly several times. This API is an entrypoint for the shell application of the Site to start the communication with the backend Site. #### Authentication If the configuration has the authentication enabled, the Site will perform soft-validation of the user and store email address of the person logging in. The email address will be stored in the `person[0].email_address`. Show the rest Site checks for `email_address` and `custom:person_identifier` JWT claims to find user's email address and GUID. Later on, Site will populate transaction (marked by `transaction_id`) with the email address of the user signed in. Site populates the transaction in a synchronous manner, i.e., the transaction will be populated before the response is returned. #### Advertiser Key Correlation When the website is set up with the advertiser key linkage, it will search for the correlating key within query parameters of the URL. This key should be present in the query parameters and its value should correspond to the advertiser's ID. If a prior session is already in place, the website will bypass both the correlating key and the associated advertisement information. If not, the website will initiate a new session, and the advertisement details will be stored under this fresh transaction, which is marked by a `transaction_id`. ##### Example Define the advertiser key correlation key in the configuration: ``` { "analytics": { "advertiser_correlation_key": "utm_source" }, "layout_configuration": {...} } ``` Set the URL in the advertisement platform (e.g. Google Ads) to include the correlating key: ``` ``` Here the correlating key is `utm_source` and the value is `91319ebc-3c29-4e65-801c-91d4e32073a5`, which represents the advertiser's ID. ##### Response 200400404 application/json Copy Successfully retrieved the current app ID ``` { "transaction_id": "5aa4be4e-4c4e-42-af36-9ddaaa2322ec", "session_id": "6ed4be4e-4c4e-42-af36-9ddaaa2322ec", "trace_id": "OOWDANFA" } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_flow_configuration_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-sc-trace-id` required | `string` header | `01HQQEHAPB8EVDA35QDTMEEV9X` | The trace ID | | `site_flow_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site flow configuration ID. | | `session_id` | `string` query | `5ed4be4e-4c4e-42-af36-9ddaaa2322ec` | An existing session ID (optional) | | `transaction_id` | `string` query | `5aa4be4e-4c4e-42-af36-9ddaaa2322ec` | An existing transaction ID associated with the session ID (optional) | | `Authorization` | `string` header | `` | Authentication token | ##### Response `200``application/json` 3 fields Successfully retrieved the current app ID | Field | Type | Description | | --- | --- | --- | | `session_id` | `string` | The session ID, either provided or newly generatedExample `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `transaction_id` | `string` | The transaction ID, either provided or newly generatedExample `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | | `trace_id` | `string` | The sc-trace-idExample `4ed4be4e-4c4e-42-af36-7928d3e1c9ac` | ##### Other responses `400``404` `GET` `/ordered-flows` #### List Configurations `listAppConfigurations` List Configuration #### List Configurations Retrieves list of registered configurations. ##### Response 200400422 application/json Copy Success ``` { "site_flow_configurations": [ { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174000", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174001" }, { "site_flow_configuration_id": "345e8795-eb14-24t3-a2-aaaa174004", "site_flow_product_id": "345e8795-eb14-24t3-a2-aaaa174088" } ], "page": { "count": 2, "next_token": null } } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | The response can include a limited number of results along with a `next_token` value. You can use this `next_token` value in a subsequent API request to retrieve the next batch of items. `next_token` is located under the `page` object in the response. | | `limit` | `integer` query | `10` | List configurations limit | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `site_flow_configurations`required | `array` | Represents the array of flow configurations. | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Other responses `400``422` `DELETE` `/ordered-flows/{site_flow_configuration_id}` #### Remove Configuration `removeAppConfiguration` #### Remove Configuration Removes configurations with all of its layouts. ##### Response 400404 application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_flow_configuration_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_flow_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site flow configuration ID. | ##### Other responses `204``400``404` `POST` `/system-feedback/ordered-flows/{site_flow_configuration_id}/sessions/{session_id}/transactions/{transaction_id}` #### Collect System Feedback `collectSystemFeedback` #### Collect System Feedback Collects system feedback for a given session and transaction IDs. | Event type | Description | `base_elapsed_time` | | --- | --- | --- | | `start_session` | Indicates the start of a session. | The time elapsed in milliseconds since the start of the interaction with site. | | `page_change` | Indicates a page change. | The time elapsed in milliseconds since the user has opened the page. | | `end_session` | Indicates the end of a session. | The time elapsed in milliseconds since the start of the session. | | `error` | Indicates error. | Can be set to `0` | | `console_app_loaded` | Indicates the console app has been loaded. | The time elapsed in milliseconds since the "iframe" started loading. | ##### Request Start SessionConsole App LoadedPage ChangeEnd SessionSampled (Advanced) application/json Copy ``` { "events": [ { "event_type": "start_session", "base_elapsed_time": 0 } ] } ``` application/json Copy ``` { "events": [ { "event_type": "console_app_loaded", "base_elapsed_time": 1.2, "modifiers": { "configuration_id": "345e8795-eb14-24t3-a2-aaaa1748931" } } ] } ``` application/json Copy ``` { "events": [ { "event_type": "page_change", "base_elapsed_time": 9982 } ] } ``` application/json Copy ``` { "events": [ { "event_type": "end_session", "base_elapsed_time": 112500 } ] } ``` application/json Copy ``` { "events": [ { "event_type": "start_session", "base_elapsed_time": 0 }, { "event_type": "page_change", "base_elapsed_time": 3215 }, { "event_type": "page_change", "base_elapsed_time": 6152 } ] } ``` ##### Response 200400404422 application/json Copy Success ``` { "status": "SUCCEEDED" } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_flow_configuration_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_flow_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site flow configuration ID. | | `session_id` required | `string` path | `5ed4be4e-4c4e-42-af36-9ddaaa2322ec` | An existing session ID (required) | | `transaction_id` required | `string` path | `5aa4be4e-4c4e-42-af36-9ddaaa2322ec` | An existing transaction ID associated with the session ID (required) | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `user` | `object` | Represents user object | | `user_guid`required | `string` | Global Unique Identifier of the user | | `location`required | `object` | Represents location object | | `ip_address` | `string` | IP address of the user | | `device`required | `object` | Represents device object | | `brand` | `string` | Device Brand | | `model` | `string` | Device Model | | `screen_resolution` | `string` | Screen resolution | | `browser_name` | `string` | Browser name | | `browser_version` | `string` | Browser version | | `operating_system` | `string` | Device OS | | `events`required | `array` | A list of event objects that contain system feedback information. | | `session_telemetry` | `object` | Represents session telemetry | | `start_time` | `string` | Session start timestamp | | `end_time` | `string` | Session end timestamp | | `load_time` | `integer` | Load time | | `time_spent` | `integer` | Time spent on site | | `number_of_clicks` | `integer` | Number of clicks on site | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `status`required | `string` | The status of the operation.`SUCCEEDED`Example `SUCCEEDED` | ##### Other responses `400``404``422` `GET` `/deployments` #### List Deployments `listLatestSitesDeployments` #### List Deployments Retrieves list of active deployments. ##### Response 200400422 application/json Copy Success ``` { "deployments": [ { "domain_name": "site-acdc27.product.staircaseapi.com", "site_flow_configuration_id": "15a820a6-cac9-4b-a7b1-d364b26d7f69" } ], "page": { "next_token": null, "count": 1 } } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | The response can include a limited number of results along with a `next_token` value. You can use this `next_token` value in a subsequent API request to retrieve the next batch of items. `next_token` is located under the `page` object in the response. | | `limit` | `integer` query | `10` | List deployments limit | | `site_flow_configuration_id` | `string` query | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site Flow Configuration ID. Exclusive with `site_domain_name` parameter. | | `site_domain_name` | `string` query | `site-b0964187.bohr.staircaseapi.com` | Domain name of the site. Can not be custom domain name, only deployment one is accepted. Exclusive with `site_flow_configuration_id` parameter. | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `deployments`required | `object[]` | Represents the array of flow configurations. | | `site_flow_configuration_id`required | `string` | The ID of the site flow configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `domain_name`required | `string` | Site full domain name.Example `site-000aaa.docs.staircaseapi.com` | | `transaction_id` | `string` | Deployment transaction ID. Omitted when queried with `site_domain_name` query filter.Example `01H021M9X10AN9XNNJ8THMMMMM` | | `page`required | `object` | Page information. Contains basic information of the current page returned. | | `count`required | `integer` | Count of items that were retrieved for this page.Example `1` | | `next_token`required | `string` | If this field exists in the page information collection, it means you can continue querying for other items, using this token in the query parameters of the following request.Example `eNolzLEKwkAQRdFfeZnGRvwAWxtBbOwsh2TcXYxvZJ2NBPHfNVpduMV5yf4gW8k2d5i9rSbDxRsHKGH6CKvfpoRCRDYctV4t7qP2hsH7djOGRnHKWk4LtHOmqtHG3+1w/ptPJ+iRC9NG3h89BijN` | ##### Other responses `400``422` `PUT` `/deployments` #### Deploy Configuration `deployAppConfiguration` #### Deploy Configuration Sites are installed under environment's subdomain. Each site configuration gets its own short ID, which is used in the future domain name of the site. Example of the URL: site-3065e3b5.xchange.staircaseapi.com. ##### Observe deployment status Events are sent in payloads of a “HTTP requests” using `POST` method. ``` { "$schema": "", "additionalProperties": true, "type": "object", "required": ["status", "transaction_id", "domain_name"], "description": "Schema for the payload event emitted to callback.", "properties": { "transaction_id": { "type": "string", "description": "Transaction identifier. Unique per deployment and managed by Site." }, "status": { "type": "string", "description": "Provisioning status.", "enum": ["SUCCEEDED", "FAILED"] }, "domain_name": { "type": "string", "description": "Domain name of the site." }, "error": { "type": "object", "additionalProperties": true, "description": "Deployment has failed unexpectedly. Error details are provided in this object. Note that you should contact the support team when the error occurs." } } } ``` ###### Troubleshooting Events are dispatched once the deployment process completes. Show the rest An event is deemed as successfully delivered when its recipient acknowledges with an HTTP status code that falls within the range of successful responses. If an event isn't successfully delivered, the Site will make six additional attempts to resend the event, with each attempt following an exponential back off strategy. To confirm the propagation of the webhook, you can utilize Retrieve Transaction Collections with the transaction ID, which is returned during the initialization of deployment. ##### Request application/json Copy ``` { "site_flow_configuration_id": "6374c7f8-13fa-454a-8587-bd29724346f7", "callback_url": "https://webhooks.staircaseapi.com/persistence/bridge/o09jun2kjhjkkkiDj" } ``` ##### Response 400404422 application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_flow_configuration_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `site_flow_configuration_id`required | `string` | Site flow configuration ID.Example `6374c7f8-13fa-454a-8587-bd29724346f7` | | `callback_url`required | `string` | Callback URL.Example `https://webhooks.staircaseapi.com/persistence/bridge/o09jun2kjhjkkkiDj` | ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `domain_name`required | `string` | Generated domain name for the site.Example `site-abc00def.xchange.staircaseapi.com` | | `transaction_id`required | `string` | Transaction ID.Example `01H021M9X10AN9XNNJ8THMMMMM` | | `callback_url` | `string` | The callback URL is returned as is. The value will match the input `callback_url`.Example `https://webhooks.staircaseapi.com/persistence/bridge/o09jun2kjhjkkkiDj` | | `site_flow_configuration_id` | `string` | Site flow configuration ID. The value will match the input `site_flow_configuration_id`.Example `6374c7f8-13fa-454a-8587-bd29724346f7` | ##### Other responses `400``404``422` `POST` `/event-loop/sso/{site_flow_configuration_id}` #### Request SSO Links `requestSSOLinks` Retrieves SSO links for the specified flow configuration. This is an automated process, intended for the browser environment by the frontend application. If the origin is validated, and certain conditions are met – creates a new SSO application and returns SSO links. When the same origin already contains a mapped SSO application – returns SSO links. #### Limitations Only specific domain names are eligible for automatic SSO application issuance. The maximum amount of automatically managed SSO applications is `3` per site flow configuration. ##### Response 200400404422 application/json Copy SSO links generated successfully. ``` { "access_sso_links": { "sso_provider": "Google", "sso_signin_link": "https://auth.bah.staircaseapi.com/oauth2/authorize?identity_provider=Google&redirect_uri=https://site-9873489.bah.staircaseapi.com&response_type=TOKEN&client_id=93414o1ml23chevrloh762oO9d&scope=email+openid+profile", "sso_logout_link": "https://auth.bah.staircaseapi.com/logout?client_id=93414o1ml23chevrloh762oO9d&response_type=TOKEN&logout_uri=https://site-9873489.bah.staircaseapi.com/logout" }, "access_app_identifier": "6374c7f8-13fa-454a-8587-bd2000007" } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_flow_configuration_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_flow_configuration_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site flow configuration ID. | | `sso_provider` required | `string` query | `Google` | The provider for Single Sign-On (SSO). Currently, only Google is supported. | ##### Response `200``application/json` 2 fields SSO links generated successfully. | Field | Type | Description | | --- | --- | --- | | `access_sso_links`required | `object` | Object proxied from Access. Contains the SSO links for the specified provider. | | `sso_provider` | `string` | The provider for Single Sign-On (SSO). Currently, only Google is supported.Example `Google` | | `sso_signin_link` | `string` | The SSO link for the specified provider.Example `https://auth.bah.staircaseapi.com/oauth2/authorize?identity_provider=Google&redirect_uri=https://site-9873489.bah.staircaseapi.com&response_type=TOKEN&client_id=93414o1ml23chevrloh762oO9d&scope=email+openid+profile` | | `sso_logout_link` | `string` | The SSO logout link for the specified provider.Example `https://auth.bah.staircaseapi.com/logout?client_id=93414o1ml23chevrloh762oO9d&response_type=TOKEN&logout_uri=https://site-9873489.bah.staircaseapi.com/logout` | | `access_app_identifier`required | `string (uuid)` | Access application identifier in UUID format.Example `6374c7f8-13fa-454a-8587-bd2000007` | ##### Other responses `400``401``404``407``422` `POST` `/event-loop/logout` #### Logout `logout` Resets access and ID token cookies for the current session. Response contains same cookies from the request with expiration date set to the past. ##### Response application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `__sc.acact` required | `string` cookie | `access-token` | Authentication access token | | `__sc.acidt` required | `string` cookie | `openid ID token in JWT format.` | Authentication ID token | ##### Other responses `204``400` `GET` `/event-loop/workflows` #### Get State[new] `getState` Get State Get state for the current user. ##### Response 200 SomeState200 NoState400401422 application/json Copy Success ``` { "current_console": "89e820a6-cac9-4b-a7b1-d364b26d5552" } ``` application/json Copy Success ``` {} ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 401 status code occurs when a request is unauthorized. ``` { "error": { "message": "Token is not valid.", "reason": "Unauthorized." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `__sc.acact` required | `string` cookie | `access-token` | Authentication access token | | `__sc.acidt` required | `string` cookie | `openid ID token in JWT format.` | Authentication ID token | | `site_configuration` required | `string` query | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site configuration ID. | | `site_workflow` required | `string` query | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site workflow ID. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `current_console` | `string` | Current console ID.Example `89e820a6-cac9-4b-a7b1-d364b26d5552` | ##### Other responses `400``401``422` `POST` `/event-loop/workflows` #### Set State[new] `setState` Set State Set state for the current user. ##### Request application/json Copy ``` { "site_configuration": "6374c7f8-13fa-454a-8587-bd29724346f7", "site_workflow": "6374c7f8-13fa-454a-8587-bd29724346f7", "current_console": "89e820a6-cac9-4b-a7b1-d364b26d5552" } ``` ##### Response 400401422 application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 401 status code occurs when a request is unauthorized. ``` { "error": { "message": "Token is not valid.", "reason": "Unauthorized." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `__sc.acact` required | `string` cookie | `access-token` | Authentication access token | | `__sc.acidt` required | `string` cookie | `openid ID token in JWT format.` | Authentication ID token | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `site_configuration`required | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `site_workflow`required | `string` | The ID of the site workflow configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `current_console`required | `string` | Current console ID.Example `89e820a6-cac9-4b-a7b1-d364b26d5552` | ##### Other responses `204``400``401``422` ### Distribute `GET` `/pipeline/products/{product_name}/artifacts` #### Get Product Artifacts `getProductArtifacts` ##### Response 200400 application/json Copy Success response ``` { "artifacts": [ "Site", "Site Health Configuration", "Site Connector Configuration", "Site Documentation Configuration" ] } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `artifacts` | `string[]` | The list of artifacts | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `DELETE` `/pipeline/products/{product_name}/artifacts/{artifact_tag}` #### Delete Product Artifact `deleteProductArtifact` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | | `artifact_tag` required | `string` path | `SiteDocumentationConfig` | Product Artifact Tag. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `POST` `/pipeline/publish` #### Publish Artifact `publishArtifact` Publish your Artifacts You can add Site product in your DevOps pipeline. Site is compatible with Staircase's other Ship products. Site can accept the bundle of the Market Place as an artifact input. #### Swagger Files You need to specify you swagger path in your `service.yml` or `data.yml' file. ``` documentation: path: requirements/swagger.yml ``` Also, if you don't want to publish swagger, you can specify it in the yml. Default is true Show the rest ``` documentation: publish: false path: requirements/swagger.yml ``` If you want to put link to a file in your swagger, you can use Upload Public Content API and place the `download_url` in your swagger file. #### Product Component Ordering If you want to set order for your product's components, in service yml file you can specify it as follows: ``` documentation: publish: true path: requirements/swagger.yml components: ordering: - 'Tech: Ontology' - 'Tech: Open Api' - 'Tech: Component Ordering' - 'Tech: Overview' - 'Tech: Quick Start Guides' - 'Marketing: Companies' - 'Marketing: Product Ontology' - 'Distribute' ``` ! Note: If your product has multiple artifacts due to microservices, you can choose one main configuration repo for your product's site(documentation) config and set components' order. #### Product Overview Page All products have an overview page which describes the product usage and workflow. The product’s overview page is located in the product repo /requirements folder. File name is “overview.md”. Content in the /requirements/overview.md file is displayed when the product name is clicked in the api.staircase.co left-hand navigation bar. #### Product Icons/Images Product icons and images can be put in the product repo /requirements/public folder. They can be referenced in the overview file like `Alt Text`. Site will automatically upload images and modify the image paths to point to the correct URL. ! Note: You should avoid using spaces at your content name #### Product Quick Start Guides Detailed guide of how-to attach product Quick Start Guides under the product bundle #### Links to custom files Any downloadable file you want to serve in overview page should be placed to product repo /requirements/public folder. They can be referenced in the overview file like `Link Text`. Site will automatically upload the files and modify the path to point to the correct URL. ##### Left-Hand Navigation Sidebar The left-hand navigation sidebar for api.staircase.co is automatically built based on custom extensions in the product’s swagger file. Every swagger file needs these 3 custom extensions added after the “title” property. You only need to specify these extensions once per swagger file. - `x-product-family:` family the product should be listed under - `x-product-category:` category the product should be listed under - `x-product-name:` product name. Every endpoint within the swagger file needs these 3 custom extensions added after the “path” property: - `x-product-component:` the name of the component under which the endpoint should be grouped - `x-product-endpoint:` the name of the endpoint - `x-product-sequence:` the sequence in which the endpoint should appear under the component. Both: `x-product-component` and/or `x-product-endpoint` can be defined as: - `x-product-*: value[new]` it will add "NEW" pill to the x-product-* - `x-product-*: value[deprecated]` it will add "DEPRECATED" pill to the x-product-* - `x-product-*: value[warning]` it will add "WARNING" pill to the x-product-* - `x-product-*: value[updated]` it will add "UPDATED" pill to the x-product-* ! Note: `x-product-*` value at Technical Site will not contain `[*pill*]` text while rendering. It will render pill instead. ##### Multiple Swagger Files for One Product To publish multiple swagger files to the same product, make sure that the x-product-name extension in every repo’s swagger file must be given the same product name. For example, if the “Tax” product is associated with 5 different swagger files and repos, every swagger file/repo must provide the name “Tax” as x-product-name. The product name must match a product name in the product ontology. ##### Request application/json Copy ``` { "artifact_url": "https://dev-marketplace-bundles-bucket-us-east-1-581813358386.s3.amazonaws.com/SERVICE/Automated%20Underwriting%20System%20%28AUS%29/01G110WHPJFCGMD0YHF8G6PAKB?AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1650459612", "artifact_tag": "Automated Underwriting System (AUS)" } ``` ##### Response 200400 application/json Copy Approval uploaded ``` { "publish_id": "01G13DH3PRSTQQQRK186PWF9GC" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `artifact_url` | `string` | Artifact URL | | `artifact_tag` | `string` | Artifact Tag | ##### Response `200``application/json` 1 fields Approval uploaded | Field | Type | Description | | --- | --- | --- | | `publish_id` | `string` | Publish started | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/pipeline/publish/{publish_id}` #### Get Publish Status `getProductPublish` ##### Response 200400 application/json Copy Success response ``` { "status": "COMPLETED", "message": "Published Successfully" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | | `publish_id` required | `string` path | `01G13DH3PRSTQQQRK186PWF9GC` | Publish ID. | ##### Response `200``application/json` 2 fields Success response | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Publish Status`COMPLETED``FAILED``RUNNING` | | `message` | `string` | Message | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### SuCo `POST` `/process` #### Match with MDL `process` Process ##### Request application/json Copy ``` { "callback_url": "https://callback.url", "data": { "people": [ { "@id": "1", "first_name": "John", "last_name": "Doe" } ], "addresses": [ { "@id": "2", "address_line_1": "123 Main St", "city": "Springfield", "state_code": "IL", "postal_code": "62701" } ] } } ``` ##### Response 202400 application/json Copy Accepted ``` { "message": "Accepted" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string` | Callback URLExample `https://callback.url` | | `data` | `object` | Data | ##### Response `202``application/json` 1 fields Accepted | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ### Tech: Ontology `POST` `/tech/ontology` #### Save Product Ontology `saveOntology` Product Ontology defines concepts, relations among them and axioms to be applied in the complex product modeling domain Ontology consists of product families. Every family is a set of products which share a common, managed set of features that satisfy the specific needs of a particular market segment and are developed from a common set of core assets in a prescribed way Publish products ontology. It will be used to show ordered product families, categories, and products in the navigation bar. When ontology contains not published product, then it will not be shown in the navigation bar. When ontology does not have a product, it will be shown at the end of the list. ##### Request application/json Copy ``` { "ontology": { "product_families": [ { "name": "Mortgage Products", "product_categories": [ { "name": "Data Manager", "products": [ { "name": "Document Classification" }, { "name": "Data Extraction" }, { "name": "Ground Truth Labeling" } ] }, { "name": "Borrower", "products": [ { "name": "Employment" }, { "name": "Credit" }, { "name": "Income" }, { "name": "Assets" } ] }, { "name": "Collateral", "products": [ { "name": "Automated Valuation Model (AVM)" }, { "name": "Property Taxes" } ] }, { "name": "Loan", "products": [ { "name": "Pricing" }, { "name": "Fees" } ] }, { "name": "Adapters", "products": [ { "name": "LOS" } ] } ] }, { "name": "Mortgage Processes", "product_categories": [ { "name": "Application", "products": [ { "name": "Pre-Approval" } ] }, { "name": "Underwriting", "products": [ { "name": "Loan Eligibility" }, { "name": "Automated Underwriting System (AUS)" } ] }, { "name": "Servicing", "products": [ { "name": "Loanboarding" } ] } ] } ] } } ``` ##### Response 201 application/json201 application/json400 application/json Copy Success response ``` { "DevOps": { "Ship": [ "Build", "Deploy" ], "Distribute": [ "Marketplace", "Environment", "Documentation" ] } } ``` application/json Copy Success response ``` { "ontology": { "product_families": [ { "name": "Mortgage Products", "product_categories": [ { "name": "Data Manager", "products": [ { "name": "Document Classification" }, { "name": "Data Extraction" }, { "name": "Ground Truth Labeling" } ] }, { "name": "Borrower", "products": [ { "name": "Employment" }, { "name": "Credit" }, { "name": "Income" }, { "name": "Assets" } ] }, { "name": "Collateral", "products": [ { "name": "Automated Valuation Model (AVM)" }, { "name": "Property Taxes" } ] }, { "name": "Loan", "products": [ { "name": "Pricing" }, { "name": "Fees" } ] }, { "name": "Adapters", "products": [ { "name": "LOS" } ] } ] }, { "name": "Mortgage Processes", "product_categories": [ { "name": "Application", "products": [ { "name": "Pre-Approval" } ] }, { "name": "Underwriting", "products": [ { "name": "Loan Eligibility" }, { "name": "Automated Underwriting System (AUS)" } ] }, { "name": "Servicing", "products": [ { "name": "Loanboarding" } ] } ] } ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `ontology` | `object` | Ontology | | `product_families` | `object[]` | Family List | | `name` | `string` | Family name | | `product_categories` | `object[]` | Category List | | `name` | `string` | Category name | | `products` | `object[]` | Product List | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `201``403` `DELETE` `/tech/ontology` #### Delete Product Ontology `deleteOntology` Delete products ontology Delete products ontology. ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `GET` `/tech/ontology` #### Retrieve Product Ontology `getOntology` Retrieve products ontology Retrieve products ontology. ##### Response 200 application/json200 application/json400 application/json Copy Success response ``` { "DevOps": { "Ship": [ "Build", "Deploy" ], "Distribute": [ "Marketplace", "Environment", "Documentation" ] } } ``` application/json Copy Success response ``` { "ontology": { "product_families": [ { "name": "Mortgage Products", "product_categories": [ { "name": "Data Manager", "products": [ { "name": "Document Classification" }, { "name": "Data Extraction" }, { "name": "Ground Truth Labeling" } ] }, { "name": "Borrower", "products": [ { "name": "Employment" }, { "name": "Credit" }, { "name": "Income" }, { "name": "Assets" } ] }, { "name": "Collateral", "products": [ { "name": "Automated Valuation Model (AVM)" }, { "name": "Property Taxes" } ] }, { "name": "Loan", "products": [ { "name": "Pricing" }, { "name": "Fees" } ] }, { "name": "Adapters", "products": [ { "name": "LOS" } ] } ] }, { "name": "Mortgage Processes", "product_categories": [ { "name": "Application", "products": [ { "name": "Pre-Approval" } ] }, { "name": "Underwriting", "products": [ { "name": "Loan Eligibility" }, { "name": "Automated Underwriting System (AUS)" } ] }, { "name": "Servicing", "products": [ { "name": "Loanboarding" } ] } ] } ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``403` ### Tech: Open Api `POST` `/tech/products` #### Add Product Documentation `saveProduct` #### Publish Your Open API Definition of your product 1. Every swagger file needs these 3 custom extensions added after the “title” property. You only need to specify these extensions once per swagger file. - `x-product-family:` family the product should be listed under, either Mortgage, Platform or DevOps - `x-product-category:` category the product should be listed under (e.g. Borrower, Distribute, Integrate) - `x-product-name:` product name. This name must match a product name in the product ontology spreadsheet. 1. Every endpoint within the swagger file needs these 3 custom extensions added after the “path” property: - `x-product-component:` the name of the component under which the endpoint should be grouped - `x-product-endpoint:` the name of the endpoint - `x-product-sequence:` the sequence in which the endpoint should appear under the component. ##### Request application/json Copy ``` { "swagger": {} } ``` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `swagger` | `object` | Open API Definition | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `202``403` `DELETE` `/tech/products/{product_name}` #### Delete Product Documentation `deleteProduct` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `GET` `/tech/sidebar` #### Get sidebar `getSideBar` Retrieve the sidebar data. ##### Response `200``application/json` 1 fields Success response. | Field | Type | Description | | --- | --- | --- | | `products_side_bar` | `string` | List of products for sidebar. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/tech/products/{product_name}/openapi/paths/{openapi_method_id}` #### Get Open API Method Definition `getOpenApiPath` Get Open API path definitions. ##### Response 200400 application/json Copy Success response ``` { "openapi_paths": { "method": "get", "service_name": "Build", "base_path": "infra-builder", "env_domain": "template.staircaseapi.com", "path": "/builds/{build_id}", "sidebar_path": "/docs/DevOps/Ship/Build/get-build-status", "operation_id": null, "description": "**Retrieve Service Build Status**", "summary": "Get build status", "request_body": null, "responses": [ { "response_code": "200", "content": { "application/json": { "schema": { "type": "object", "properties": { "build_id": { "type": "string", "description": "Unique build id which was returned when build was started", "format": "uuid" }, "status": { "type": "string", "description": "Build status (IN_PROGRESS, FAILED, SUCCEEDED)" }, "artifacts_url": { "type": "string", "format": "url", "description": "Artifact URL if build was successfully completed" }, "logs": { "type": "array", "description": "Build Logs which can be used for build problem investigation", "items": { "type": "string" } }, "metadata": { "type": "object", "description": "Metadata generated by build" } } }, "example": { "build_id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "status": "SUCCEEDED", "metadata": { "service-assessor": { "id": "devops-code-assessor:e5dcb19e-b025-4255-a42f-7f501456703c", "timestamp": 1623399920.05132, "version": "1.0.0", "issuer": "https://build.staircaseapi.com/code-assessor", "status": "SUCCEEDED" }, "service-code": { "id": "0da65dfd-9753-4bb4-8853-06e608979e73", "timestamp": 1623399796.747468, "version": "1.1", "status": "SUCCEEDED", "commit_hash": "c366156be0d8a39ce9a7bf85a5f5d5fc1a59ba4c", "issuer": "https://build.staircaseapi.com/code" }, "service-builder": { "id": "7ac245b7-2f93-4850-8e86-abfdfd3b0a76", "timestamp": 1623400025.2152104, "version": "1.1", "status": "SUCCEEDED", "bundle_type": "SERVICE", "issuer": "https://build.staircaseapi.com/infra-builder" } }, "artifacts_url": "https://builder-api-dev-codebuilddevbucket-kkwqngshvjap.s3.amazonaws.com/build-main/build/7ac245b7-2f93-4850-8e86-abfdfd3b0a76/build.zip", "logs": [] } } }, "description": "200 response" } ] } } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | | `openapi_method_id` required | `string` path | `publishDocumentation` | Path which was specified as 'operationId' in api method definition in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `openapi_paths` | `object` | Open API paths definition. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Tech: Component Ordering `GET` `/tech/products/{product_name}/components/ordering` #### Retrieve Product Component Ordering `retrieveProductComponentOrdering` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `200``403` `POST` `/tech/products/{product_name}/components/ordering` #### Add Product Component Ordering `addProductComponentOrdering` ##### Request application/json Copy ``` { "order_list": [ "COMP_1", "COMP_2", "COMP_3" ] } ``` ##### Response 200400 application/json Copy Success response ``` { "order_list": [ "COMP_1", "COMP_2", "COMP_3" ] } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `order_list` | `string[]` | Component Ordering | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `order_list` | `string[]` | Component Ordering | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `401``application/json` 1 fields Not Authorized | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Tech: Quick Start Guides `DELETE` `/tech/products/{product_name}/quickstart-guides/{quickstart_guide_id}` #### Delete Quick Start Guide `deleteQuickStartGuide` ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | | `quickstart_guide_id` required | `string` path | `how-to-distribute-site` | Quick Start Guide Id. | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `GET` `/tech/products/{product_name}/quickstart-guides` #### Retrieve Quick Start Guides `getProductQuickStartGuides` ##### Response 200400 application/json Copy Success response ``` [ { "id": "how-to-distribute-site", "name": "How To Distribute Site", "description": "Description of How To Distribute Site", "type": "markdown", "data": "\n

\n\n

" } ] ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 5 fields Success response | Field | Type | Description | | --- | --- | --- | | `id` | `string` | Quick Start Guide ID.Example `how-to-distribute-site` | | `name` | `string` | Quick Start Guide name.Example `How To Distribute Site` | | `description` | `string` | Quick Start Guide description.Example `Description of How To Distribute Site` | | `type` | `string` | Quick Start Guide type.Example `markdown` | | `data` | `string` | Quick Start Guide content.Example `

` | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `POST` `/tech/products/{product_name}/quickstart-guides` #### Add Quick Start Guide `postQuickStartGuide` Add Quick Start Guide #### Attaching Quick Start Guides via bundle Site platform is able to parse Quick Start Guides from your bundle automatically. To get your Quick Start Guides be parsed from your bundle, just create the following structure: ``` /requirements/quick-start-guides/dictionary.json /requirements/quick-start-guides/guide1.md /requirements/quick-start-guides/guide2.md ...etc ``` /requirements/quick-start-guides/dictionary.json Show the rest This file contains your Quick Start Guides descriptions, names and paths to MD files. Example: ``` { "guide_1_name": { "description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam.", "path": "guide1.md" }, "guide_2_name": { "description": "Quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.", "path": "guide2.md" } } ``` ! Note: Quick Start Guide Definition can accept an images/custom files described at Site: Publish Artifact endpoint. ! Note: Custom Files/images should be present under the same product name as Quick Start Guide ##### Request application/json Copy ``` { "name": "How to publish documentation via pipeline", "description": "Complete how-to...", "type": "markdown", "data": "\n

\n\n

" } ``` ##### Response 201400 application/json Copy Example response ``` { "id": "0944f479-3b23-4a9e-b193-b3df37825525" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Quick Start Guide Name | | `description` | `string` | Quick Start Guide Description | | `type` | `string` | Quick Start Guide Type`markdown` | | `data` | `string` | Quick Start Guide Data | ##### Response `201``application/json` 1 fields Example response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Quick Start Guide ID | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/tech/products/{product_name}/quickstart-guides/{quickstart_guide_id}` #### Retrieve Quick Start Guide `getQuickStartGuide` ##### Response 200400 application/json Copy Success response ``` { "type": "markdown", "description": "description", "name": "Quick Start Guide name", "data": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | | `quickstart_guide_id` required | `string` path | `how-to-distribute-site` | Quick Start Guide Id. | ##### Response `200``application/json` 4 fields Success response | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Quick Start Guide name.Example `Quick Start Guide name` | | `type` | `string` | Quick Start Guide type.Example `markdown` | | `description` | `string` | Quick Start Guide description.Example `description` | | `data` | `string` | Quick Start Guide content.Example `

` | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `PUT` `/tech/products/{product_name}/quickstart-guides/{quickstart_guide_id}` #### Update Quick Start Guide `putQuickStartGuide` Update Quick Start Guide ##### Request application/json Copy ``` { "name": "How to publish documentation via pipeline", "description": "Complete how-to...", "type": "markdown", "data": "\n

\n\n

" } ``` ##### Response 201400 application/json Copy Example response ``` { "id": "0944f479-3b23-4a9e-b193-b3df37825525" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | | `quickstart_guide_id` required | `string` path | `how-to-distribute-site` | Quick Start Guide Id. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Quick Start Guide Name | | `description` | `string` | Quick Start Guide Description | | `type` | `string` | Quick Start Guide Type`markdown` | | `data` | `string` | Quick Start Guide Data | ##### Response `201``application/json` 1 fields Example response | Field | Type | Description | | --- | --- | --- | | `id`required | `string` | Quick Start Guide ID | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Customer Ticket `POST` `/tech/products/{product_name}/ticket` #### New Ticket `postCustomerTicket` Create Customer Ticket What it does This endpoint creates a new Zendesk Ticket using the information passed in the request. Registering Zendesk as partner To register Zendesk as a partner in a given environment, please get the correct client_id and secret according to the following documentation: ##### Request application/json Copy ``` { "name": "Test Ticket Title", "description": "This is a description for the test ticket", "requester_name": "John Doe", "requester_email": "john.doe@example.com", "source_id": "test_id_for_source", "priority": "low", "type": "defect", "attachments": [ "01G4YJ1F9K8ER3GGQEBFZGH5W" ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | ##### Request body`application/json` 8 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Ticket Title | | `description`required | `string` | Description | | `requester_name`required | `string` | Requester Name | | `requester_email`required | `string` | Requester Email | | `source_id`required | `string` | The URL of the page where the ticket was created | | `priority`required | `string` | Priority`high``low``normal``urgent` | | `type`required | `string` | Ticket Type`comment``cr``defect``other``question` | | `attachments` | `string[]` | The list of Blob ID | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success Message. | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `400``401``403``404` `POST` `/tech/products/{product_name}/ticket/attachments-blobs` #### Customer Ticket Attachment Blobs `postCustomerTicketAttachmentBlobs` What it does This endpoint creates list of blobs for attachments ##### Request application/json Copy ``` { "attachments": [ { "file_type": "image/png" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `attachments`required | `object[]` | List of attachment information | | `file_type`required | `string` | Mime type of the file | ##### Response `201``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `blobs` | `object[]` | Blobs array. | | `blob_id` | `string` | Blob ID | | `upload_Presigned_URL` | `string` | Upload URL | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `400``401``403``404` ### Sitemap `POST` `/updates` #### Update Sitemap `UpdateSitemap` Update Sitemap with new data ##### Request application/json Copy Minimal GraphQL selection you’re using ``` { "webhookId": "wh_123", "id": "evt_abc", "createdAt": "2025-08-22T10:10:00Z", "type": "GRAPHQL_EVENT", "event": { "data": { "block": { "logs": [ { "data": "0x162B87B2044BFCCD1BABE22DE6734BFCFBD995D81DC9CEC65A7CC384E692981A5" }, { "data": "0xabc123...deadbeef" } ] } } } } ``` ##### Response 401 missing401 invalid application/json Copy Missing or invalid signature header. ``` { "error": "Missing signature" } ``` application/json Copy Missing or invalid signature header. ``` { "error": "Invalid signature" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-alchemy-signature` required | `string` header | `some-hashed-signature` | HMAC-SHA256 hex digest of the **raw** request body using the server's SIGNING_KEY. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `webhookId`required | `string` | Unique identifier of the Alchemy webhook configuration that triggered this delivery. | | `id`required | `string` | Unique identifier of this specific webhook delivery attempt/event. | | `createdAt`required | `string (date-time)` | ISO 8601 timestamp when Alchemy created the webhook event. | | `type`required | `string` | Classification of the webhook event from Alchemy (opaque to the service). | | `event`required | `object` | Container for the actual GraphQL execution result returned by Alchemy for your query. | | `data` | `object` | Root GraphQL data object containing the block payload. | | `block` | `object` | The matched block that produced the filtered logs. | | `logs` | `object[]` | Array of log entries that matched your address/topic filters within the block. | ##### Response `200``application/json` 2 fields Sitemap Updated Succesfully | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Human-readable status string; "ok" on success.Example `ok` | | `dataHashesFound` | `integer` | Count of dataHash values extracted from the payload. | ##### Response `401``application/json` 1 fields Missing or invalid signature header. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Short, non-sensitive reason for the failure (e.g., "Invalid JSON"). | ##### Other responses `403` ### Custom Site `POST` `/verifications` #### Attach Site to Domain `registerCustomDomain` Add custom domain to the existing website #### Attach Site to Domain This endpoint enables you to easily and securely register custom domain names for your website, providing a personalized and branded experience for your users. This service benefits businesses that want to expand their online presence, create separate marketing and technical sites. Utilizing this endpoint, you can efficiently request a new SSL certificate for the specified domain(s). Show the rest This endpoint works by combining two independent functions: - Issue and validate the certificate for provided domain names. - Attach certificate to existing Site Configuration. - Mirror and deliver content of sites mentioned above using your custom domain name. In order to clone technical or marketing websites – apply for a verification and check verification results in: Note that custom domains are attached to the deployed version of the site. Make sure you deploy it before mirroring onto custom domain. #### FAQ ##### How many domains can I include per certificate? Currently, only two domain names can be included under the same certificate. ##### Can I register my root domain? Typically, DNS standards don't allow for CNAME records at the zone apex (also known as the root domain or naked domain). This is because a CNAME record can't coexist with any other data for the same name, and at the zone apex there are always other records, like SOA or NS records. However, some DNS providers provide a way to register records that are not bound to IP-addresses (`A` and `AAAA`). List of DNS providers known to support or not support alias records at the apex zone: | Provider | Can Have Alias at Apex Zone | Specific Feature Used | | --- | --- | --- | | AWS Route 53 | Yes | Alias Records | | Cloudflare | Yes | CNAME Flattening | | Azure DNS | Yes | Alias Records | | DNSimple | Yes | ALIAS Records | | DNS Made Easy | Yes | ANAME Records | | NS1 | Yes | ALIAS Records | | Google Cloud DNS | No | N/A | ##### Request application/json Copy ``` { "domain_names": [ "dmn.foreign.staircaseapi.com" ], "company_id": "01F7Z8J1M8G8W9XKVX9G1JQFN2", "transaction_id": "01F7Z8J1M8G8W9XKVX9G1JQFN2", "site_id": "00000aa0000-4080-0aa0-000-000aa00000aa" } ``` ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `domain_names`required | `string[]` | List of domain names to be registered. Accepts up to two domain names. | | `company_id`required | `string` | The company identifier – requester of the custom assignmentExample `01F7Z8J1M8G8W9XKVX9G1JQFN2` | | `transaction_id`required | `string` | A unique transaction identifierExample `01F7Z8J1M8G8W9XKVX9G1JQFN2` | | `site_id`required | `string` | Site Configuration identifier.Example `00000aa0000-4080-0aa0-000-000aa00000aa` | ##### Response `200``application/json` 3 fields Success | Field | Type | Description | | --- | --- | --- | | `domains` | `object[]` | List of registered domain names. | | `domain_name` | `string` | The custom domain nameExample `dmn.foreign.staircaseapi.com` | | `domain_id` | `string` | The unique identifier for the domainExample `c206b986-0a9f-4b88-82b3-67afea9bd9` | | `certificate_id` | `string` | The unique identifier for the SSL certificateExample `c206b986-0a9f-4b88-82b3-67afea9bd9` | | `certificate_id` | `string` | The unique identifier for the SSL certificateExample `c206b986-0a9f-4b88-82b3-67afea9bd9` | | `transaction_id` | `string` | The unique identifier for the verification processExample `01F7Z8J1M8G8W9XKVX9G1JQFE2` | ##### Other responses `422` `GET` `/verifications/{transaction_id}` #### Check Certificate and DNS Records `checkCustomDomainValidation` Check the status of certificate verification #### Check Certificate and DNS Records Retrieves DNS records required to be set up. At the same time retrieves certificate issuance status. Each record under `records` array must be created under corresponding domain name's DNS management system. Only after that certificate will become valid. Note: It can take up to 72 hours for the certificate to be validated. Show the rest #### DNS providers ##### GoDaddy When using GoDaddy as a DNS provider, if you create a `CNAME` record, it will automatically add the `@` (root) directive at the end of the record's name. Therefore, if you receive a record with the following information: ``` { "type": "CNAME", "name": "_657987justAnExample2o8ade532806ee.pre-approval.example.com.", "value": "_9d20eb7EjustAnotherExample140fd4476.rotmnwfxf.acm-validations.aws." "validation_status": "PENDING_VALIDATION" } ``` You should insert the record as shown in the following example: - `_657987justAnExample2o8ade532806ee.pre-approval` (no `.example.com.` at the end) as a name for the record - `_9d20eb7EjustAnotherExample140fd4476.rotmnwfxf.acm-validations.aws.` as a value for the record - For the record type select `CNAME` ##### Route53 ###### Apex zone Create certificate validation record as usual. For the content delivery record at the zone apex, please follow: 1. Log in to the AWS Management Console: Make sure you're in the account that has the Route 53 hosted zone for your domain. 1. Open the Route 53 console: Navigate to the Route 53 home page. 1. Select Hosted Zones: On the Route 53 home page, choose `Hosted zones` from the navigation pane on the left. 1. Select your Domain: In the Hosted Zones page, click on the domain name for which you want to create the record. 1. Create Record Set: On the domain's settings page, click on `Create Record`. 1. Configure Record Set: - Record name: Leave it blank to use the root domain. - Record type: Select `A - IPv4 address`. - Toggle the `Alias` switch to `Yes`. - In the `Route traffic to` dropdown, select `Alias to CloudFront distribution`. - In the `Choose Distribution` dropdown and toggle `Switch to Manual Input mode` and paste the record which ends with `.cloudfront.net`. 1. Create Record Set: After filling in all the details, click on `Define simple record` and then `Create Records`. Please note that DNS changes can take a while to propagate, so it might take some time before you see your changes take effect. To check DNS propagation of a particular record you can use public DNS resolver and look up the record by its name. For example, you can use Google DNS Lookup to do that. ##### Response 200 Certificate Pending Validation200 Certificate Issued422 application/json Copy Success ``` { "certificate": { "status": "PENDING_VALIDATION", "created_at": "2023-02-05T00:21:23.295438+00:00" }, "records": [ { "type": "CNAME", "name": "_7www9www678222e742953.dmn.foreign.staircaseapi.com", "value": "_7329461678222e742953.scffwap.acm-validations.aws", "validation_status": "PENDING_VALIDATION" }, { "type": "CNAME", "name": "dmn.foreign.staircaseapi.com", "value": "dwarf-star.cloudfront.net" } ] } ``` application/json Copy Success ``` { "certificate": { "status": "ISSUED", "issued_at": "2023-02-04T14:14:42.987868+00:00", "created_at": "2023-02-05T00:21:23.295438+00:00" }, "records": [ { "type": "CNAME", "name": "_7www9www678222e742953.dmn.foreign.staircaseapi.com", "value": "_7329461678222e742953.scffwap.acm-validations.aws", "validation_status": "SUCCESS" }, { "type": "CNAME", "name": "dmn.foreign.staircaseapi.com", "value": "dwarf-star.cloudfront.net" } ] } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `01F7Z8J1M8G8W9XKVX9G1JQFE2` | The unique identifier of the verification task | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `certificate` | `object` | Certificate status | | `status`required | `string` | Whether the certificate is issued or not`EXPIRED``FAILED``INACTIVE``ISSUED``PENDING_VALIDATION``REMOVED``REVOKED``VALIDATION_TIMED_OUT` | | `issued_at` | `string` | Certificate issuance date and time. Present when the certificate status is `ISSUED`.Example `2023-02-04T14:14:42.987868+00:00` | | `created_at` | `string` | Creation date and time for the certificate. Present if the status is not `REMOVED`.Example `2023-02-05T00:21:23.295438+00:00` | | `records` | `object[]` | The list of domain names with required to set up records. | | `type`required | `string` | The type of the DNS record`CNAME`Example `CNAME` | | `name`required | `string` | The name of the DNS recordExample `_7www9www678222e742953.dmn.foreign.staircaseapi.com` | | `value`required | `string` | The value of the DNS recordExample `_7329461678222e742953.scffwap.acm-validations.aws` | | `validation_status` | `string` | The validation status of the domain for the certificate records. Present for certificate validation records exclusively, other records are not validated.`FAILED``PENDING_VALIDATION``SUCCESS`Example `PENDING_VALIDATION` | ##### Other responses `404``422` `DELETE` `/verifications/{transaction_id}` #### Detach Site from Domain `detachSiteFromDomain` Provides a way to detach a site from your domain. Provides a way to detach a site from domain. Keep in mind that deleting DNS records from your DNS provider is on user. Site does not have access to modify those. ##### Response application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `01F7Z8J1M8G8W9XKVX9G1JQFE2` | The unique identifier of the verification task | ##### Other responses `204``404``422` `PUT` `/verifications/{transaction_id}/invalidation` #### Invalidate Cache `invalidateCacheCustomSite` Invalidate cache. Invalidates the cache of the site on a custom domain. Cache invalidation is recommended to be done whenever the source site is re-deployed. ##### Response 202404422 application/json Copy Site cache invalidation request accepted ``` { "transaction_id": "01F7Z8J1M8G8W9XKVX9G1JQFE2" } ``` application/json Copy Transaction was not found ``` { "error": { "message": "Could not find transaction ID.", "reason": "Transaction (`01F7Z8J1M8G8W9LTLT9G1J0J00`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `01F7Z8J1M8G8W9XKVX9G1JQFE2` | The unique identifier of the verification task | ##### Response `202``application/json` 1 fields Site cache invalidation request accepted | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Verification transaction ID.Example `01F7Z8J1M8G8W9XKVX9G1JQFE2` | ##### Other responses `404``422` `PUT` `/verifications/{transaction_id}/synchronization` #### Synchronize `syncCustomSite` Synchronize site. Synchronizes site on a custom domain with a source site. Synchronization is optional, but is recommended to be done whenever sources changes. ##### Response 202404422 application/json Copy Site synchronization request accepted ``` { "transaction_id": "01F7Z8J1M8G8W9XKVX9G1JQFE2" } ``` application/json Copy Transaction not found ``` { "error": { "message": "Could not find transaction ID.", "reason": "Transaction (`01F7Z8J1M8G8W9LTLT9G1J0J00`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `01F7Z8J1M8G8W9XKVX9G1JQFE2` | The unique identifier of the verification task | ##### Response `202``application/json` 1 fields Site synchronization request accepted | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Verification transaction ID.Example `01F7Z8J1M8G8W9XKVX9G1JQFE2` | ##### Other responses `404``422` `GET` `/certificates` #### List Certificates `listCertificates` Retrieve a list of registered certificates and their statuses. ##### Response application/json Copy Success ``` { "certificates": [ { "status": "ISSUED", "issued_at": "2023-02-04T14:14:42.987868+00:00", "renewal_eligible": "ELIGIBLE", "created_at": "2023-02-05T00:21:23.295438+00:00", "subject": "CN=xira.example.com", "expiry_date": "2024-02-04T23:59:59+00:00" }, { "status": "ISSUED", "issued_at": "2023-02-04T14:14:42.987868+00:00", "renewal_eligible": "ELIGIBLE", "created_at": "2023-02-05T00:21:23.295438+00:00", "subject": "CN=dmn.foreign.staircaseapi.com", "expiry_date": "2024-06-26T23:59:59+00:00" } ] } ``` ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `certificates` | `object[]` | List of registered certificates. | | `subject` | `string` | The subject of the certificate.Example `CN=dmn.foreign.staircaseapi.com` | | `status` | `string` | Whether the certificate is issued or not`EXPIRED``FAILED``INACTIVE``ISSUED``PENDING_VALIDATION``REMOVED``REVOKED``VALIDATION_TIMED_OUT`Example `ISSUED` | | `issued_at` | `string` | Certificate issuance date and time. Present when the certificate status is `ISSUED`.Example `2023-02-04T14:14:42.987868+00:00` | | `expiry_date` | `string` | Certificate expiration date and time. Present when the certificate status is `ISSUED`.Example `2023-02-04T14:14:42.987868+00:00` | | `renewal_eligible` | `string` | Whether the certificate is eligible for renewal.`ELIGIBLE``INELIGIBLE`Example `ELIGIBLE` | | `created_at` | `string` | Creation date and time for the certificate. Present if the status is not `REMOVED`.Example `2023-02-05T00:21:23.295438+00:00` | ### Simple sites[new] `PUT` `/simple` #### Register Simple Configuration[new] `registerSimpleAppConfiguration` Register Simple Configuration Simple configuration registration API. The simple site will route requests based on lust of resources specified in the configuration. The simple site will not have any client-side features like authentication, analytics, etc. It will not be affected by iframe downsides. You can specify list of resources to be served by the simple site and error page for restricted access. If `analytics` google tag manager is provided, the tag will be available via `/common.js` request. Your environment domain of site is available via `/environment.json` request. For now only the google analytics tag is supported. In custom object, you can specify custom JS code for common.js API. ##### Request application/json Copy ``` { "site_id": "6374c7f8-13fa-454a-8587-bd29724346d6", "analytics": { "google_analytics_tag": "UA-123456789-1" }, "custom": { "commonjs": "my_js_code" }, "url_mappings": [ { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/" }, { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/", "url_suffix": "/preapproval" } ] } ``` ##### Response 400422 application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `site_id` | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `last_updated` | `string (date-time)` | Last updated date in ISO format.Example `2024-05-14T11:33:11.755632` | | `custom` | `object` | Custom configuration. | | `commonjs` | `string` | Custom JS code.Example `my_js_code` | | `domain_name` | `string` | Domain name of the site. Available after successful deployment.Example `simple-c9985d4f.cerf-dev.staircaseapi.com` | | `url_mappings` | `object[]` | URL mappings configuration. | | `console_app_url`required | `string (uri)` | Console app URL.Example `https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/` | | `url_suffix` | `string (uri)` | URL suffix.Example `/preapproval` | | `environment` | `object` | Environment configuration. | | `domain` | `string` | Environment domain of site.Example `cerf.staircaseapi.com` | | `analytics` | `object` | Analytics configuration. | | `google_analytics_tag` | `string` | If provided, Google Analytics tag will be available inside /common.js request.Example `UA-123456789-1` | ##### Response `201``application/json` 7 fields Success | Field | Type | Description | | --- | --- | --- | | `site_id` | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `last_updated` | `string (date-time)` | Last updated date in ISO format.Example `2024-05-14T11:33:11.755632` | | `custom` | `object` | Custom configuration. | | `commonjs` | `string` | Custom JS code.Example `my_js_code` | | `domain_name` | `string` | Domain name of the site. Available after successful deployment.Example `simple-c9985d4f.cerf-dev.staircaseapi.com` | | `url_mappings` | `object[]` | URL mappings configuration. | | `console_app_url`required | `string (uri)` | Console app URL.Example `https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/` | | `url_suffix` | `string (uri)` | URL suffix.Example `/preapproval` | | `environment` | `object` | Environment configuration. | | `domain` | `string` | Environment domain of site.Example `cerf.staircaseapi.com` | | `analytics` | `object` | Analytics configuration. | | `google_analytics_tag` | `string` | If provided, Google Analytics tag will be available inside /common.js request.Example `UA-123456789-1` | ##### Other responses `400``422` `GET` `/simple` #### List Simple Configurations[new] `listSimpleAppConfigurations` List Simple Configurations Retrieves list of registered simple configurations. ##### Response application/json Copy Success ``` { "sites": [ { "site_id": "82fc3fd6-9031-4dc5-9f40-81927134f19c", "url_mappings": [ { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/" }, { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/", "url_suffix": "/preapproval" } ] }, { "site_id": "6374c7f8-13fa-454a-8587-bd29724346d6", "url_mappings": [ { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/" }, { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/", "url_suffix": "/preapproval" } ] }, { "site_id": "c98f97c7-e021-4988-973d-d51fe041204b", "url_mappings": [ { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/" }, { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/", "url_suffix": "/preapproval" } ] } ], "next_token": null } ``` ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `sites` | `array` | Represents the array of simple sites. | | `next_token` | `string` | Next token to be used in the next request to fetch the next page of configurations. | `GET` `/simple/{site_id}` #### Get Simple Configuration[new] `getSimpleSite` Get Simple Site Retrieves simple site by ID. ##### Response 200404 application/json Copy Success ``` { "site_id": "82fc3fd6-9031-4dc5-9f40-81927134f19c", "domain_name": "simple-c9985d4f.cerf-dev.staircaseapi.com", "custom": { "commonjs": "my_js_code" }, "url_mappings": [ { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/" }, { "console_app_url": "https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/", "url_suffix": "/preapproval" } ] } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site ID | ##### Response `200``application/json` 7 fields Success | Field | Type | Description | | --- | --- | --- | | `site_id` | `string` | The ID of the site configuration.Example `15a820a6-cac9-4b-a7b1-d364b26d7f69` | | `last_updated` | `string (date-time)` | Last updated date in ISO format.Example `2024-05-14T11:33:11.755632` | | `custom` | `object` | Custom configuration. | | `commonjs` | `string` | Custom JS code.Example `my_js_code` | | `domain_name` | `string` | Domain name of the site. Available after successful deployment.Example `simple-c9985d4f.cerf-dev.staircaseapi.com` | | `url_mappings` | `object[]` | URL mappings configuration. | | `console_app_url`required | `string (uri)` | Console app URL.Example `https://chatmtg-prod.chatmtg.com/chatmtg_apply_app/` | | `url_suffix` | `string (uri)` | URL suffix.Example `/preapproval` | | `environment` | `object` | Environment configuration. | | `domain` | `string` | Environment domain of site.Example `cerf.staircaseapi.com` | | `analytics` | `object` | Analytics configuration. | | `google_analytics_tag` | `string` | If provided, Google Analytics tag will be available inside /common.js request.Example `UA-123456789-1` | ##### Other responses `404` `PUT` `/deployments-simple-site` #### Deploy Simple siteConfiguration `deploySimpleSiteConfiguration` Deploy Simple site Configuration #### Deploy Configuration Sites are installed under environment's subdomain. Each site configuration gets its own short ID, which is used in the future domain name of the site. Example of the URL: site-3065e3b5.xchange.staircaseapi.com. ##### Observe deployment status Events are sent in payloads of a “HTTP requests” using `POST` method. ``` { "$schema": "", "additionalProperties": true, "type": "object", "required": ["status", "transaction_id", "domain_name"], "description": "Schema for the payload event emitted to callback.", "properties": { "transaction_id": { "type": "string", "description": "Transaction identifier. Unique per deployment and managed by Site." }, "status": { "type": "string", "description": "Provisioning status.", "enum": ["SUCCEEDED", "FAILED"] }, "domain_name": { "type": "string", "description": "Domain name of the site." }, "error": { "type": "object", "additionalProperties": true, "description": "Deployment has failed unexpectedly. Error details are provided in this object. Note that you should contact the support team when the error occurs." } } } ``` ###### Troubleshooting Events are dispatched once the deployment process completes. Show the rest An event is deemed as successfully delivered when its recipient acknowledges with an HTTP status code that falls within the range of successful responses. If an event isn't successfully delivered, the Site will make six additional attempts to resend the event, with each attempt following an exponential back off strategy. To confirm the propagation of the webhook, you can utilize Retrieve Transaction Collections with the transaction ID, which is returned during the initialization of deployment. ##### Request application/json Copy ``` { "site_id": "6374c7f8-13fa-454a-8587-bd29724346f7", "callback_url": "https://webhooks.staircaseapi.com/persistence/bridge/o09jun2kjhjkkkiDj" } ``` ##### Response 400404422 application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `site_id`required | `string` | Simple site flow configuration ID.Example `6374c7f8-13fa-454a-8587-bd29724346f7` | | `callback_url`required | `string` | Callback URL.Example `https://webhooks.staircaseapi.com/persistence/bridge/o09jun2kjhjkkkiDj` | ##### Response `200``application/json` 5 fields Success | Field | Type | Description | | --- | --- | --- | | `deploy_id` | `string` | deploy_idExample `16af04ab-eb62-42b7-8778-a79234d137ce` | | `domain_name`required | `string` | Generated domain name for the site.Example `site-abc00def.xchange.staircaseapi.com` | | `transaction_id`required | `string` | Transaction ID.Example `01H021M9X10AN9XNNJ8THMMMMM` | | `callback_url` | `string` | The callback URL is returned as is. The value will match the input `callback_url`.Example `https://webhooks.staircaseapi.com/persistence/bridge/o09jun2kjhjkkkiDj` | | `site_id` | `string` | Simple site ID. The value will match the input `site_id`.Example `6374c7f8-13fa-454a-8587-bd29724346f7` | ##### Other responses `400``404``422` `GET` `/deployments-simple-site/{deploy_id}` #### Deploy Simple siteConfiguration `deploySimpleSiteConfigurationStatus` Deploy Simple site Configuration Status API for checking the status of the simple site deployment. ##### Response 200404 application/json Copy Success ``` { "status": "SUCCEEDED" } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `deploy_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Deploy ID. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Deployment status.`RUNNING``SUCCEEDED``FAILED``TIMED_OUT``ABORTED``PENDING_REDRIVE`Example `SUCCEEDED` | ##### Other responses `404` `GET` `/simple/{site_id}/custom-domain` #### Custom domain status[new] `customDomainStatus` Custom Domain Status Fetch status of custom domain attachment. ##### Response 200404 application/json Copy Success ``` { "domain_name": "example.chatmtg.com", "certificate_arn": "arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012", "attach": true } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site ID | ##### Response `200``application/json` 3 fields Success | Field | Type | Description | | --- | --- | --- | | `attach` | `boolean` | Attach flag.Example `false` | | `domain_name` | `string` | Custom domain name.Example `example.chatmtg.com` | | `certificate_arn` | `string` | ACM Certificate ARN.Example `arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012` | ##### Other responses `404` `PUT` `/simple/{site_id}/custom-domain` #### Attach custom domain[new] `attachCustomDomain` Attach Custom Domain Allows to attach custom domain to the simple site. Simple site can be deployed under different domain name (custom domain name). In order to deploy the site under custom domain name, you need to provide the domain name and ACM Certificate ARN in the configuration. After it, the site will be deployed under the provided domain name, and previous domain name will not be accessible. First deployment should use attach flag as false. After the deployment, grab the cloudfront distribution name and put in into CNAME record of your custom domain. After that, you can deploy the site with attach flag as true. After attaching custom domain name it is impossible to go back to default domain name. ##### Response 201400404422 application/json Copy Success ``` { "domain_name": "example.chatmtg.com", "certificate_arn": "arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012", "attach": true } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site ID | ##### Response `201``application/json` 3 fields Success | Field | Type | Description | | --- | --- | --- | | `attach` | `boolean` | Attach flag.Example `false` | | `domain_name` | `string` | Custom domain name.Example `example.chatmtg.com` | | `certificate_arn` | `string` | ACM Certificate ARN.Example `arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012` | ##### Other responses `400``404``422` `POST` `/simple/{site_id}/invalidate-cache` #### Invalidate cache[new] `invalidateCache` Invalidate Cache Starts cache invalidation process for the site. Process is asynchronous and can take up to 15 minutes. ##### Request application/json Copy ``` { "items": [ "listings*" ] } ``` ##### Response 202400404422 application/json Copy Success ``` { "message": "Cache invalidation started" } ``` application/json Copy A 400 status code occurs when some of provided request parameters is invalid. ``` { "error": { "message": "Bad Request", "reason": "Provided token is not valid." } } ``` application/json Copy A 404 status code occurs when a requested resource cannot be located. ``` { "error": { "message": "Not found.", "reason": "Flow(site_id=`345e8795-eb14-24t3-a2-aaaa174000`)" } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `site_id` required | `string` path | `15a820a6-cac9-4b-a7b1-d364b26d7f69` | Site ID | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `items`required | `string[]` | List of items to invalidate | ##### Response `202``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message about the cache invalidation process. | ##### Other responses `400``404``422` ### Marketing: Companies `GET` `/marketing/companies` #### Retrieve Companies `Companies` Retrieve Companies ##### Response 200400 application/json Copy Approval uploaded ``` { "partners": [ { "name": "partner_x", "logo": "https://site-content.domain.staircaseapi.com/marketing/partners/partner_x/logo.png" } ] } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `company_type` required | `string` query | `customer` | filters by concrete company type. | ##### Response `200``application/json` 1 fields Approval uploaded | Field | Type | Description | | --- | --- | --- | | `partners` | `object[]` | The partner list | | `name` | `string` | Name | | `logo` | `string` | Logo URL | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `POST` `/marketing/companies` #### Add Company `addCompany` Add Company ##### Request Example Request for Adding Partnerexample-1 application/json Copy ``` { "name": "Company_X", "company_type": "partner", "logo_url": "https://dev-data-manager-blobs-bucket-us-east-1-581813358386.s3.amazonaws.com/01G0J3GRQER1DH5HXNYA7S39YN.png?response-content-type=image%2Fpng&AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1651062920", "logo_extension": ".png" } ``` application/json Copy ``` { "name": "Partner_X", "logo_url": "https://dev-data-manager-blobs-bucket-us-east-1-581813358386.s3.amazonaws.com/01G0J3GRQER1DH5HXNYA7S39YN.png?response-content-type=image%2Fpng&AWSAccessKeyId=&Signature=&x-amz-security-token=&Expires=1651062920", "logo_extension": ".png" } ``` ##### Response application/json Copy Example response ``` { "message": "Created" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Company Name | | `company_type`required | `string` | Company Type`adapter``customer``partner` | | `logo_url`required | `string` | Logo URL | | `logo_extension`required | `string` | Logo Extension | ##### Response `201``application/json` 1 fields Example response | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `DELETE` `/marketing/companies/{company_name}` #### Delete Company `Company` Delete Company ##### Response text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | | `company_name` required | `string` path | `Truework` | Company Name | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `PUT` `/marketing/companies/{company_name}/logo` #### Upload Company Logo `uploadCompanyLogo` Upload Logo ##### Request application/json Copy ``` Select option 'binary' in order to upload file ``` ##### Response 200400 application/json Copy Approval uploaded ``` { "message": "Successfully Uploaded" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API key of Environment. | | `company_name` required | `string` path | `Truework` | Company Name | ##### Response `200``application/json` 1 fields Approval uploaded | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Successfully Uploaded | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Marketing: Product Ontology `GET` `/marketing/ontology` #### Retrieve Product Ontology `retrieveMarketingProductOntology` Retrieve Product Ontology ##### Response application/json Copy Success response ``` { "product_families": [ { "name": "Mortgage Products", "product_categories": [ { "name": "Data Manager", "products": [ { "name": "Document Classification" }, { "name": "Data Extraction" }, { "name": "Ground Truth Labeling" } ] }, { "name": "Borrower", "products": [ { "name": "Employment" }, { "name": "Credit" }, { "name": "Income" }, { "name": "Assets" } ] }, { "name": "Collateral", "products": [ { "name": "Automated Valuation Model (AVM)" }, { "name": "Property Taxes" } ] }, { "name": "Loan", "products": [ { "name": "Pricing" }, { "name": "Fees" } ] }, { "name": "Adapters", "products": [ { "name": "LOS" } ] } ] }, { "name": "Mortgage Processes", "product_categories": [ { "name": "Application", "products": [ { "name": "Pre-Approval" } ] }, { "name": "Underwriting", "products": [ { "name": "Loan Eligibility" }, { "name": "Automated Underwriting System (AUS)" } ] }, { "name": "Servicing", "products": [ { "name": "Loanboarding" } ] } ] }, { "name": "Platform", "product_categories": [ { "name": "Integrate", "products": [ { "name": "Connector" }, { "name": "Job" }, { "name": "Product" } ] }, { "name": "Data", "products": [ { "name": "Persistence" }, { "name": "Data Extraction Training" }, { "name": "Translator" }, { "name": "Language" }, { "name": "Rule" }, { "name": "Site" } ] } ] }, { "name": "Devops", "product_categories": [ { "name": "Distribute", "products": [ { "name": "Environment" }, { "name": "Account" }, { "name": "Marketplace" }, { "name": "Host" }, { "name": "Company" }, { "name": "Setup" } ] }, { "name": "Ship", "products": [ { "name": "Code" }, { "name": "Assess" }, { "name": "Build" }, { "name": "Deploy" }, { "name": "Test" }, { "name": "Health" }, { "name": "Comply" }, { "name": "Experience" }, { "name": "Work" } ] } ] }, { "name": "Operations", "product_categories": [ { "name": "Operations", "products": [ { "name": "Capital Allocation" } ] } ] } ] } ``` ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `product_families`required | `object[]` | Product Families | | `name`required | `string` | Family name | | `description` | `string` | Family description | | `color` | `string` | Family color code | | `product_categories`required | `object[]` | Product categories | | `name`required | `string` | Category name | | `description` | `string` | Category description | | `color` | `string` | Category color code | | `products`required | `object[]` | Products | | `name`required | `string` | Product name | | `description` | `string` | Product description | | `color` | `string` | Product color code | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `POST` `/marketing/ontology` #### Create Product Ontology `createMarketingProductOntology` Add Product Ontology ##### Request application/json Copy ``` { "ontology": { "product_families": [ { "name": "Mortgage Products", "product_categories": [ { "name": "Data Manager", "products": [ { "name": "Document Classification" }, { "name": "Data Extraction" }, { "name": "Ground Truth Labeling" } ] }, { "name": "Borrower", "products": [ { "name": "Employment" }, { "name": "Credit" }, { "name": "Income" }, { "name": "Assets" } ] }, { "name": "Collateral", "products": [ { "name": "Automated Valuation Model (AVM)" }, { "name": "Property Taxes" } ] }, { "name": "Loan", "products": [ { "name": "Pricing" }, { "name": "Fees" } ] }, { "name": "Adapters", "products": [ { "name": "LOS" } ] } ] }, { "name": "Mortgage Processes", "product_categories": [ { "name": "Application", "products": [ { "name": "Pre-Approval" } ] }, { "name": "Underwriting", "products": [ { "name": "Loan Eligibility" }, { "name": "Automated Underwriting System (AUS)" } ] }, { "name": "Servicing", "products": [ { "name": "Loanboarding" } ] } ] }, { "name": "Platform", "product_categories": [ { "name": "Integrate", "products": [ { "name": "Connector" }, { "name": "Job" }, { "name": "Product" } ] }, { "name": "Data", "products": [ { "name": "Persistence" }, { "name": "Data Extraction Training" }, { "name": "Translator" }, { "name": "Language" }, { "name": "Rule" }, { "name": "Site" } ] } ] }, { "name": "Devops", "product_categories": [ { "name": "Distribute", "products": [ { "name": "Environment" }, { "name": "Account" }, { "name": "Marketplace" }, { "name": "Host" }, { "name": "Company" }, { "name": "Setup" } ] }, { "name": "Ship", "products": [ { "name": "Code" }, { "name": "Assess" }, { "name": "Build" }, { "name": "Deploy" }, { "name": "Test" }, { "name": "Health" }, { "name": "Comply" }, { "name": "Experience" }, { "name": "Work" } ] } ] }, { "name": "Operations", "product_categories": [ { "name": "Operations", "products": [ { "name": "Capital Allocation" } ] } ] } ] } } ``` ##### Response application/json Copy Example response ``` { "message": "Created" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `ontology`required | `object` | Marketing Ontology | | `product_families`required | `object[]` | Product Families | | `name`required | `string` | Family name | | `description` | `string` | Family description | | `color` | `string` | Family color code | | `product_categories`required | `object[]` | Product categories | | `name`required | `string` | Category name | | `description` | `string` | Category description | | `color` | `string` | Category color code | | `products`required | `object[]` | Products | ##### Response `201``application/json` 1 fields Example response | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `DELETE` `/marketing/ontology/families/{family_id}` #### Delete Product Family `deleteMarketingProductFamily` Delete Product Ontology Delete Product Family ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `family_id` required | `string` path | `platform` | The family id | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `204``403` `GET` `/marketing/ontology/families/{family_id}` #### Retrieve Product Family `retrieveMarketingProductFamily` Retrieve Product Ontology Retrieve Product Family ##### Response application/json Copy Successfully got the response ``` { "category": "", "color": "", "name": "Platform", "component_type": "FAMILY", "description": "", "family": "", "id": "platform", "logo_url": "https://site-content.dev-site.staircaseapi.com/marketing/ontology/families/platform/content/public/logo.svg", "pk": "ONTOLOGY", "sk": "FAMILY#platform", "product_categories": [ { "category": "", "color": "", "name": "Data", "component_type": "CATEGORY", "description": "", "family": "platform", "id": "data", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data", "products": [ { "category": "data", "color": "", "name": "Data Extraction Training", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "data-extraction-training", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data#PRODUCT#data-extraction-training" }, { "category": "data", "color": "", "name": "Language", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "language", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data#PRODUCT#language" }, { "category": "data", "color": "", "name": "Persistence", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "persistence", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data#PRODUCT#persistence" }, { "category": "data", "color": "", "name": "Rule", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "rule", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data#PRODUCT#rule" }, { "category": "data", "color": "", "name": "Site", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "site", "logo_url": "https://site-content.dev-site.staircaseapi.com/marketing/ontology/families/platform/categories/data/products/site/content/public/logo.svg", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data#PRODUCT#site" }, { "category": "data", "color": "", "name": "Translator", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "translator", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#data#PRODUCT#translator" } ] }, { "category": "", "color": "", "name": "Integrate", "component_type": "CATEGORY", "description": "", "family": "platform", "id": "integrate", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#integrate", "products": [ { "category": "integrate", "color": "", "name": "Connector", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "connector", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#integrate#PRODUCT#connector" }, { "category": "integrate", "color": "", "name": "Job", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "job", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#integrate#PRODUCT#job" }, { "category": "integrate", "color": "", "name": "Product", "component_type": "PRODUCT", "description": "", "family": "platform", "id": "product", "logo_url": "", "pk": "ONTOLOGY", "sk": "FAMILY#platform#CATEGORY#integrate#PRODUCT#product" } ] } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `family_id` required | `string` path | `platform` | The family id | ##### Response `200``application/json` 11 fields Successfully got the response | Field | Type | Description | | --- | --- | --- | | `category` | `string` | The category name | | `color` | `string` | Color code | | `name`required | `string` | The component name | | `component_type`required | `string` | Component Type | | `description`required | `string` | Description | | `family` | `string` | Family | | `id`required | `string` | Component ID | | `logo_url` | `string` | The logo URL | | `pk`required | `string` | key | | `sk`required | `string` | The path key | | `product_categories`required | `object[]` | Product categories | | `category` | `string` | Category name | | `color` | `string` | The color code | | `name`required | `string` | Component Name | | `component_type`required | `string` | Component Type | | `description`required | `string` | Description | | `family` | `string` | Family | | `id`required | `string` | ID | | `logo_url` | `string` | The logo URL | | `pk`required | `string` | PK | | `sk`required | `string` | SK | | `products` | `object[]` | Products List | | `category` | `string` | Category | | `color` | `string` | Color Code | | `name`required | `string` | Component Name | | `component_type`required | `string` | Component Type | | `description`required | `string` | Description | | `family` | `string` | Family | | `id`required | `string` | ID | | `logo_url` | `string` | Logo URL | | `pk`required | `string` | PK | | `sk`required | `string` | SK | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ### Tech: Overview `PUT` `/tech/products/{product_name}/content/public/{content_name}` #### Upload Product Public Content[updated] `uploadPublicContent` Upload Public Content Upload your Public Content ! Note: You should avoid using spaces at your content name #### Big size files Site platform has some restrictions at request body size. Once you reach this limit, you will face 413 Payload Too Large error. 413 Payload Too Large error fix ##### Request application/json Copy ``` Select option 'binary' in order to upload file ``` ##### Response 200400 application/json Copy Approval uploaded ``` { "download_url": "https://documentation.staircaseapi.com/products/Site/content/public/notebook.ipynb" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | | `content_name` required | `string` path | `notebook.ipynb` | The name of the content (should contain extension too) | | `Content-Type` required | `string` header | `application/vnd.jupyter` | Mime type of the file | ##### Response `200``application/json` 1 fields Approval uploaded | Field | Type | Description | | --- | --- | --- | | `download_url` | `string` | Download URL for the uploaded content | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/tech/products/{product_name}/content/public/{content_name}/presigned-url` #### Get Presigned URL to upload Public Content[new] `uploadPublicContentPresignedUrl` Get Presigned URL to upload Public Content Upload your big size Public Content This is a functional duplicate of this endpoint. Just use upload_Presigned_URL from response to upload your any-size content! ! Note: it is important to set correct {content_name} and {content_type} values according to your file! ! Note: You should avoid using spaces at your content name ##### Response 200400 application/json Copy Approval uploaded ``` { "download_url": "https://documentation.staircaseapi.com/products/Site/content/public/filename.pdf", "presigned_upload_url": "https://site-api-dev-publishingbucket-kz0j6vc5htl0.s3.amazonaws.com/products/Site/content/public/filename.pdf?AWSAccessKeyId=&Signature=&content-type=application%2Fpdf&x-amz-security-token=&Expires=1665605220" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file | | `content_name` required | `string` path | `filename.pdf` | The name of the content (should contain extension too) | | `content_type` required | `string` query | `application/pdf` | Content-Type of file you want to upload via Presigned URL | ##### Response `200``application/json` 2 fields Approval uploaded | Field | Type | Description | | --- | --- | --- | | `download_url` | `string` | Download URL for the uploaded content | | `presigned_upload_url` | `string` | Presigned Upload URL for the content | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/tech/products/{product_name}/components/{component_name}/overview` #### Get Component Overview Page `getComponentOverviewPage` Get component overview page HTML content. ##### Response 200400 application/json Copy Success response ``` { "overview_embedded": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | | `component_name` required | `string` path | `Marketing: Product Ontology` | Component name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `overview` | `string` | HTML content of embedded overview page.Example `

` | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `POST` `/tech/products/{product_name}/components/{component_name}/overview` #### Add Component Overview Page `postComponentOverviewPage` Add Component Overview Page. ##### Request application/json Copy ``` { "overview": "" } ``` ##### Response 200400 application/json Copy Success response ``` { "overview_embedded": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | | `component_name` required | `string` path | `Marketing: Product Ontology` | Component name which was specified as 'x-product-name' in product swagger file. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `overview` | `string` | Overview markdown or HTML | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `overview_embedded` | `string` | HTML content of embedded overview page.Example `

` | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `GET` `/tech/products/{product_name}/overview` #### Get Overview Page `getOverviewEmbedded` Get overview Page Get product overview page HTML content. ##### Response 200400 application/json Copy Success response ``` { "overview_embedded": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-name' in product swagger file. | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `overview_embedded` | `string` | HTML content of embedded overview page.Example `

` | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `POST` `/tech/products/{product_name}/overview` #### Add Overview Page `postOverviewPage` Add Product Overview Page. ##### Request application/json Copy ``` { "overview": "" } ``` ##### Response 200400 application/json Copy Success response ``` { "overview_embedded": "\n

\n\n

" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_name` required | `string` path | `Site` | Product name which was specified as 'x-product-component' in product swagger file. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `overview` | `string` | Overview markdown or HTML | ##### Response `200``application/json` 1 fields Success response | Field | Type | Description | | --- | --- | --- | | `overview_embedded` | `string` | HTML content of embedded overview page.Example `

` | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `422``application/json` 1 fields Bad request. | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Tech: Logo[new] `GET` `/tech/logo` #### Get Logo `getLogo` Get Logo download URL used both Sites: Technical and Marketing. ##### Response 200400 application/json Copy Logo URL ``` { "download_url": "https://documentation.staircaseapi.com/products/Site/content/public/logo.png" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Response `200``application/json` 1 fields Logo URL | Field | Type | Description | | --- | --- | --- | | `download_url` | `string` | Download URL for the uploaded Logo | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` `PUT` `/tech/logo` #### Upload Logo `uploadGlobalCompanyLogo` Upload Logo which will be used both: Technical and Marketing Sites ! Note: It might take time after request did to update your logo ##### Request application/json Copy ``` Select option 'binary' in order to upload file ``` ##### Response 200400 application/json Copy Logo Uploaded ``` { "download_url": "https://documentation.staircaseapi.com/products/Site/content/public/logo.png" } ``` text/html Copy Bad Request ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `Content-Type` required | `string` header | `image/png` | Mime type of the file | ##### Response `200``application/json` 1 fields Logo Uploaded | Field | Type | Description | | --- | --- | --- | | `download_url` | `string` | Download URL for the uploaded Logo | ##### Response `400``application/json` 2 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error. | | `message` | `string` | Error message. | ##### Response `404``application/json` 1 fields Publishing not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message which contains information about requested entity | ##### Response `500``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error`required | `string` | Error message. | ##### Response `502``application/json` 1 fields Server error | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message. | ##### Other responses `403` ### Operations `GET` `/getting-started` #### Content for getting-started section Get content for getting started section ##### Other responses `200``403` `POST` `/hello-world` #### Hello World Dummy hello world endpoint ##### Other responses `200` ## Errors `400``401``403``404``407``422``500``502` ## More in Data - Previous product: Rule - Next product: Turker --- # Turker # Turker Human-in-the-loop task management: the queue, assignment and review layer behind labelling and data-quality work. Some steps need a person — labelling a document field, confirming an extracted owner name, resolving a record two sources disagree about. Turker carries the queue those tasks sit in, the assignment to a reviewer, and the record of what was decided. It is the shared layer beneath the document-labelling pipeline and the review steps in the property pipeline. Documentation for this slot is thin in the recorded sources and no specification survives, so the page carries no endpoint detail. ## More in Data - Previous product: Site --- # Integration # Integration The integration substrate: the vendor connector layer, the job scheduler, and the registry that defines other products. How does a product reach a vendor, and how does it run? Three primitives. Connectors are declared as state machines rather than written as services, one repository per vendor endpoint, each versioned and tested on its own. Jobs carry anything recurring or resumable, including the bulk translation runs and the scheduled vendor pulls. The product registry defines the uniform endpoint surface every vertical inherits. That last one is why two products from different categories expose the same shape: request and response schema, vendor ordering, invocation history, partner list and report templates are declared once here rather than per product. ## Products In the order the value chain runs. 1. Connection has a recorded specification 1. Job has a recorded specification 1. Product has a recorded specification 1. Workflow --- # Connection # Connection Vendor connectors declared as state machines: one repository per vendor endpoint, each versioned, tested and monitored on its own. A connector is a JSON document, not a service. A flow declares states — an HTTP call in JSON or XML, an inline transformation, a branch — with input selectors pulling values out of the request payload and the credential set in scope, and a callback address for asynchronous completion. One repository per vendor endpoint, with a test for each status code that endpoint can return. Webhook and browser-widget variants get their own repositories on the same shape. ## How it works Declaring the transport rather than coding it makes a vendor integration reviewable by someone who does not read the language it would otherwise be written in, and it makes the unit small enough to version honestly: one endpoint changes, one repository changes. Credentials are profiles, selected at run time. A vendor's stored credential set holds a default plus named profiles, and the first state of the flow picks the profile the request asked for and merges it over the default. The same connector therefore serves a lender using its own vendor account and a lender using the shared one, without a second flow. Overhead measurement excludes the vendor's own elapsed time. Four connector API identifiers are excluded by name — the three generic outbound request types and the webhook notification — because their duration measures the vendor rather than the platform. Cold starts are reported separately, as invocation code `7000` with status `REQUEST_MADE`. ## Operations ### Transformations `PUT` `/transformations/html-to-pdf` #### HTML to PDF `transform_html_to_pdf` Performs synchronous format transformation. Transforms HTML to PDF. Downloads data from the URL and uploads the transformed data to PDF. Upload is sent with "PUT" with HTTP method. An example of how to integrate the conversion in the flow. ``` { "version": "2", "authorization": { "mode": "pass_through", "auth_type": "custom", "credentials": "dynamic" }, "definition": { "StartAt": "DownloadHTML", "States": { "DownloadHTML": { "Next": "InstantiateBlob", "Type": "Task", "ResourceDefinition": { "Type": "HTTP_ANY", "HttpMethod": "GET", "Headers": { "Accept": "text/html" }, "VendorEndpointUrlPath": "$.request_payload.source_url", "SaveResponseToFile": true, "Extract": { "Save": { "download_from_url": "$.response_file_url" } } } }, "InstantiateBlob": { "Type": "Task", "Next": "SaveAsPDF", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "POST", "VendorEndpointUrl": "", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "PathParametersMapping": { "request_host": "$.request_host" }, "RequestPayload": { "extension": ".pdf", "presign_url_ttl": 3600 }, "Extract": { "Save": { "blob_id": "$.blob_id", "upload_to_url": "$.presigned_urls.upload.url" } } } }, "SaveAsPDF": { "Type": "Task", "Next": "ComposeResponse", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "PUT", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "RequestPayload": { "urls": { "download_from_url": "$.download_from_url", "upload_to_url": "$.upload_to_url" } }, "VendorEndpointUrl": "", "PathParametersMapping": { "request_host": "$.request_host" } } }, "ComposeResponse": { "End": true, "Type": "Task", "ResourceDefinition": { "Type": "CODE", "Source": "loopback = lambda response: response", "Runtime": "python3.8", "InputDataSelector": { "blob_id": "$.blob_id" }, "SaveOutputTo": "response_payload", "FunctionName": "loopback" } } } } } ``` #### Note Subscribe to `connection-html-to-pdf` component to access this feature. Show the rest ##### Request application/json Copy ``` { "urls": { "download_from_url": "https://staircase.co/html-is-downloaded-from-here", "upload_to_url": "https://staircase.co/pdf-is-upload-to-here" } } ``` ##### Response 400403404422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `urls`required | `object` | Container for download and upload URLs. | | `download_from_url`required | `string (uri)` | The URL from where connector pulls the HTML data. Must have `https://` in the URLs part. | | `upload_to_url`required | `string (uri)` | The URL where connector puts the PDF data. Must have `https://` in the URLs scheme. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Other responses `204``400``404``422` `PUT` `/transformations/xml-to-json` #### XML to JSON `transform_xml_to_json` Performs synchronous format transformation. Transforms XML to JSON. Downloads data from the input URL and uploads the transformed data to output URL. Upload is sent with "PUT" HTTP method. An example of how to integrate the transformation in the flow definition. ``` { "version": "2", "authorization": { "mode": "pass_through", "auth_type": "custom", "credentials": "dynamic" }, "definition": { "StartAt": "DownloadXML", "States": { "DownloadXML": { "Next": "InstantiateBlob", "Type": "Task", "ResourceDefinition": { "Type": "HTTP_ANY", "HttpMethod": "GET", "Headers": { "Content-Type": "$.request_payload.content_type" }, "VendorEndpointUrlPath": "$.request_payload.source_url", "SaveResponseToFile": true, "Extract": { "Save": { "download_from_url": "$.response_file_url" } } } }, "InstantiateBlob": { "Type": "Task", "Next": "SaveAsJSON", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "POST", "VendorEndpointUrl": "", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "PathParametersMapping": { "request_host": "$.request_host" }, "RequestPayload": { "extension": ".json", "presign_url_ttl": 3600 }, "Extract": { "Save": { "blob_id": "$.blob_id", "upload_to_url": "$.presigned_urls.upload.url" } } } }, "SaveAsJSON": { "Type": "Task", "Next": "ComposeResponse", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "PUT", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "RequestPayload": { "transaction_id": "$.transaction_id", "urls": { "download_from_url": "$.download_from_url", "upload_to_url": "$.upload_to_url" } }, "VendorEndpointUrl": "", "PathParametersMapping": { "request_host": "$.request_host" } } }, "ComposeResponse": { "End": true, "Type": "Task", "ResourceDefinition": { "Type": "CODE", "Source": "loopback = lambda response: response", "Runtime": "python3.8", "InputDataSelector": { "blob_id": "$.blob_id" }, "SaveOutputTo": "response_payload", "FunctionName": "loopback" } } } } } ``` #### Transformation Modes User can specify either `data` to be transformed directly or `urls` from which the data will be pulled and uploaded to (only one can be used a a time). Show the rest #### Warning If `data` mode is used but the supplied XML is too large, request will not be evaluated. Consider switching to `url` based transformation. #### Transformation Configuration - `force_values_into_array` (Optional) Boolean or array of strings. Forces array creation for every child in an XML document at any given depth if boolean is used. If array of strings is supplied, only the nodes named by those strings will be forced to be arrays. By default, `force_values_into_array` is `true`. - `attribute_prefix` (Optional) String. Prefix for tag attributes that will be added to differentiate attributes from text. By default, `attribute_prefix` is `"@"`. User can set it to empty string to not append prefix to attributes. Access pattern to a free text of an element will depend on the format of the tag. - If an element has at least one attribute, free text will be available under `#text` - If an element has no attributes defined, free text will be the next following element Transformation Samples Input XML: ``` It's me, Connection! eyJwaem.ei2u.2e03rinmALDd ``` Suppose `attribute_prefix` is `_` and `force_values_into_array` is `true` ``` { "dialogs": [ { "_filterTopic": "E2P", "message": [ { "_receiver": "124191486", "_sender": "1", "text": [ { "_version": "0.1.1", "_engine": "CHTML", "entities": [ { "entity": [ { "_offset": "9", "_length": "9", "_transform": "bold" }, { "_offset": "5", "_length": "2", "_transform": "link", "_link": "" } ] } ], "raw": [ "It's me, Connection!" ] } ], "#text": [ "eyJwaem.ei2u.2e03rinmALDd" ] } ] } ] } ``` Changing `force_values_into_array` to `false` ``` { "dialogs": { "_filterTopic": "E2P", "message": { "_receiver": "124191486", "_sender": "1", "text": { "_version": "0.1.1", "_engine": "CHTML", "entities": { "entity": [ { "_offset": "9", "_length": "9", "_transform": "bold" }, { "_offset": "5", "_length": "2", "_transform": "link", "_link": "" } ] }, "raw": "It's me, Connection!" }, "#text": "eyJwaem.ei2u.2e03rinmALDd" } } } ``` Specification for interpreting XML as JSON is partially described here. However, parameters like `force_values_into_array` and `attribute_prefix` can be controlled. ##### Note Subscribe to `connection-xml-to-json` component to access this feature. ##### Request URL based transformationDirect transformationSpecific array nodes application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "urls": { "download_from_url": "https://staircase.co/xml-is-downloaded-from-here", "upload_to_url": "https://staircase.co/json-is-uploaded-here" }, "configuration": { "attribute_prefix": "__" }, "product_configuration_id": "345a814d-432e-4801-96b4-74dc03ef1047" } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "Staircase", "configuration": { "attribute_prefix": "__" }, "product_configuration_id": "345a814d-432e-4801-96b4-74dc03ef1047" } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "JohnNothing", "configuration": { "force_values_into_array": [ "people" ] } } ``` ##### Response 400403404422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": "\"\" is less than 1 character." } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": "Domain name could not be validated." } } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `configuration` | `object` | Appends a specified value as attribute prefix, '@' by default. | | `attribute_prefix` | `string` | Appends a specified value as attribute prefix, '@' by default. | | `force_values_into_array` | `one of` | Forces all values into array. Can be array or boolean. | | `json_schema` | `object` | JSON schema of the output data. Output data will be converted to types specified in the schema. If conversion is not possible, transformation will fail. If the schema is not specified, the output data will not be converted. If the schema is not a valid JSON Schema, transformation will fail. | | `data` | `string` | XML data to be transformed. Should not exceed 5242880 bytes. | | `product_configuration_id` | `string` | Configuration ID that references a Configuration registered in Marketplace. | | `transaction_id` | `string` | Transaction ID | | `urls` | `object` | Container for download and upload URLs. | | `download_from_url`required | `string (uri)` | The URL from which XML data is to be pulled. Must have `https://` in the URLs scheme. | | `upload_to_url`required | `string (uri)` | The URL to which converted to JSON data will be uploaded. Must have `https://` in the URLs scheme. | ##### Response `200``application/json` 1 fields Transformation was successful. | Field | Type | Description | | --- | --- | --- | | `transformed_data` | `object` | Transformed data | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Contains error information | | `message` | `string` | Contains error message | | `reason` | `string` | Contains the cause of the error | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Contains error information | | `message` | `string` | Contains error message | | `reason` | `string` | Contains the cause of the error | ##### Other responses `204``422` `PUT` `/transformations/json-to-xml` #### JSON to XML `transform_json_to_xml` Performs synchronous format transformation. Transforms JSON to XML. Downloads data from the input URL and uploads the transformed data to output URL. Upload is sent with "PUT" HTTP method. An example of how to integrate the transformation in the flow definition. ``` { "version": "2", "authorization": { "mode": "pass_through", "auth_type": "custom", "credentials": "dynamic" }, "definition": { "StartAt": "DownloadJSON", "States": { "DownloadJSON": { "Next": "InstantiateBlob", "Type": "Task", "ResourceDefinition": { "Type": "HTTP_ANY", "HttpMethod": "GET", "Headers": { "Content-Type": "$.request_payload.content_type" }, "VendorEndpointUrlPath": "$.request_payload.source_url", "SaveResponseToFile": true, "Extract": { "Save": { "download_from_url": "$.response_file_url" } } } }, "InstantiateBlob": { "Type": "Task", "Next": "SaveAsXML", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "POST", "VendorEndpointUrl": "", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "PathParametersMapping": { "request_host": "$.request_host" }, "RequestPayload": { "extension": ".xml", "presign_url_ttl": 3600 }, "Extract": { "Save": { "blob_id": "$.blob_id", "upload_to_url": "$.presigned_urls.upload.url" } } } }, "SaveAsXML": { "Type": "Task", "Next": "ComposeResponse", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "PUT", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "RequestPayload": { "transaction_id": "$.transaction_id", "urls": { "download_from_url": "$.download_from_url", "upload_to_url": "$.upload_to_url" } }, "VendorEndpointUrl": "", "PathParametersMapping": { "request_host": "$.request_host" } } }, "ComposeResponse": { "End": true, "Type": "Task", "ResourceDefinition": { "Type": "CODE", "Source": "loopback = lambda response: response", "Runtime": "python3.8", "InputDataSelector": { "blob_id": "$.blob_id" }, "SaveOutputTo": "response_payload", "FunctionName": "loopback" } } } } } ``` #### Transformation Modes User can specify either `data` to be transformed directly or `urls` from which the data will be pulled and uploaded to (only one can be used a a time). Show the rest #### Warning If `data` mode is used but the supplied JSON is too large, request will not be evaluated. Consider switching to `url` based transformation. #### Transformation Details User can set the values of transformation variables, such as `attribute_prefix`, `wrapper`, or `array_enumeration`. ##### `attribute_prefix` Some JSON objects that are to be transformed to XML have previously been derived from XML or have been meant to be transformed to XML later, preserving elements' attribute values with a specific attribute prefix. User can pass this attribute prefix to construct XML with respective attribute definitions located in correct places. Default value for `attribute_prefix` is `"@"`. If text is specified using `"#text": "my_text"`, the resulting element will contain my_text as text enclosed directly by parent element - ` my_text`, instead of usual `my_text` resulting from `"element": "my_text"` ##### `preserve_prefixes` User can set this to `true` if respective attribute prefixes should not be deleted from the resulting attributes upon transformation. ##### `wrapper` Some JSON objects are problematic to transform to XML, especially those that are enclosed into the array at the top level. To avoid multi-root documents (not proper XML) to be produced, the result is wrapped into the root element using the value of `wrapper`, which is `"root"` by default. Additionally, in case JSON object is an array at the highest level, to construct proper XML it is wrapped around with `"items"` element as a child of `wrapper` element. Wrapper is customizable i.e. allows user to provide the tag attributes using relevant schema. Note that the input JSON is wrapped before transformation, thus all other configuration settings apply to the provided wrapper tag/attributes during the transformation. ##### `array_enumeration` Allows defining special variables - `sequence_start` and `attribute_name` - enabling the transformation to enumerate array items in the generated XML output. The index for the item in the array is stored as offset from `sequence_start` in the attribute of the item tag named as `attribute_name`. ##### `omit_wrapper` Allows to omit enforced wrapper in case the JSON data is suitable for direct conversion to XML. Transformation Examples Transforming: ``` { "Developer": { "@age": 32, "@language": "c++", "#text": "my_little_json" } } ``` produces: ``` my_little_json ``` Changing #text key to text: ``` { "Developer": { "@age": 32, "@language": "c++", "text": "my_little_json" } } ``` results into: ``` my_little_json ``` Finally, following JSON: ``` [ { "shape": "square", "size": 50 }, { "shape": "circle", "size": 25 } ] ``` yields: ``` square 50 circle 25 ``` Array Enumeration Examples Sample Input JSON: ``` { "people": [ { "name": "John", "age": 30 }, { "name": "Jane", "age": 25 }, { "name": "Jack", "age": 40 } ] } ``` Sample Output XML with array enumeration enabled: ``` John 30 Jane 25 Jack 40 ``` Customized Wrapper Example For the following JSON: ``` { "company": "EvilMegaCorp", "owner": { "SuperEvil": "confirmed", "@country": "KTR" } } ``` with the following configuration parameters: ``` { "wrapper": { "value": "root", "attributes": { "origin_source": "json" } }, "attribute_prefix": "@" } ``` the output XML looks like: ``` EvilMegaCorp confirmed ``` ##### Note Subscribe to `connection-json-to-xml` component to access this feature. ##### Request URL based transformationDirect transformationArray Enumeration Enabled application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "urls": { "download_from_url": "https://staircase.co/json-is-downloaded-from-here", "upload_to_url": "https://staircase.co/xml-is-uploaded-here" }, "configuration": { "wrapper": "my_wrapper", "attribute_prefix": "__" }, "product_configuration_id": "21194609-9634-40a3-a044-979682e58a37" } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "{\"key_1\": \"value_1\"}", "product_configuration_id": "345a814d-432e-4801-96b4-74dc03ef1047" } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "{\"people\": [{\"name\": \"John\", \"age\": 30}, {\"name\": \"Jane\", \"age\": 25}, {\"name\": \"Jack\", \"age\": 40}]}", "configuration": { "array_enumeration": { "sequence_start": 0, "attribute_name": "ItemIndex" } } } ``` ##### Response 200400403404422 application/json Copy Transformation was successful. ``` { "transformed_data": "John30Jane25Jack40" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Response `200``application/json` 1 fields Transformation was successful. | Field | Type | Description | | --- | --- | --- | | `transformed_data` | `string` | Transformed data | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `one of` | reason | ##### Other responses `204` `PUT` `/transformations/html-to-json` #### HTML to JSON `transform_html_to_json` Performs synchronous format transformation. Transforms HTML to JSON. Downloads data from the input URL and uploads the transformed data to output URL. Upload is sent with "PUT" HTTP method. An example of how to integrate the transformation in the flow definition. ``` { "version": "2", "authorization": { "mode": "pass_through", "auth_type": "custom", "credentials": "dynamic" }, "definition": { "StartAt": "DownloadHTML", "States": { "DownloadHTML": { "Next": "InstantiateBlob", "Type": "Task", "ResourceDefinition": { "Type": "HTTP_ANY", "HttpMethod": "GET", "Headers": { "Content-Type": "$.request_payload.content_type" }, "VendorEndpointUrlPath": "$.request_payload.source_url", "SaveResponseToFile": true, "Extract": { "Save": { "download_from_url": "$.response_file_url" } } } }, "InstantiateBlob": { "Type": "Task", "Next": "SaveAsJSON", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "POST", "VendorEndpointUrl": "", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "PathParametersMapping": { "request_host": "$.request_host" }, "RequestPayload": { "extension": ".json", "presign_url_ttl": 3600 }, "Extract": { "Save": { "blob_id": "$.blob_id", "upload_to_url": "$.presigned_urls.upload.url" } } } }, "SaveAsJSON": { "Type": "Task", "Next": "ComposeResponse", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "PUT", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "RequestPayload": { "transaction_id": "$.transaction_id", "urls": { "download_from_url": "$.download_from_url", "upload_to_url": "$.upload_to_url" } }, "VendorEndpointUrl": "", "PathParametersMapping": { "request_host": "$.request_host" } } }, "ComposeResponse": { "End": true, "Type": "Task", "ResourceDefinition": { "Type": "CODE", "Source": "loopback = lambda response: response", "Runtime": "python3.8", "InputDataSelector": { "blob_id": "$.blob_id" }, "SaveOutputTo": "response_payload", "FunctionName": "loopback" } } } } } ``` #### Transformation Modes User can specify either `data` to be transformed directly or `urls` from which the data will be pulled and uploaded to (only one can be used a a time). Show the rest #### Warning If `data` mode is used but the supplied HTML is too large, request will not be evaluated. Consider switching to `url` based transformation. Transformation Example Applying Transformation to: ```
Company Country
Staircase USA
``` produces: ``` { "div": [ { "_attributes": { "align": "center" }, "table": [ { "_attributes": { "border": "0", "width": "95%" }, "tr": [ { "th": [ { "_value": "Company" }, { "_value": "Country" } ] }, { "td": [ { "_value": "Staircase" }, { "_value": "USA" } ] } ] } ] } ] } ``` ##### Note Subscribe to `connection-html-to-json` component to access this feature. ##### Request URL based transformationDirect transformation application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "urls": { "download_from_url": "https://staircase.co/html-is-downloaded-from-here", "upload_to_url": "https://staircase.co/json-is-uploaded-here" } } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "

Staircase

", "product_configuration_id": "345a814d-432e-4801-96b4-74dc03ef1047" } ``` ##### Response 400403404422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Response `200``application/json` 1 fields Transformation was successful. | Field | Type | Description | | --- | --- | --- | | `transformed_data` | `object` | Transformed data | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | ##### Other responses `204` `PUT` `/transformations/text-to-json` #### Formatted Text to JSON `transform_text_to_json` Performs synchronous format transformation. Transforms Formatted Text to JSON. Downloads data from the input URL and uploads the transformed data to output URL. Upload is sent with "PUT" HTTP method. An example of how to integrate the transformation in the flow definition. ``` { "version": "2", "flow_name": "my_lovely_flow", "authorization": { "mode": "pass_through", "auth_type": "custom", "credentials": "dynamic" }, "definition": { "StartAt": "DownloadFormattedText", "States": { "DownloadFormattedText": { "Next": "InstantiateBlob", "Type": "Task", "ResourceDefinition": { "Type": "HTTP_ANY", "HttpMethod": "GET", "Headers": { "Content-Type": "$.request_payload.content_type" }, "VendorEndpointUrlPath": "$.request_payload.source_url", "SaveResponseToFile": true, "Extract": { "Save": { "download_from_url": "$.response_file_url" } } } }, "InstantiateBlob": { "Type": "Task", "Next": "SaveAsJSON", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "POST", "VendorEndpointUrl": "", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "PathParametersMapping": { "request_host": "$.request_host" }, "RequestPayload": { "extension": ".json", "presign_url_ttl": 3600 }, "Extract": { "Save": { "blob_id": "$.blob_id", "upload_to_url": "$.presigned_urls.upload.url" } } } }, "SaveAsJSON": { "Type": "Task", "Next": "ComposeResponse", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "PUT", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "RequestPayload": { "transaction_id": "$.transaction_id", "urls": { "download_from_url": "$.download_from_url", "upload_to_url": "$.upload_to_url" }, "template_name": "$.request_payload.template_name", "multipart_boundary_header": "$.request_payload.multipart_boundary_header" }, "VendorEndpointUrl": "", "PathParametersMapping": { "request_host": "$.request_host" } } }, "ComposeResponse": { "End": true, "Type": "Task", "ResourceDefinition": { "Type": "CODE", "Source": "loopback = lambda response: response", "Runtime": "python3.8", "InputDataSelector": { "blob_id": "$.blob_id" }, "SaveOutputTo": "response_payload", "FunctionName": "loopback" } } } } } ``` #### Transformation Modes User can specify either `data` to be transformed directly or `urls` from which the data will be pulled and uploaded to (only one can be used at a time). Show the rest #### Warning If `data` mode is used but the supplied JSON is too large, request will not be evaluated. Consider switching to `url` based transformation. #### Templates This endpoint requires usage of a template that allows to match the necessary data fields with their values to compose a JSON object as a result. Check the Formatted Text Templates documentation for the necessary operations and information on how to build the Template. This endpoint attempts to apply the specified Template to the given Text to produce the result, to the best possible extent. `template_name` requested in the payload should be a valid name of already existing template in the environment. User has to specify `multipart_boundary_header` which sets the multipart boundary value for the file separator. ##### Note Subscribe to `connection-plain-text-to-json` component to access this feature. ##### Request URL based transformationData based transformation application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "urls": { "download_from_url": "https://staircase.co/text-is-downloaded-from-here", "upload_to_url": "https://staircase.co/json-is-uploaded-here" }, "template_name": "my_special_template", "multipart_boundary_header": "----------ieoau._._+2_8_GoodLuck8.3-ds0d0J0S0Kl234324jfLdsjfdAuaoei-----" } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "company: Staircase\ncountry: US\n", "template_name": "my_special_template", "multipart_boundary_header": "----------ieoau._._+2_8_GoodLuck8.3-ds0d0J0S0Kl234324jfLdsjfdAuaoei-----", "product_configuration_id": "605d8623-262f-4d64-a490-4963d73db8f0" } ``` ##### Response 400403404422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Response `200``application/json` 1 fields Transformation was successful. | Field | Type | Description | | --- | --- | --- | | `transformed_data` | `object` | Transformed data | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | ##### Other responses `204` ### Transformations[new] `PUT` `/transformations/csv-to-json` #### CSV to JSON `transform_csv_to_json` Performs synchronous format transformation. Transforms CSV to JSON. Downloads data from the input URL and uploads the transformed data to output URL, if `url` based transformation has been chosen. Otherwise, if `data` format is picked, accepts the CSV data and attempts to transform it into JSON directly, returning the result in the response payload. Check below for the transformation parameters that user can/should control. Show the rest Upload is sent with "PUT" HTTP method for the `url` based transformation. An example of how to integrate the url based transformation in the flow definition. ``` { "version": "2", "authorization": { "mode": "pass_through", "auth_type": "custom", "credentials": "dynamic" }, "definition": { "StartAt": "DownloadCSV", "States": { "DownloadCSV": { "Next": "InstantiateBlob", "Type": "Task", "ResourceDefinition": { "Type": "HTTP_ANY", "HttpMethod": "GET", "Headers": { "Content-Type": "$.request_payload.content_type" }, "VendorEndpointUrlPath": "$.request_payload.source_url", "SaveResponseToFile": true, "Extract": { "Save": { "download_from_url": "$.response_file_url" } } } }, "InstantiateBlob": { "Type": "Task", "Next": "SaveAsJSON", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "POST", "VendorEndpointUrl": "", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "PathParametersMapping": { "request_host": "$.request_host" }, "RequestPayload": { "extension": ".json", "presign_url_ttl": 3600 }, "Extract": { "Save": { "blob_id": "$.blob_id", "upload_to_url": "$.presigned_urls.upload.url" } } } }, "SaveAsJSON": { "Type": "Task", "Next": "ComposeResponse", "ResourceDefinition": { "Type": "HTTP_JSON", "HttpMethod": "PUT", "Headers": { "Content-Type": "application/json", "x-api-key": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "RequestPayload": { "transaction_id": "$.transaction_id", "urls": { "download_from_url": "$.download_from_url", "upload_to_url": "$.upload_to_url" } }, "VendorEndpointUrl": "", "PathParametersMapping": { "request_host": "$.request_host" } } }, "ComposeResponse": { "End": true, "Type": "Task", "ResourceDefinition": { "Type": "CODE", "Source": "loopback = lambda response: response", "Runtime": "python3.8", "InputDataSelector": { "blob_id": "$.blob_id" }, "SaveOutputTo": "response_payload", "FunctionName": "loopback" } } } } } ``` #### Transformation Modes User can specify either `data` to be transformed directly or `urls` from which the data will be pulled and uploaded to (only one can be used at a time). #### Warning If `data` mode is used but the supplied CSV is too large, request will not be evaluated. Consider switching to `url` based transformation. If 'urls' mode is used, user should ensure that the download link responds with the `Content-Type` header containing relevant value, such as `text/plain` or `csv`. #### Transformation Configuration User can define specific transformation properties to control the process and use custom characters set for the key attributes involved. Below is the list of properties that are under control of the user: - `delimiter` - defines the character to be used as the delimiter for the CSV record fields. Default value is `,` - `fieldnames` - this endpoint treats the passed data's 1st row as the header from which it generates relevant field names. If your data is not supposed to have 1st row as header, specify this property with a list of custom fieldnames, 1 per record field (see examples below for better clarity) - `escape_character` - defines the character that is used to escape other special characters used in CSV or defined by user. - `include_columns` - defines the set of columns to include in the output JSON (allows to crop out unneeded columns) - `column_types` - allows to define specific data types which will be cast to the values of the specified columns (see the possible values for the data types below). Note that empty values in the string columns are transformed into `null` instead of empty strings. #### Data Types For the `column_types` configuration parameter user can specify column names with the data types to cast upon values of those. The available data types are: `integer`, `float`, and `string`. Transformation Examples Applying transformation with default configuration to: ``` h1,h2,h3 r1v1,r1v2,r1v3 r2v1,r2v2,r2v3 ``` results in: ``` [ { "h1": "r1v1", "h2": "r1v2", "h3": "r1v3" }, { "h1": "r2v1", "h2": "r2v2", "h3": "r2v3" } ] ``` In case your data resembles this: ``` h1;h2;h3 r1v1;r1v2;r1v3 r2v1;r2v2;r2v3 ``` then, by setting `configuration` with the value below, you can achieve the same result with the previous example: ``` { "delimiter": ";" } ``` Assume that you only need several columns from the input CSV, whereas it contains many more. One can specify specific column names to be used to form the result JSON, cropping out all the additional columns. For instance: ``` h1,h2,h3 r1v1,r1v2,r1v3 r2v1,r2v2,r2v3 ``` You can exclude column `h3` from the result JSON by specifying following configuration: ``` { "include_columns": ["h1", "h2"] } ``` Result: ``` [ { "h1": "r1v1", "h2": "r1v2" }, { "h1": "r2v1", "h2": "r2v2" } ] ``` Finally, user could also benefit from `column_types` configuration parameter, which allows to force-cast data types on specific columns. Below is example: ``` name,surname,age,id bob,marley,31,456 kurt,cobain,26,298 ``` Assuming that user wishes to have `id` column to have string values, one can specify following configuration: ``` { "column_types": [ { "column_name": "id", "column_type": "string" } ] } ``` Result: ``` [ { "name": "bob", "surname": "marley", "age": 31, "id": "456" }, { "name": "kurt", "surname": "cobain", "age": 26, "id": "298" } ] ``` ##### Note Subscribe to `connection-csv-to-json` component to access this feature. ##### Request URL based transformationData based transformation application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "urls": { "download_from_url": "https://staircase.co/csv-is-downloaded-from-here", "upload_to_url": "https://staircase.co/csv-is-uploaded-here" }, "configuration": { "delimiter": ";" } } ``` application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "data": "h1,h2,h3\nr1v1,r1v2,r1v3\nr2v1,r2v2,r2v3", "configuration": { "column_types": [ { "column_name": "h1" }, { "column_type": "string" } ] } } ``` ##### Response 400403404422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Response `200``application/json` 1 fields Transformation was successful. | Field | Type | Description | | --- | --- | --- | | `transformed_data` | `object[]` | Transformed data consisting of records | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `one of` | Reason | ##### Other responses `204` `PUT` `/transformations/csv-to-json/async` #### CSV to JSON (Async)[new] `transform_csv_to_json_async` CSV to JSON Performs asynchronous format transformation. Transforms CSV to JSON. This endpoint is designed to handle the processing of CSV files with a high volume of rows and columns. Each asynchronous transformation is assigned a `transaction_id` and a unique `response_collection_id`. To identify and retrieve the URL to a response, you need to use both `transaction_id` and `response_collection_id`. See Refresh Data URL for more. Show the rest #### Synchronous vs Asynchronous Opting for asynchronous transformation is recommended when processing large CSV files with numerous rows and columns. However, it's important to note that asynchronous transformation has its own drawbacks. This approach doesn't directly upload data to the specified URL or return transformed data in the webhook response payload. Instead, it generates a temporary URL that can be used to access the transformed data once the processing is complete. For synchronous transformation, you can check out CSV to JSON API. #### Events Events are sent to `callback_url` provided by user. At the end of conversion, you will receive a webhook with the following schema: ``` { "$schema": "", "type": "object", "properties": { "status": { "type": "string", "enum": ["Failed", "Completed"] }, "error": { "type": "object", "properties": { "error_type": { "type": "string" }, "context": { "type": "object", "additionalProperties": true } }, "required": ["error_type", "context"], "additionalProperties": false }, "result": { "type": "object", "properties": { "temporary_url": { "type": "string" } }, "required": ["temporary_url"], "additionalProperties": false }, "transaction_id": { "type": "string" }, "response_collection_id": { "type": "string" } }, "required": ["status", "transaction_id", "response_collection_id"], "additionalProperties": false } ``` Please note that the result and error fields cannot appear at the same time. However, both are included in the schema for better understanding and display purposes. You can refresh the temporary URL in the Refresh Data URL #### Known limitations Including type definitions for every column is strongly recommended, as this helps to establish consistent data types across all rows. Without this information, the first row of each column is used to infer the type for subsequent rows, which can lead to inconsistencies and errors. At least one column type definition must be provided. ##### Request application/json Copy ``` { "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK", "callback_url": "https://watch.staircaseapi.com/callback-listener/tok89782uomvc2nuyYBw", "urls": { "download_from_url": "https://staircase.co/csv-is-downloaded-from-here" }, "configuration": { "delimiter": "|", "column_types": [ { "column_name": "LoanNumber", "column_type": "integer" }, { "column_name": "AAndHFlagChangeById", "column_type": "string" }, { "column_name": "AccelerationAmount", "column_type": "float" }, { "column_name": "AccelerationReasonCode", "column_type": "float" } ] } } ``` ##### Response 400403422 application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | The unique identifier for the transaction. | | `configuration`required | `object` | An object that specifies the configuration options for the data file. | | `delimiter` | `string` | The delimiter used to separate fields in the data file. | | `fieldnames` | `string[]` | An array of field names for the columns in the data file. | | `escape_character` | `string` | The character used to escape special characters in the data file. | | `column_types`required | `object[]` | An array of objects that specify the column names and data types in the data file. | | `column_name` | `string` | The name of the column in the data file. | | `column_type` | `string` | The type of data in the column.`float``integer``string` | | `include_columns` | `string[]` | An array of column names to include in the output. | | `urls`required | `object` | An object that specifies the URLs for the data file. | | `download_from_url`required | `string` | The URL from which to download the data file. | | `callback_url`required | `string` | The URL to call with the results of the data processing. | ##### Response `202``application/json` 3 fields Transformation has been initialized. | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | The unique identifier for the transaction.Example `01ABDC918DE524F` | | `response_collection_id`required | `string` | The unique identifier for the response collection.Example `002f8b98-c5-4ac3-b26d-edecba96ef19` | | `future_temporary_url`required | `string` | The temporary URL that can be used in the future. Note that object may not be immediately.Example `https://urls.staircaseapi.com/early-access` | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `one of` | Reason | `GET` `/transformations/csv-to-json/async/results/{transaction_id}/{response_collection_id}` #### Refresh Data URL[new] `refresh_csv_data_url` CSV to JSON Refreshes the `URL` of a given transformation. To identify a response, you need to use both `transaction_id` and `response_collection_id`. The URL is not included when no transformation for the specified response collection ID. If a transformation is still pending or not found, the `transformation_status` will indicate this by showing `pending_or_not_found`. ##### Response application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `01F7S0N7CQ31DZQYVSVPN66GNK` | The unique identifier for the transaction. | | `response_collection_id` required | `string` path | `002f8b98-c5-4ac3-b26d-edecba96ef19` | The unique identifier for the response collection. | ##### Response `200``application/json` 2 fields Transformation metadata. | Field | Type | Description | | --- | --- | --- | | `transformation_status`required | `string` | Status of a data transformation process.`available``pending_or_not_found` | | `temporary_url`required | `string` | Temporary URL for accessing transformed data. Can be null. | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ### Formatted Text Templates `POST` `/transformations/text-to-json/templates` #### Create Transformation Template `create_template` Creates and stores transformation Template that will be used to transform Formatted Text data to JSON objects the way user prefers it. Template can be referenced by the `template_name`, so it should be unique. User can use `template_section_break` value to specify templates for different variations of the same file (`#####formatted_text_template_section_break#####` by default). Show the rest #### Template Specification Templates are written in a plain text data format and do not follow strict rules outside the template statements. The so-called template statements are enclosed in double curly braces - `{{my_template_statement}}`. The statement inside follows a strict syntax that is validated by the endpoint. The template statements are used to match certain user-defined regular expressions to the data inside Formatted Text files. A typical template_statement structure is shown below: {{ "`regex`", "`object_path`", "`value_structure`", "`multiline`" }} | Statement Component | Description | Required | | --- | --- | --- | | regex | Regular expression | true | | object_path | JSONPath where the created value should be stored | true | | value_structure | Allows to configure the object structure created as value | false | | multiline | Allows regex detection with new line character `\n` | false | `regex` (required) needs at least one `(regex group)` to extract relevant value from data. `object_path` (required) - object properties separated by dot (.). Object is created dynamically, if it contains pipe character (|) then this `prop.prop_A|prop.prop_B` becomes: ``` { "prop": { "prop_A": "match group 1 from REGEX value", "prop_B": "match group 2 from REGEX value" } } ``` (scalable to `n` REGEX groups) `value_structure` (optional) - when this is set instead of adding value to OBJ_PATH, this creates an object from `propA|propB` to: ``` { "propA": "match group 1 from REGEX value", "propB": "match group 2 from REGEX value" } ``` Can be used to add objects as individual elements to arrays. `multiline` (optional) - forces the Template to read data lines until it reaches an empty line. The combined lines are then matched to regex. Template Statement Examples Template Statement: `{{ "Dataset:\s(.*)\n\s*(.*)", "Dataset[]", "code|message", "true" }}` applied to: Dataset: 1003 Data No Errors/Warnings detected Dataset: Additional Case Data No Errors/Warnings detected produces: ``` "Dataset": [ { "code": "1003 Data", "message": "No Errors/Warnings detected" }, { "code": "Additional Case Data", "message": "No Errors/Warnings detected" } ] ``` Template Statement: `{{ "(.+performance\stime\swas.+)", "Credit Report Retrieval Log.Performance" }}` applied to: Credit agency Agency200's performance time was 1 seconds. produces: ``` "Credit Report Retrieval Log": { "Performance": "Credit agency Agency200's performance time was 1 seconds." } ``` ##### Note ###### Subscribe to `connection-plain-text-to-json` component to access this feature. ##### Request application/json Copy ``` { "template_name": "my_special_template", "template_content": "my_template_content" } ``` ##### Response 201400403404422 application/json Copy Template was created successfully ``` { "201 Response Example": { "value": { "template_name": "my_special_template" } } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `template_name`required | `string` | Template name that can be referenced | | `template_content`required | `string` | Template content to be validated and saved | | `template_section_break` | `string` | Allows overriding default value | ##### Response `201``application/json` 1 fields Template was created successfully | Field | Type | Description | | --- | --- | --- | | `template_name` | `string` | Template name that can be referenced | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | `GET` `/transformations/text-to-json/templates` #### Retrieve All Templates `retrieve_templates` Retrieves all Templates created and stored by the user. Since the response can become large, the number of items returned is limited and can be configured by the user. #### Pagination by Token This endpoint supports pagination by token. If you receive a non-null value for 'next_token' under the "page" collection in response payload, to get the next page, you will have to pass 'next_token' in the following request as query parameter #### Note ###### Subscribe to `connection-plain-text-to-json` component to access this feature. ##### Response 200400403404422 application/json Copy Retrieved all Transformation Templates ``` { "templates": [], "page": { "count": 2, "next_token": "cGs9VEVNUExBVEUlMjNteV90ZW1wbGF0ZV8yJnNrPVRFTVBMQVRFJTIzbXlfdGVtcGxhdGVfMg==" } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `limit` | `integer` query | `15` | Limits number of items returned | | `next_token` | `string` query | `cGs9VEVNUExBVEUlMjNteV90ZW1wbGF0ZV8yJnNrPVRFTVBMQVRFJTIzbXlfdGVtcGxhdGVfMg==` | Next token can be used to retrieve next page of results | ##### Response `200``application/json` 2 fields Retrieved all Transformation Templates | Field | Type | Description | | --- | --- | --- | | `templates` | `object[]` | Array of Transformation Templates created earlier | | `template_name` | `string` | Template name | | `template_content` | `string` | Template content | | `page` | `object` | Contains information about pagination | | `count` | `integer` | Count of items returned | | `next_token` | `string` | The next token for further requests | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | `GET` `/transformations/text-to-json/templates/{template_name}` #### Retrieve Transformation Template `retrieve_template` Retrieves an individual Template referenced by its name. #### Note ###### Subscribe to `connection-plain-text-to-json` component to access this feature. ##### Response 200400403404422 application/json Copy Retrieved all Transformation Templates ``` { "template_name": "my_special_template", "template_content": "template content" } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `template_name` required | `string` path | `my_special_template` | Template Name | ##### Response `200``application/json` 2 fields Retrieved all Transformation Templates | Field | Type | Description | | --- | --- | --- | | `template_name` | `string` | Name of the template | | `template_content` | `string` | Content of the template | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | `PATCH` `/transformations/text-to-json/templates/{template_name}` #### Update Transformation Template `update_template` Update the Template content referenced by its name. #### Note ###### Subscribe to `connection-plain-text-to-json` component to access this feature. ##### Request application/json Copy ``` { "template_content": "my_template_content" } ``` ##### Response 200400403404422 application/json Copy Template was updated successfully ``` { "200 Response Example": { "message": "The template `template_name` has been updated successfully." } } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `template_name` required | `string` path | `my_special_template` | Template Name | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `template_content`required | `string` | Template content to be validated and updated | ##### Response `200``application/json` 1 fields Template was updated successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request fulfilled successfully message | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | `DELETE` `/transformations/text-to-json/templates/{template_name}` #### Delete Transformation Template `delete_template` Deletes a Transformation Template referenced by its name. #### Note ###### Subscribe to `connection-plain-text-to-json` component to access this feature. ##### Response 200400403404422 application/json Copy The template was deleted successfully ``` { "message": "The template `my_special_template` has been deleted successfully." } ``` application/json Copy Bad request syntax. Request payload does not exist or malformed. ``` { "error": { "message": "Bad Request", "reason": [ "\"\" is less than 1 character." ] } } ``` application/json Copy Request is forbidden, API key is not valid ``` { "message": "Your API key is not valid, please refresh it." } ``` application/json Copy Resource not found. Resource you were looking for was not found. ``` { "error": { "message": "Not Found", "reason": "Nothing matches the given URI." } } ``` application/json Copy A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. ``` { "error": { "message": "Unprocessable entity.", "reason": { "remote": "[422, error_message]" } } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `template_name` required | `string` path | `my_special_template` | Template Name | ##### Response `200``application/json` 1 fields The template was deleted successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Template deleted successfully message | ##### Response `400``application/json` 1 fields Bad request syntax. Request payload does not exist or malformed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `errors` | `array` | errors | ##### Response `403``application/json` 1 fields Request is forbidden, API key is not valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Forbidden error messageExample `Your API key is not valid, please refresh it.` | ##### Response `404``application/json` 1 fields Resource not found. Resource you were looking for was not found. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason`required | `string` | reason | ##### Response `422``application/json` 1 fields A 422 status code occurs when a request is well-formed, however, due to semantic errors it is unable to be processed. | Field | Type | Description | | --- | --- | --- | | `error` | `object` | error | | `message`required | `string` | message | | `reason` | `object` | reason | ## Providers - Arch MI - Argyle - Atomic - Blend - Byte Software - CBC / Factual Data - Citadel - DocuSign - Docutech - Enact - Ephesoft - Equifax - Essent - Experian - Fannie Mae - Finicity - Freddie Mac - ICE Mortgage Technology - Informative Research - LendingPad - MeridianLink - MGIC - Mindee - National MI - Ocrolus - Optimal Blue - Pinwheel - Plaid - Prove - Radian - RPR - Sales Boomerang - Sharper Lending - SoftworksAI - Stavvy - Truework - Truv - Valon - Wage - Wilqo - Xactus ## Field mapping | Provider | Flow | Canonical in | Vendor in | Vendor out | Canonical out | | --- | --- | --- | --- | --- | --- | | Argyle | `income` | `staircase-graph` | `income-input` | `income-argyle-output` | `staircase-graph` | | Essent | `essent-insurance-flow` | `staircase-graph` | `essent-input` | `essent-output` | `staircase-graph` | | Plaid | `asset` | `staircase-graph` | `asset-input` | `asset-plaid-output` | `staircase-graph` | | Xactus | `credit-verify` | `staircase-graph` | `credit-input` | `credit-mismo231` | `staircase-graph` | ## Errors `400``403``404``422` ## More in Integration - Next product: Job --- # Job # Job Scheduled and on-demand execution with full lifecycle tracking: create, run, resume, stop, and webhook triggers. Anything recurring runs here — nightly vendor pulls, report generation, bulk translation runs. A job carries its schedule, its payload and its state, and can be resumed rather than only restarted. Webhook triggering means an external event starts a job directly, which is how a vendor's asynchronous completion becomes the next stage of work without a poller. ## How it works Resumability is the reason the lifecycle is explicit rather than implied by a scheduler. A bulk run that fails partway through should continue from where it stopped; that is only possible if the run's position is state the job itself carries. ## Operations ### Jobs `POST` `/jobs` #### Create Job[new] `createJob` Create Job Create Job will enable creation of a new job. To create a new job, you need to provide the below information: - `name` - `definition` - `description` (Optional) - `product_name` (Optional). Will be used to report performance metrics to Heath as a `product_name`, while setting `origin_product` to 'Job' All Jobs consist of States Show the rest State: States are the steps used to define Jobs. A different operation is performed in each State and the next step is specified. #### Quick links Available States are: - InvokeProduct - AthenaStartQuery - AthenaGetResults - AthenaGetResultsAsUrl - AthenaGetResultsAsReference - Choice - Wait - Mockdata - Data - Outputaggregate - WaitForAction - WaitForCallback Available InvokeProduct settings: - `Path` The staircase path where you will call the API (Required) - `PathParameters` (Optional). Can be specified if path should be dynamically changed during API calls. - `QueryParameters` (Optional). Can be specified if query string should be dynamically changed during API calls. - `Method` Type of api call you will make - `RequestPayload` (Optional). Request body of a http call. - `EnvironmentSettings` (Optional). Environment settings allow invoking Staircase product on the other Staircase environment. - `Headers` (Optional). Environment settings allow invoking Staircase product on the other Staircase environment. - `CallbackSettings` (Optional). Allow invoking Staircase product with `callback_url`. If `WaitForCallback` present `CallbackSettings` going to be added by default. - `WaitForCallback` (Optional). If present, State will wait for callback from a product. WaitForCallback can be used to specify success and/or failed values. - `IterationSettings` (Optional). Job supports iteration settings for dynamic parallelism. - `Projection` (Optional). Specifies the field(s) to return. To return all fields, omit this parameter. - `TimeoutSeconds` (Optional). If the task runs longer than the specified seconds, this state fails. - `ExceptNext` (Optional). Define your next state if any error occurs. - `Retry` (Optional). Retry logic if any error in InvokeProduct happens it does retry. - `After` (Optional). After action to execute after Product was invoked. Available InvokeJob settings: - `JobName` Job Name to invoke - `TransactionId` Persistence Transaction ID - `RequestPayload`. Request payload for Job invocation. - `Projection` (Optional). Specifies the field(s) to return. To return all fields, omit this parameter. - `IterationSettings` (Optional). Job supports iteration settings for dynamic parallelism. - `TimeoutSeconds` (Optional). If the task runs longer than the specified seconds, this state fails. - `ExceptNext` (Optional). Define your next state if any error occurs. - `Retry` (Optional). Retry logic if any error in InvokeJob happens it does retry. Available Intrinsic Functions are: - `ulid` - `array_get` - `array_chunks` - `add` - `concat` - `split` - `replace` - `merge` - `date_format` - `date_end_day` - `date_start_day` - `date_now` - `date_next_day` - `date_previous_day` - `date_to_iso` - `date_to_iso_tz` - `date_from_iso` #### Job Language There are few ways to work with States definition. As a JSON-path, string should start from `$.` ``` "PathParameters": { "transaction_id": "$.transaction_id" } ``` It is possible to escape a string with JSON-path like with `\$.`, for example ``` RequestPayload: query: path: path: \$.people[*].has_taxpayer_identifier_value.has_value format: jsonpath operation: eq value: $.request_payload.data.has_taxpayer_identifier_value.has_value ``` As a JMESPath, where string should start from `$jmespath.` Example selecting 2 fields from `metrics` array of objects ``` "Projection": { "metrics": "$jmespath.metrics[*].{created_at: date_format(created_at, '%Y-%m-%dT%H:%M:%S.%f','%Y-%m-%d %H:%M:%S'), transaction_id: transaction_id}", "next": "$.next_token" } ``` JMESPath pipe example ``` "Projection": { "created_at": "$jmespath.created_at | date_format(@, '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d')" } ``` JMESPath if-exists else example ``` "PathParameters": { "end_date": "$jmespath.outputs.LatestData.response_payload.created_at || outputs.Start.date", "product_name": "$.outputs.Start.product_name", "start_date": "$jmespath.outputs.LatestData.response_payload.created_at || outputs.Start.date" } ``` Follow the link bellow to review other JMESPath Examples ##### JMESPath Intrinsic Functions According to JMESPath specification there is a list of Builtin functions. However, Job Language also provides a small number of "Intrinsic Functions", constructs which look like functions in programming languages and can be used to help process the data going to and from States. Date formats should be defined with Python datetime formatting When a function fail it returns `null`. ###### `ulid` Allow to generate ULID `ulid` ``` { "name": "ulid-test", "definition": { "StartAt": "Start", "States": { "Start": { "Type": "Data", "Data": { "ulid": "$jmespath.ulid" }, "End": true } } } } ``` ###### `array_get` Allow to get element from an array using element index as jmespath `array_get(array, index)` ``` { "PathParameters": { "flow_name": "$jmespath.array_get(outputs.Start.flow_names,outputs.Loop.index)", "start_date": "$jmespath.(outputs.LatestData.response_payload.start_date || outputs.Start.date)" } } ``` ###### `array_chunks` Allow to create array of arrays with the fixed size. `array_chunks(array, chunk_size)` ``` { "name": "job_name", "definition": { "StartAt": "Start", "States": { "Start": { "Type": "MockData", "Data": { "array": [ "1","2","3","4","5","6","7","8","9" ] }, "Next": "Data" }, "Data": { "Type": "Data", "Data": { "chunks": "$jmespath.array_chunks(outputs.Start.array,`2`)" }, "End": true } } } } ``` Should provide following output ``` { "response_payload": { "chunks": [ [ "1", "2" ], [ "3", "4" ], [ "5", "6" ], [ "7", "8" ], [ "9" ] ] } } ``` ###### `add` Allow to add a number to number. Jmespath require that every Number should be inside "`" quotes `add(number1, number2)` ``` { "Start": { "Data": { "index": 2 }, "Next": "Math", "Type": "MockData" }, "Math": { "Data": { "index": "$jmespath.add(outputs.Start.index,`-1`)" }, "End": true, "Type": "Data" } } ``` ###### `concat` Allow to concat 2 strings. Jmespath require that every String should be inside "'" quotes `concat(string1, string2)` ``` { "Start": { "Data": { "name":"foo" }, "Next": "Math", "Type": "MockData" }, "Math": { "Data": { "name": "$jmespath.concat('bar ',outputs.Start.name)" }, "End": true, "Type": "Data" } } ``` ###### `split` Split a string using separator `split(string_1, separator)` ``` { "name": "split-test", "definition": { "StartAt": "Start", "States": { "Start": { "Type": "Data", "Data": { "people": [ { "@id": "id_replace", "@type": "person", "first_name": "person_name", "email_address": "email@email.com" } ] }, "Next": "Split" }, "Split": { "Type": "Data", "Data": { "domain": "$jmespath.outputs.Start.people[0].email_address | split(@,'@')[1]" }, "End": true } } } } ``` Will return, ``` { "name": "split-test", "status": "SUCCEEDED", "current_step": "Split", "response_payload": { "domain": "email.com" } } ``` ###### `replace` Allow to replace sub_string in a string. Jmespath require that every String should be inside "'" quotes `replace(where, to_replace, replace_with)` ``` { "States": { "Start": { "Type": "Data", "Data": { "data": "people[?@personal_identifier == PERSONAL_ID]" }, "Next": "Replace" }, "Replace": { "Type": "Data", "Data": { "replaced": "$jmespath.replace(outputs.Start.data,'PERSONAL_ID','123')" }, "End": true } } } ``` ###### `merge` Allow to concat 2 objects. Will merge two objects into one. All keys from `object2` will be present in result. For identical keys `object2` values will override `object1` values. This function does NOT do recursive merge. `merge(object1, object2)` ``` { "name": "test", "definition": { "StartAt": "A", "States": { "A": { "Type": "MockData", "Data": { "f1": "A", "f2": "A" }, "Next": "B" }, "B": { "Type": "MockData", "Data": { "f2": "B", "f3": "B" }, "Next": "C" }, "C": { "Type": "Data", "Data": { "result": "$jmespath.merge(outputs.A,outputs.B)" }, "End": true } } } } ``` ###### `date_format` Allow to format a date field formatting. `date_format(date, from_format, to_format)` ``` "Projection": { "created_at": "$jmespath.created_at | date_format(@, '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d')" } ``` ###### `date_end_day` Takes the date and make it end of the day. `date_end_day(date, format)` ``` "Projection": { "created_at_end":"$jmespath.created_at | date_end_day(@, '%Y-%m-%dT%H:%M:%S.%f%z')" } ``` ###### `date_start_day` Takes the date and make it start of the day. `date_start_day(date, format)` ``` "Projection": { "created_at_start":"$jmespath.created_at | date_start_day(@, '%Y-%m-%dT%H:%M:%S.%f%z')" } ``` ###### `date_now` Current datetime. `date_now(format)` ``` "Projection": { "now": "$jmespath.date_now('%Y-%m-%d %H:%M:%S.%f')" } ``` ###### `date_next_day` Takes the date and make it the next day. Equvalent of +1 day operation `date_next_day(date, format)` ``` "Projection": { "created_at_next": "$jmespath.created_at | date_next_day(@,'%Y-%m-%dT%H:%M:%S.%f%z') | date_format(@, '%Y-%m-%dT%H:%M:%S.%f%z','%Y-%m-%d %H:%M:%S')" } ``` ###### `date_previous_day` Takes the date and make it previoud day. Equvalent of -1 day operation `date_next_day(date, format)` ``` "Projection": { "created_at_prev": "$jmespath.created_at | date_previous_day(@,'%Y-%m-%dT%H:%M:%S.%f%z') | date_format(@, '%Y-%m-%dT%H:%M:%S.%f%z','%Y-%m-%d %H:%M:%S')" } ``` Example using Intrinsic Functions ``` { "name": "test", "description": "Create Transaction", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "Projection": { "transaction_id": "$jmespath.transaction_id", "created_at": "$jmespath.created_at", "created_at_next": "$jmespath.created_at | date_next_day(@,'%Y-%m-%dT%H:%M:%S.%f%z') | date_format(@, '%Y-%m-%dT%H:%M:%S.%f%z','%Y-%m-%d %H:%M:%S')", "created_at_prev": "$jmespath.created_at | date_previous_day(@,'%Y-%m-%dT%H:%M:%S.%f%z') | date_format(@, '%Y-%m-%dT%H:%M:%S.%f%z','%Y-%m-%d %H:%M:%S')", "created_at_end":"$jmespath.created_at | date_end_day(@, '%Y-%m-%dT%H:%M:%S.%f%z')", "created_at_start":"$jmespath.created_at | date_start_day(@, '%Y-%m-%dT%H:%M:%S.%f%z')", "created_at_formatted": "$jmespath.created_at | date_format(@, '%Y-%m-%dT%H:%M:%S.%f%z','%Y-%m-%d %H:%M:%S')", "now": "$jmespath.date_now('%Y-%m-%d %H:%M:%S.%f')" }, "End": true } } } } ``` Expected result ``` { "response_payload": { "transaction_id": "01GB858918AEZVTQMPAV5T1PF0", "created_at": "2022-08-24T10:49:11.465048-04:00", "created_at_next": "2022-08-25 10:49:11", "created_at_prev": "2022-08-23 10:49:11", "created_at_end": "2022-08-24T23:59:59.999999-0400", "created_at_start": "2022-08-24T00:00:00.000000-0400", "created_at_formatted": "2022-08-24 10:49:11", "now": "2022-08-24 14:49:11.494322" } } ``` ###### `date_to_iso` Takes the date and converts it to ISO format `date_to_iso(date, from_format)` ###### `date_to_iso_tz` Takes the date and converts it to ISO format by specifying TZ name `date_to_iso_tz(date, from_format, tz_name)` ###### `date_from_iso` Takes the date in ISO and converts it to `to_format` `date_from_iso(date, to_format)` ###### `date_to_iso_tz` and `date_from_iso` example ``` name: test-20221119-15 definition: StartAt: A States: A: Type: Data Data: date_EST: "2022-11-17 10:00:22.466" date_EDT: "2022-06-17 10:00:22.466" iso_EST: "2022-11-17T10:00:22.466000-05:00" iso_EDT: "2022-06-17T10:00:22.466000-04:00" from_iso: "2022-06-17T10:00:22.466000-04:00" foo: bar Next: B B: Type: Data Data: result: >- $jmespath.outputs.A.{ foo: foo, date_EST_iso: date_to_iso(date_EST, '%Y-%m-%d %H:%M:%S.%f'), date_EST: date_to_iso_tz(date_EST, '%Y-%m-%d %H:%M:%S.%f','America/New_York'), date_EDT: date_to_iso_tz(date_EDT, '%Y-%m-%d %H:%M:%S.%f','America/New_York'), iso_EST: date_from_iso(iso_EST,'%Y-%m-%d %H:%M:%S.%f TZ %z'), iso_EDT: date_from_iso(iso_EDT,'%Y-%m-%d %H:%M:%S.%f TZ %z') } result_2: >- $jmespath.outputs.A.{ date_EST: date_from_iso( date_to_iso_tz(date_EST, '%Y-%m-%d %H:%M:%S.%f','America/New_York'),'%Y-%m-%d %H:%M:%S.%f') } from_iso: >- $jmespath.outputs.A.{from_iso: date_from_iso(from_iso, '%Y-%m-%d %H:%M:%S.%f TZ %z')} End: true ``` ``` { "response_payload": { "result": { "date_EST_iso": "2022-11-17T10:00:22.466000", "date_EST": "2022-11-17T10:00:22.466000-05:00", "date_EDT": "2022-06-17T10:00:22.466000-04:00", "foo": "bar", "iso_EST": "2022-11-17 10:00:22.466000 TZ -05:00", "iso_EDT": "2022-06-17 10:00:22.466000 TZ -04:00" }, "result_2": { "date_EST": "2022-11-17 10:00:22.466000" }, "from_iso": { "from_iso": "2022-06-17 10:00:22.466000 TZ -04:00" } } } ``` #### States ##### InvokeProduct Invoke product state is main state type in the job. An API call is made to one of the Staircase products in the InvokeProduct state. You must define the resource definition for the action you will take. The following example demonstrates how to invoke Persistence Product to create a transaction ``` "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {} "Next": "CreateCollection" } ``` ###### Path Full path to a Staircase product api. Should NOT start from `/`. Can contain `{path_name}` path parameters and/or query parameters ``` { "Path": "code-health-checker/performance/metrics/products/{product_name}?start_date={start_date}&end_date={end_date}&status=failed&limit=10" } ``` ###### PathParameters ``` { "Path": "console-pipeline/pipelines/{pipeline_name}/data/latest?sort_column=created_at", "PathParameters": { "pipeline_name": "$.outputs.Start.pipeline_name" } } ``` ###### EnvironmentSettings Environment settings allow to invoke Staircase product on the other Staircase environment. `EnvironmentSettings` consists of: - `Host` - `ApiKey` It is NOT allowed to set static string values. Both `Host` and `ApiKey` can contain on of following: - JSON-path - JMESPath - `$$.CurrentValue` In case `Host` and/or `ApiKey` use JSON-path or JMESPath, `Host` and `ApiKey` can ONLY refer to `$.request_payload`. `Host` and `ApiKey` can be defined while Executing a Job in `request_payload`. Example of a job to create Transaction on other Staircase eenvironment. ``` { "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "EnvironmentSettings": { "Host": "$.request_payload.Host", "ApiKey": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "Method": "POST", "RequestPayload": { "label":"$.request_payload.label" }, "End": true } } } } ``` In case `Host` and/or `ApiKey` use `$$.CurrentValue`, ``` { "GetServiceKey": { "Type": "InvokeProduct", "Method": "GET", "Path": "environment-manager/service-key", "EnvironmentSettings": { "Host": "$$.CurrentValue" }, "IterationSettings": { "IterateOverPath": "$.outputs.Subscribers.response_payload.subscribed_domains", "MaxConcurrency": 10 }, "Next": "SomeData" } } ``` ###### Headers Headers allow to add custom headers to the request. For example, `Authorization` header. It is possible to use JSON-path or JMESPath inside `Headers`. Example of a job with `EnvironmentSettings` and `Headers`. ``` { "name": "test", "definition": { "StartAt": "Start", "States": { "Start": { "Type": "MockData", "Data": { "token": "bar" }, "Next": "Product" }, "Product": { "Type": "InvokeProduct", "Path": "administrator/costs", "Method": "GET", "EnvironmentSettings": { "Host": "$.request_payload.Host", "ApiKey": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "Headers": { "Authorization": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" }, "End": true } } } } ``` ###### QueryParameters Query Paramerts allow to specify Query string of a HTTP request. Only non-null values will be added to a query string. ``` { "Type": "InvokeProduct", "Method": "GET", "Path": "code-health-checker/performance/metrics/products/{product_name}?status=failed", "QueryParameters": { "start_date": "$jmespath.(outputs.LatestData.response_payload.created_at || outputs.Start.date) | date_next_day(@,'%Y-%m-%d')", "end_date": "$jmespath.date_now('%Y-%m-%d') | date_previous_day(@,'%Y-%m-%d')", "limit": 10, "next_token": "$jmespath.outputs.Current_Step.response_payload.next_token || outputs.Start.next_token" }, "PathParameters": { "product_name": "$.outputs.Start.product_name" } } ``` ###### Method Any valid HTTP method ###### RequestPayload Can be an object, ``` { "RequestPayload": { "collection_without_soft_credit": "$.outputs.DeleteSoftCreditInformation.response_payload.collection_id", "hard_credit_collection": "$.outputs.PatchHardCreditCollectionSsn.response_payload.collection_id", "loan_collection": "$.outputs.CreateChosenLoanCollection.response_payload.collection_id", "transaction_id": "$.transaction_id" } } ``` Can be a string, ``` { RequestPayload": "$.outputs.Health.response_payload.metrics" } ``` Can be an array, ``` { "Product": { "Type": "InvokeProduct", "Path": "path/", "Method": "POST", "EnvironmentSettings": { "Host": "$.request_payload.Host" }, "QueryParameters": { "foo": "$.outputs.Start.foo" }, "RequestPayload": [ "$jmespath.outputs.Start" ], "End": true } } ``` ###### CallbackSettings For callback settings, the expected path must be specified in the incoming callback message. It can optionally be specified in the value corresponding to this path. ``` "Build": { "Type": "InvokeProduct", "Path": "infra-builder/builds", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveAssessResponse.response_payload.source_url" }, "CallbackSettings": { "Path": "$.callback_url", }, "Next": "NextState" } ``` `Path` defines path to callback_url in request payload to Product. You can see default value above. ###### WaitForCallback It can optionally be specified in the value corresponding to this path. `WaitForCallback` can be `true`. In this case all default values will be applied. The following example invoke Staircase Build product ``` "Build": { "Type": "InvokeProduct", "Path": "infra-builder/builds", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveAssessResponse.response_payload.source_url" }, "WaitForCallback": { "ExpectedPath": "$.status", "ExpectedValues": ["SUCCEEDED"], "FailedValues": ["ERROR", "FAILED"] }, "Next": "NextState" } ``` `WaitForCallback` default values are ``` "ExpectedPath": "status", "ExpectedValues": [ "SUCCEEDED", "Succeeded", "COMPLETED", "Completed" ], "FailedValues": [ "CANCELLED", "Cancelled", "FAILED", "Failed", "ERROR", "Error", "TIME_OUT", "Time_out" ], ``` ###### TimeoutSeconds `TimeoutSeconds` (Optional). If the task runs longer than the specified seconds, this state fails with a Timeout. Must be a positive, non-zero integer. If not provided, the default value is 3600. ###### Retry `Retry` (Optional). Retry logic if any error in InvokeProduct happens it does retry. Example of State with Retry usage: ``` "CreateCollection": { "Type": "InvokeProduct", "Path": "persistence/transactions/{transaction_id}/collections", "Method": "POST", "PathParameters": { "transaction_id": "$.transaction_id" }, "RequestPayload": { "metadata": { "version": 2, "validation": true }, "data": "$.request_payload.collection_data" }, "Retry": { "IntervalSeconds": 10, "MaxAttempts": 10, }, "Next": "MockData" }, ``` Both values are required and accepts int values. ###### After `After` (Optional). Specifies type of action to execute after response from a product was received. Usually this is used when Product returns `data` instead of `response_collection_id`. Supported after actions: - `CreateCollection` will create a collection using Product response as a payload. Accepts `product_response_data_path` to prodive json path to response data - `CreateReference` will create a reference to a dataset. Can be used later f.e. `IterationSettings` -> `Reference` `CreateReference` Accepts: - `reference_name` (Optional). Name of the reference to be save. Going to available later in current Job Execution. If not specifed, Step name will be used. - `product_response_data_path` (Optional). Path in the Product response to a data to be saved as a reference. - `product_response_data_url` (Optional). Path in the Product response to a URL where data for a Reference is located. Job product will download the data and place and create new Reference. It is possible to Get All saved references back from the Job Execution. Example of After action that saves InvokeProduct response as a reference. ``` { "GetTelemetry": { "Type": "InvokeProduct", "Method": "POST", "Path": "job/stats", "Projection": "$.data", "After": [ { "CreateReference": { "reference_name": "job_stats", "product_response_data_path": "$" } } ], "Next": "SaveTelemetry" } } ``` Example of After action that saves Connector response with URL as a reference. ``` { "ToJSON": { "Type": "InvokeProduct", "Path": "connector-jobs/transformations/csv-to-json/async", "Method": "PUT", "RequestPayload": { "transaction_id": "$.transaction_id", "urls": { "download_from_url": "$.outputs.RunSQL.response_payload.url" }, "configuration": { "delimiter": "," } }, "WaitForCallback": { "ExpectedPath": "$.status" }, "After": [ { "CreateReference": { "reference_name": "sql_results", "product_response_data_url": "$.result.temporary_url" } } ], "Next": "MoveToMortgage" } } ``` `CreateCollection` For example to be able to Translate payload and save to collection Instead of ``` { "TranslateAssets": { "Method": "POST", "Next": "CreateCollectionV2Assets", "Path": "translator/translate", "RequestPayload": { "data": "$.outputs.CheckStatusAssets.response_payload.data", "lang_from": "staircase", "lang_to": "staircase", "metadata": { "transaction_id": "$.transaction_id" }, "sc_version_from": 0, "sc_version_to": 2 }, "Type": "InvokeProduct" }, "CreateCollectionV2Assets": { "Method": "POST", "Next": "InvokeSoftCredit", "Path": "persistence/transactions/{transaction_id}/collections", "PathParameters": { "transaction_id": "$.transaction_id" }, "RequestPayload": { "data": "$.outputs.TranslateAssets.response_payload", "metadata": { "version": 2 } }, "Retry": { "IntervalSeconds": 3, "MaxAttempts": 2 }, "Type": "InvokeProduct" } } ``` it is recommended to use After action ``` "TranslateAssets": { "Method": "POST", "Next": "CreateCollectionV2Assets", "Path": "translator/translate", "RequestPayload": { "data": "$.outputs.CheckStatusAssets.response_payload.data", "lang_from": "staircase", "lang_to": "staircase", "metadata": { "transaction_id": "$.transaction_id" }, "sc_version_from": 0, "sc_version_to": 2 }, "Type": "InvokeProduct", "After": [ { "CreateCollection": { "product_response_data_path": "$.response_payload", "validation": false } } ] } ``` ###### Projection `Projection` (Optional). Specifies the field(s) to return. To return all fields, omit this parameter. Can be a String or an Object. In case InvokeProduct has `CallbackSetting` Projection is going to be applied to callback response payload `$`, otherwise Projection is going to be applied to `$.response_payload`. In case InvokeProduct has `IterationSettings` it is possible to use `$$.CurrentValue` inside projection. Example of Projection as a String `"Projection":"$.collection_id"`. It will put only "$.collection_id" value in your response_payload object. ``` { "name": "demo-job-01", "description": "Demo demo-job-01", "definition": { "StartAt": "CreateCollection", "States": { "CreateCollection": { "Type": "InvokeProduct", "Path": "persistence/transactions/{transaction_id}/collections", "Method": "POST", "PathParameters": { "transaction_id": "$.transaction_id" }, "RequestPayload": { "metadata": { "version": 2, "validation": true }, "data": "$.request_payload.collection_data" }, "Projection":"$.collection_id", "Next": "MockData" }, "MockData": { "Type": "MockData", "Data": { "foo": "bar" }, "Next": "Aggregation" }, "Aggregation": { "Type": "OutputAggregate", "Aggregation": { "collection_id.$": "$.outputs.CreateCollection.response_payload", "mock_foo.$": "$.outputs.MockData.foo" }, "End": true } } } } ``` Example of Projection as a Object ``` "Projection": {"collection_id": "$.collection_id"} ``` It will put `my_collection_id` in your response_payload with a value of "$.collection_id". ``` { "name": "demo-job-01", "description": "Demo demo-job-01", "definition": { "StartAt": "CreateCollection", "States": { "CreateCollection": { "Type": "InvokeProduct", "Path": "persistence/transactions/{transaction_id}/collections", "Method": "POST", "PathParameters": { "transaction_id": "$.transaction_id" }, "RequestPayload": { "metadata": { "version": 2, "validation": true }, "data": "$.request_payload.collection_data" }, "Projection": {"my_collection_id": "$.collection_id"}, "Next": "MockData" }, "MockData": { "Type": "MockData", "Data": { "foo": "bar" }, "Next": "Aggregation" }, "Aggregation": { "Type": "OutputAggregate", "Aggregation": { "collection_id.$": "$.outputs.CreateCollection.response_payload.my_collection_id", "mock_foo.$": "$.outputs.MockData.foo" }, "End": true } } } } ``` Example using `Projection` with `$$.CurrentValue` ``` { "GetServiceKey": { "Type": "InvokeProduct", "Method": "GET", "Path": "environment-manager/service-key", "Projection": { "domain_name": "$$.CurrentValue", "service_key": "$.service_key" }, "IterationSettings": { "IterateOverPath": "$.outputs.Subscribers.response_payload.subscribed_domains", "MaxConcurrency": 10 }, "Next": "SomeData" } } ``` ###### Projection Examples Example of Projection for Invoke Product ``` "Projection": { "invocation_status": "$.invocation_status", "request_collection_id": "$.request_collection_id", "response_collection_id": "$.response_collection_id" } ``` Example of Projection for Execute Job ``` "Projection": { "response_payload": "$.response_payload", "execution_id": "$.execution_id" } ``` ###### Iteration Settings Job supports iteration settings for dynamic parallelism. `IterationSettings` can be used to run a set of steps for each element of an input array or reference. `IterationSettings` for an array If you add `IterationSettings` to you state, InvokeProduct state will execute the same steps for multiple entries of an array in the state input. Accepts: - `IterateOverPath` The IterateOverPath field's value is a reference path identifying where in the effective input the array field is found (Required) - `MaxConcurrency` (Optional) The MaxConcurrency field's value is an integer that provides an upper bound on how many invocations of the Iterator may run in parallel. Default value is `4`. For instance, a MaxConcurrency value of 10 will limit your Map state to 10 concurrent iterations running at one time. The value of 0, will places no limit on concurency. Step Functions invokes iterations as concurrently as possible. There are two additional items available in the context object when processing a state with IterationSetting The `$$.CurrentIndex` contains the index number for the arraIterationSettingsitem that is being processed in the current iteration The `$$.CurrentValue` contains the value for the array item that is being processed in the current iteration ``` "CreateCollection": { "Type": "InvokeProduct", "Path": "persistence/transactions/{transaction_id}/collections", "PathParameters": { "transaction_id": "$.outputs.CreateTransaction.response_payload.transaction_id" }, "Method": "POST", "RequestPayload": {"data": "$$.CurrentValue"}, "IterationSettings": { "IterateOverPath": "$.request_payload.items", "MaxConcurrency": 5, }, "Next": "CreateTransaction2", } ``` `IterationSettings` using Reference Will use one the Saved References as an input for iteration. Iterating over Reference allow to expand limits of Job product, such as `events history size`, `state machine size` etc. It is important to make sure reference saved points to an array. Accepts: - `Reference` Name of the saved reference. - `ReferenceType` Type of the saved reference `JSON` or `CSV` - `BatchSize` (Optional) Batch size for single Iteration. Please make sure InvokeProduct enpoint can accepts array instead of object. - `ToleratedFailureCount` (Optional) Error handling configuration where you can set count of errors to tolerate. - `ToleratedFailurePercentage` (Optional) Error handling configuration where you can set percentage of errors to tolerate. - `MaxConcurrency` (Optional) If you set it to zero, Job doesn't limit concurreny and runs 10,000 parallel child workflow executions. Default value is `4`. Example of `IterationSettings` using Reference ``` { "SaveTelemetry": { "Method": "POST", "Path": "console-pipeline/pipelines/{pipeline_name}/datasets/main/data", "PathParameters": { "pipeline_name": "$.request_payload.pipeline_name" }, "QueryParameters": { "account_name": "$.request_payload.domain_name", "transaction_id": "$.transaction_id", "created_at": "$jmespath.start_time | date_format(@, '%Y-%m-%dT%H:%M:%S.%f%z', '%Y-%m-%d %H:%M:%S')" }, "RequestPayload": "$$.CurrentValue", "Type": "InvokeProduct", "IterationSettings": { "Reference": "job_stats", "BatchSize": 20, "ToleratedFailureCount": 100, "ToleratedFailurePercentage": 0 }, "Retry": { "IntervalSeconds": 10, "MaxAttempts": 5 }, "End": true } } ``` ##### InvokeJob `InvokeJob` initiates a direct synchronous call to another Job. Being inherently synchronous, `InvokeJob` will invariably wait for the other job to finish before proceeding. The following example demonstrates how to invoke other Job ``` "FIPS": { "Type": "InvokeJob", "JobName": "get-data-fips", "RequestPayload": {} "Next": "SQL" } ``` ###### JobName Job Name to invoke. Job should be created before using Create Job ###### RequestPayload Request Payload to be passed to Job execution. See `Request Payload` in Execute Job Should always be an object, ``` { "Create": { "Type": "InvokeJob", "JobName": "sql-execute-and-wait", "TransactionId": "$.transaction_id", "RequestPayload": { "sql": "$.outputs.Start.create_sql", "parameters": [ "$.outputs.FIPS.fips_counties_prefixes_start" ] }, "Next": "Insert" } } ``` ###### TransactionId TransactionID to be passed to Job execution. See `Transaction ID` in Execute Job If TransactionID was not provided, Job product will generate new Transaction ID. ###### Projection Specifies the field(s) to return. To return all fields, omit this parameter. Should always be an object. Projection is going to be applied to `$.response_payload` of a Job. Projection does not support JMESPATH. Example of Projection ``` { "Projection": { "fips_counties_prefixes_start": "$.fips_counties_prefixes_start", "fips_counties_prefixes_continue": "$.fips_counties_prefixes_continue" } } ``` ``` { "FIPS": { "Type": "InvokeJob", "JobName": "get-data-fips", "TransactionId": "$.transaction_id", "Projection": { "fips_counties_prefixes_start": "$.fips_counties_prefixes_start", "fips_counties_prefixes_continue": "$.fips_counties_prefixes_continue" }, "Next": "SQL" } } ``` ##### AthenaStartQuery This type allows invoking AWS Athena directly, without API invocations or additional job definitions. AthenaStartQuery is a synchronous operation, which means its state will be 'RUNNING' as soon as the SQL request starts running. Accepts: - `Query`. SQL query to execute. Should be a string - `Parameters` (Optional). Arrays of SQL Query parameters to use - `WorkGroup` (Optional). AWS Athena workgroup to use. Default value is: `primary` Outputs: - `QueryExecutionId`. ID of the query execution The following example executes SQL and get results as URL or CSV Reference ``` { "name": "athena-test", "definition": { "StartAt": "Data", "States": { "Data": { "Type": "Data", "Next": "Start", "Data": { "params": [ "NY" ] } }, "Start": { "Type": "AthenaStartQuery", "Query": "SELECT * FROM \"db_name\".\"addresses\" WHERE state = ? limit 10", "Parameters": "$.outputs.Data.params", "Next": "Get" }, "Get": { "Type": "AthenaGetResults", "QueryExecutionId": "$.outputs.Start.QueryExecutionId", "Next": "GetUrl" }, "GetUrl": { "Type": "AthenaGetResultsAsUrl", "QueryExecutionId": "$.outputs.Start.QueryExecutionId", "Next": "GetReference" }, "GetReference": { "Type": "AthenaGetResultsAsReference", "QueryExecutionId": "$.outputs.Start.QueryExecutionId", "ReferenceName": "reference_name_foo", "End": true } } } } ``` ##### AthenaGetResults Gets SQL Results as data inside the Job state machine Accepts: - `QueryExecutionId`. SQL query to execute. Should be a string Outputs: - `Data`. JSON array that represents rows from SQL query results ##### AthenaGetResultsAsUrl Accepts: - `QueryExecutionId`. SQL query to execute. Should be a string Outputs: - `URL`. Pre-signed url to download results. File is in the format of CSV ##### AthenaGetResultsAsReference Accepts: - `QueryExecutionId`. SQL query to execute. Should be a string - `ReferenceName`. Reference name to be created in current Job execution. Similar to CreateReference Outputs: - Reference name that was created The following example executes SQL, creates Reference and executes IterationSettings using Reference ``` { "name": "athena-test", "definition": { "StartAt": "Start", "States": { "Start": { "Type": "AthenaStartQuery", "Query": "SELECT * FROM \"batch-data-load\".\"sc-first-american-listings-unique\" limit 10000;", "Next": "GetReference" }, "GetReference": { "Type": "AthenaGetResultsAsReference", "QueryExecutionId": "$.outputs.Start.QueryExecutionId", "ReferenceName": "listings", "Next": "InvokeJobs" }, "InvokeJobs": { "Type": "InvokeProduct", "Path": "job/jobs/{job_name}/executions", "Method": "POST", "IterationSettings": { "IterateOverPath": "$", "Reference": "listings", "ReferenceType": "CSV", "BatchSize": 2, "ToleratedFailurePercentage": 5, "MaxConcurrency": 10 }, "PathParameters": { "job_name": "athena-test-empty" }, "RequestPayload": { "transaction_id": "$.transaction_id", "request_payload": { "data": "$$.CurrentValue" } }, "WaitForCallback": { "ExpectedPath": "$.status" }, "End": true } } } } ``` ##### Choice A Choice state adds branching logic to a state machine. `Choices` (Required): An array of Choice Rules that determines which state the state machine transitions to next `Default` (Optional, Recommended): The name of the state to transition to if none of the transitions in Choices is taken Choice Rules A Choice state must have a Choices field whose value is a non-empty array, and whose every element is an object called a Choice Rule. A Choice Rule contains the following: - A comparison - Two fields that specify an input variable to compare, the type of comparison, and the value to compare the variable to. Choice Rules support comparison between two variables. Within a Choice Rule, the value of Variable can be compared with another value from the state input by appending Path to name of supported comparison operators. - A Next field - The value of this field must match a state name in the state machine. The following example checks whether the numerical value is equal to 1. ``` { "Variable": "$.foo", "NumericEquals": 1, "Next": "FirstMatchState" } ``` The following example checks whether the string is equal to MyString. ``` { "Variable": "$.foo", "StringEquals": "MyString", "Next": "FirstMatchState" } ``` Supported Operations The following comparison operators are supported: - And - BooleanEquals,BooleanEqualsPath - IsBoolean - IsNull - IsNumeric - IsPresent - IsString - IsTimestamp - Not - NumericEquals,NumericEqualsPath - NumericGreaterThan,NumericGreaterThanPath - NumericGreaterThanEquals,NumericGreaterThanEqualsPath - NumericLessThan,NumericLessThanPath - NumericLessThanEquals,NumericLessThanEqualsPath - Or - StringEquals,StringEqualsPath - StringGreaterThan,StringGreaterThanPath - StringGreaterThanEquals,StringGreaterThanEqualsPath - StringLessThan,StringLessThanPath - StringLessThanEquals,StringLessThanEqualsPath - StringMatches - TimestampEquals,TimestampEqualsPath - TimestampGreaterThan,TimestampGreaterThanPath - TimestampGreaterThanEquals,TimestampGreaterThanEqualsPath - TimestampLessThan,TimestampLessThanPath - TimestampLessThanEquals,TimestampLessThanEqualsPath ##### Wait A Wait state delays the state machine from continuing for a specified time. The following Wait state introduces a 10-second delay into a state machine ``` "wait_ten_seconds": { "Type": "Wait", "Seconds": 10, "Next": "NextState" } ``` ##### MockData MockData could be used to generate and place some static data. Common usecase would be a usage of this step instead of InvokeProduct if it is not implemented. ``` "AddingSomeDataInsideJob": { "Type": "MockData", "Data": { "foo": "bar", }, "Next": "NextState" } ``` Will produce following result ``` { "outputs": { "AddingSomeDataInsideJob": { "foo": "bar" } } } ``` ##### Data Data could be used to generate new data from the `$.outputs.*`. ``` { "Start": { "Data": { "array": [ "a", "b", "c", "d", "e" ] }, "Next": "Data", "Type": "MockData" }, "Data": { "Data": { "size.$": "States.ArrayLength($.outputs.Start.array)" }, "End": true, "Type": "Data" }, } ``` Will produce following result ``` { "Data": { "size": 5 }, "Start": { "array": [ "a", "b", "c", "d", "e" ] } } ``` ##### OutputAggregate OutputAggregate is used to clear all state results from outputs and create new step data. ``` "AddingSomeDataInsideJob": { "Type": "OutputAggregate", "Aggregation": { "foo": "bar", "foo.$": "$.outputs.PreviousStep.foo" }, "Next": "NextState" } ``` `Aggregation` as an object allow to construct Step output with custom fields. Example of MockData used together with OutputAggregate ``` { "name": "JobRandom", "description": "", "definition": { "StartAt": "State", "States": { "State": { "Type": "MockData", "Result": { "foo": "bar" }, "Next": "State1" }, "State1": { "Type": "MockData", "Result": { "bar": "bar" }, "Next": "State2" }, "State2": { "Type": "OutputAggregate", "Aggregation": { "foonew.$": "$.outputs.State.foo" }, "End": true } } } } ``` `Aggregation` as a String allow to set object from from different step. Example of OutputAggregate override state outputs with results from "State" ``` { "name": "JobRandom", "description": "", "definition": { "StartAt": "State", "States": { "State": { "Type": "MockData", "Result": { "foo": "bar" }, "Next": "State1" }, "State1": { "Type": "MockData", "Result": { "bar": "bar" }, "Next": "State2" }, "State2": { "Type": "OutputAggregate", "Aggregation": "$.outputs.State", "End": true } } } } ``` ##### Wait for action Wait for action allows to pause job execution and wait for resume action. The following Wait for action will pause job execution ``` "wait_for_action": { "Type": "WaitForAction", "Next": "NextState" } ``` ##### Wait for callback State waits for callback from a product. WaitForCallback can be used to specify success and/or failed values. This step behaviour is the same as waitforcallback in the InvokeProduct `StepName` should point to a Step defined before with `CallbackSettings` It is also possible to specify `Projection` in the WaitForCallback. In that case it will be applied to the to callback response payload `$`. See more details in the `InvokeProduct` section Projection The following Wait for action will pause job execution ``` "WaitForCallback": { "Type": "WaitForCallback", "StepName": "step_name", "ExpectedPath": "$.status", "ExpectedValues": ["SUCCEEDED"], "FailedValues": ["ERROR", "FAILED"], "Next": "NextState" } ``` ##### Examples ###### Create Transaction Job Example ``` { "name": "CreateTransaction", "description": "Create Transaction", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {} "End": true } } } } ``` ###### DevOps Pipeline Job ``` { "name": "pipeline", "description": "Devops Pipeline", "definition": { "StartAt": "Clone", "States": { "Clone": { "Type": "InvokeProduct", "Path": "code/clone", "Method": "POST", "RequestPayload": { "project_name": "$.request_payload.product_name", "branch": "$.request_payload.branch_name", "github_account": "GITHUB_ACCOUNT", "github_token": "GITHUB_TOKEN" }, "Next": "WaitCloneStatus20Secs" }, "WaitCloneStatus20Secs": { "Type": "Wait", "Seconds": 20, "Next": "RetrieveCloneStatus" }, "RetrieveCloneStatus": { "Type": "InvokeProduct", "Path": "code/clone/{bundle_id}", "Method": "GET", "PathParameters": { "bundle_id": "$.outputs.Clone.response_payload.bundle_id" }, "Next": "CheckCloneStatus" }, "CheckCloneStatus": { "Type": "Choice", "Choices": [ { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "SUCCEEDED", "Next": "Assess" }, { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "FAILED", "Next": "FailState" }, { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "IN_PROGRESS", "Next": "WaitCloneStatus20Secs" } ] }, "Assess": { "Type": "InvokeProduct", "Path": "code-assessor/assessments", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveCloneStatus.response_payload.source_url" }, "Next": "WaitAssessStatus30Secs" }, "WaitAssessStatus30Secs": { "Type": "Wait", "Seconds": 30, "Next": "RetrieveAssessStatus" }, "RetrieveAssessStatus": { "Type": "InvokeProduct", "Path": "code-assessor/assessments/{assessment_id}", "Method": "GET", "PathParameters": { "assessment_id": "$.outputs.Assess.response_payload.assessment_id" }, "Next": "CheckAssessStatus" }, "CheckAssessStatus": { "Type": "Choice", "Choices": [ { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "SUCCEEDED", "Next": "Build" }, { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "FAILED", "Next": "FailState" }, { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "IN_PROGRESS", "Next": "WaitAssessStatus30Secs" } ] }, "Build": { "Type": "InvokeProduct", "Path": "infra-builder/builds", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveAssessStatus.response_payload.source_url" }, "CallbackSettings": { "ExpectedPath": "$.status", "ExpectedValue": "SUCCEEDED" }, "Next": "Wait10SecGetBuildResults" }, "Wait10SecGetBuildResults": { "Type": "Wait", "Seconds": 10, "Next": "GetBuildResults" }, "GetBuildResults": { "Type": "InvokeProduct", "Path": "infra-builder/builds/{build_id}", "Method": "GET", "PathParameters": { "build_id": "$.outputs.Build.response_payload.bundle_id" }, "Next": "Deploy" }, "Deploy": { "Type": "InvokeProduct", "Path": "infra-deployer/deploy-by-token", "Method": "POST", "RequestPayload": { "artifacts_url": "$.outputs.GetBuildResults.response_payload.artifacts_url", "environment_token": "$.request_payload.environment_token" }, "CallbackSettings": { "ExpectedPath": "$.status", "ExpectedValue": "SUCCEEDED" }, "Next": "Wait10SecGetDeployResults" }, "Wait10SecGetDeployResults": { "Type": "Wait", "Seconds": 10, "Next": "GetDeployResults" }, "GetDeployResults": { "Type": "InvokeProduct", "Path": "infra-deployer/deploy/{bundle_id}", "Method": "GET", "PathParameters": { "bundle_id": "$.outputs.Deploy.response_payload.bundle_id" }, "End": true }, "FailState": { "Type": "Fail", "Cause": "Failed.", "Error": "Failed" } } } } ``` ##### Request CreateTransactionDevOps Pipeline JobCreate Job With Iteration Settings application/json Copy ``` { "name": "CreateTransaction", "description": "Create Transaction", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "End": true } } } } ``` application/json Copy ``` { "name": "pipeline", "description": "DevOps Pipeline", "definition": { "StartAt": "Clone", "States": { "Clone": { "Type": "InvokeProduct", "Path": "code/clone", "Method": "POST", "RequestPayload": { "project_name": "$.request_payload.product_name", "branch": "$.request_payload.branch_name", "github_account": "GITHUB_ACCOUNT", "github_token": "GITHUB_TOKEN" }, "Next": "WaitCloneStatus20Secs" }, "WaitCloneStatus20Secs": { "Type": "Wait", "Seconds": 20, "Next": "RetrieveCloneStatus" }, "RetrieveCloneStatus": { "Type": "InvokeProduct", "Path": "code/clone/{bundle_id}", "Method": "GET", "PathParameters": { "bundle_id": "$.outputs.Clone.response_payload.bundle_id" }, "Next": "CheckCloneStatus" }, "CheckCloneStatus": { "Type": "Choice", "Choices": [ { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "SUCCEEDED", "Next": "Assess" }, { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "FAILED", "Next": "FailState" }, { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "IN_PROGRESS", "Next": "WaitCloneStatus20Secs" } ] }, "Assess": { "Type": "InvokeProduct", "Path": "code-assessor/assessments", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveCloneStatus.response_payload.source_url" }, "Next": "WaitAssessStatus30Secs" }, "WaitAssessStatus30Secs": { "Type": "Wait", "Seconds": 30, "Next": "RetrieveAssessStatus" }, "RetrieveAssessStatus": { "Type": "InvokeProduct", "Path": "code-assessor/assessments/{assessment_id}", "Method": "GET", "PathParameters": { "assessment_id": "$.outputs.Assess.response_payload.assessment_id" }, "Next": "CheckAssessStatus" }, "CheckAssessStatus": { "Type": "Choice", "Choices": [ { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "SUCCEEDED", "Next": "Build" }, { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "FAILED", "Next": "FailState" }, { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "IN_PROGRESS", "Next": "WaitAssessStatus30Secs" } ] }, "Build": { "Type": "InvokeProduct", "Path": "infra-builder/builds", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveAssessStatus.response_payload.source_url" }, "CallbackSettings": { "ExpectedPath": "status", "ExpectedValue": "SUCCEEDED" }, "Next": "Wait10SecGetBuildResults" }, "Wait10SecGetBuildResults": { "Type": "Wait", "Seconds": 10, "Next": "GetBuildResults" }, "GetBuildResults": { "Type": "InvokeProduct", "Path": "infra-builder/builds/{build_id}", "Method": "GET", "PathParameters": { "build_id": "$.outputs.Build.response_payload.bundle_id" }, "Next": "Deploy" }, "Deploy": { "Type": "InvokeProduct", "Path": "infra-deployer/deploy-by-token", "Method": "POST", "RequestPayload": { "artifacts_url": "$.outputs.GetBuildResults.response_payload.artifacts_url", "environment_token": "$.request_payload.environment_token" }, "CallbackSettings": { "ExpectedPath": "status", "ExpectedValue": "SUCCEEDED" }, "Next": "Wait10SecGetDeployResults" }, "Wait10SecGetDeployResults": { "Type": "Wait", "Seconds": 10, "Next": "GetDeployResults" }, "GetDeployResults": { "Type": "InvokeProduct", "Path": "infra-deployer/deploy/{bundle_id}", "Method": "GET", "PathParameters": { "bundle_id": "$.outputs.Deploy.response_payload.bundle_id" }, "End": true }, "FailState": { "Type": "Fail", "Cause": "Failed.", "Error": "Failed" } } } } ``` application/json Copy ``` { "name": "Dynamic Parallelism", "description": "MAP", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "Next": "CreateCollection" }, "CreateCollection": { "Type": "InvokeProduct", "Path": "persistence/transactions/{transaction_id}/collections", "PathParameters": { "transaction_id": "$.outputs.CreateTransaction.response_payload.transaction_id" }, "Method": "POST", "RequestPayload": { "data": "$$.CurrentValue.data" }, "IterationSettings": { "IterateOverPath": "$.request_payload.items", "MaxConcurrency": 5 }, "End": true } } } } ``` ##### Response 201400 Already Exist400 Invalid Job Name400 Invalid Job Definition403500503 application/json Copy Create Job API Triggered Successfully ``` { "name": "Job name", "description": "Job Description", "product_name": "Product", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "Retry": { "MaxAttempts": 3, "IntervalSeconds": 5 }, "End": true } } } } ``` application/json Copy Bad Request ``` { "message": "Job {job_name} is exist!" } ``` application/json Copy Bad Request ``` { "message": "Invalid job name!" } ``` application/json Copy Bad Request ``` { "message": "Invalid job definition!" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy Service Unavailable ``` { "message": "Job is in deleting process! Try after a few seconds" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Job Name | | `description`required | `string` | Job Description | | `product_name` | `string` | Product Name | | `definition`required | `object` | Job Definition | | `StartAt`required | `string` | The first state | | `States`required | `object` | Job States | | `STATE_NAME` | `object` | Name of the State | | `Method` | `string` | Method | | `Path` | `string` | Path | | `PathParameters` | `object` | PathParameters | | `QueryParameters` | `object` | QueryParameters | | `RequestPayload` | `object` | RequestPayload | | `CallbackSettings` | `object` | CallbackSettings | | `WaitForCallback` | `object` | WaitForCallback | | `Projection` | `object` | Projection | | `After` | `object` | After Action | | `Type`required | `string` | State type`Choice``Data``Fail``InvokeProduct``MockData``OutputAggregate``Pass``Succeed``Wait``WaitForAction``WaitForCallback` | | `End` | `boolean` | End of the job definition | | `Next` | `string` | Next State Name | | `ExceptNext` | `string` | Next State if any error occurs | | `Retry` | `object` | Retry Settings | | `TimeoutSeconds` | `integer` | If the task runs longer than the specified seconds, this state fails with a Timeout. Must be a positive, non-zero integer. If not provided, the default value is 3600. | | `IterationSettings` | `object` | If you add IterationSetting to you state, InvokeProduct state will execute the same steps for multiple entries of an array in the state input | ##### Response `201``application/json` 4 fields Create Job API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Job Name | | `description` | `string` | Job Description | | `product_name` | `string` | Name of product | | `definition` | `object` | Job Definition | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/jobs` #### Retrieve All Jobs `listJobs` Retrieves Existing Jobs ##### Response 200403500 application/json Copy Retrieve Jobs ``` [ { "$ref": "#/components/examples/GetJobResp" } ] ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 4 fields Retrieve Jobs | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Job Name | | `description` | `string` | Job Description | | `product_name` | `string` | Name of product | | `definition` | `object` | Job Definition | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/jobs/{job_name}` #### Retrieve Job `getJob` Retrieve Job returns the content of a given job. ##### Response 200400403404500 application/json Copy Retrieve Job ``` { "name": "Job name", "description": "Job Description", "product_name": "Product", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "Retry": { "MaxAttempts": 3, "IntervalSeconds": 5 }, "End": true } } } } ``` application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job not found" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | ##### Response `200``application/json` 4 fields Retrieve Job | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Job Name | | `description` | `string` | Job Description | | `product_name` | `string` | Name of product | | `definition` | `object` | Job Definition | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/jobs/executions` #### Create Job[new] `retrieveExecutionsMetrics` Retrieve Executions Metrics ##### Response 200403500 application/json Copy Retrieve Executions Metrics ``` [ { "name": "job-name-1", "datapoints": [ { "Timestamp": "2023-11-24T10:00:00.000000Z", "Sum": 1 } ] }, { "name": "job-name-2", "datapoints": [ { "Timestamp": "2023-11-24T12:00:00.000000Z", "Sum": 3 } ] } ] ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `start_time` | `string` query | `2023-11-24T00:00:00` | Start time | | `end_time` | `string` query | `2023-11-25T00:00:00` | End time | ##### Response `200``application/json` 2 fields Retrieve Executions Metrics | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Job Name | | `datapoints` | `object[]` | datapoints | | `Timestamp` | `string` | Timestamp | | `Sum` | `string` | Sum | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `PUT` `/jobs/{job_name}` #### Update Job `updateJob` Update Job returns the content of an updated job. ##### Request CreateCollectionDevOps Pipeline Job application/json Copy ``` { "name": "CreateCollection", "description": "CreateCollection", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "Next": "CreateCollection" }, "CreateCollection": { "Type": "InvokeProduct", "Path": "persistence/transactions/{transaction_id}/collections", "Method": "POST", "PathParameters": { "transaction_id": "$.outputs.CreateTransaction.response_payload.transaction_id" } } } } } ``` application/json Copy ``` { "name": "pipeline", "description": "DevOps Pipeline", "definition": { "StartAt": "Clone", "States": { "Clone": { "Type": "InvokeProduct", "Path": "code/clone", "Method": "POST", "RequestPayload": { "project_name": "$.request_payload.product_name", "branch": "$.request_payload.branch_name", "github_account": "GITHUB_ACCOUNT", "github_token": "GITHUB_TOKEN" }, "Next": "WaitCloneStatus20Secs" }, "WaitCloneStatus20Secs": { "Type": "Wait", "Seconds": 20, "Next": "RetrieveCloneStatus" }, "RetrieveCloneStatus": { "Type": "InvokeProduct", "Path": "code/clone/{bundle_id}", "Method": "GET", "PathParameters": { "bundle_id": "$.outputs.Clone.response_payload.bundle_id" }, "Next": "CheckCloneStatus" }, "CheckCloneStatus": { "Type": "Choice", "Choices": [ { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "SUCCEEDED", "Next": "Assess" }, { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "FAILED", "Next": "FailState" }, { "Variable": "$.outputs.RetrieveCloneStatus.response_payload.clone_status", "StringEquals": "IN_PROGRESS", "Next": "WaitCloneStatus20Secs" } ] }, "Assess": { "Type": "InvokeProduct", "Path": "code-assessor/assessments", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveCloneStatus.response_payload.source_url" }, "Next": "WaitAssessStatus30Secs" }, "WaitAssessStatus30Secs": { "Type": "Wait", "Seconds": 30, "Next": "RetrieveAssessStatus" }, "RetrieveAssessStatus": { "Type": "InvokeProduct", "Path": "code-assessor/assessments/{assessment_id}", "Method": "GET", "PathParameters": { "assessment_id": "$.outputs.Assess.response_payload.assessment_id" }, "Next": "CheckAssessStatus" }, "CheckAssessStatus": { "Type": "Choice", "Choices": [ { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "SUCCEEDED", "Next": "Build" }, { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "FAILED", "Next": "FailState" }, { "Variable": "$.outputs.RetrieveAssessStatus.response_payload.status", "StringEquals": "IN_PROGRESS", "Next": "WaitAssessStatus30Secs" } ] }, "Build": { "Type": "InvokeProduct", "Path": "infra-builder/builds", "Method": "POST", "RequestPayload": { "source_url": "$.outputs.RetrieveAssessStatus.response_payload.source_url" }, "CallbackSettings": { "ExpectedPath": "status", "ExpectedValue": "SUCCEEDED" }, "Next": "Wait10SecGetBuildResults" }, "Wait10SecGetBuildResults": { "Type": "Wait", "Seconds": 10, "Next": "GetBuildResults" }, "GetBuildResults": { "Type": "InvokeProduct", "Path": "infra-builder/builds/{build_id}", "Method": "GET", "PathParameters": { "build_id": "$.outputs.Build.response_payload.bundle_id" }, "Next": "Deploy" }, "Deploy": { "Type": "InvokeProduct", "Path": "infra-deployer/deploy-by-token", "Method": "POST", "RequestPayload": { "artifacts_url": "$.outputs.GetBuildResults.response_payload.artifacts_url", "environment_token": "$.request_payload.environment_token" }, "CallbackSettings": { "ExpectedPath": "status", "ExpectedValue": "SUCCEEDED" }, "Next": "Wait10SecGetDeployResults" }, "Wait10SecGetDeployResults": { "Type": "Wait", "Seconds": 10, "Next": "GetDeployResults" }, "GetDeployResults": { "Type": "InvokeProduct", "Path": "infra-deployer/deploy/{bundle_id}", "Method": "GET", "PathParameters": { "bundle_id": "$.outputs.Deploy.response_payload.bundle_id" }, "End": true }, "FailState": { "Type": "Fail", "Cause": "Failed.", "Error": "Failed" } } } } ``` ##### Response 200400403404500 application/json Copy Update Job ``` { "name": "Job name", "description": "Job Description", "product_name": "Product", "definition": { "StartAt": "CreateTransaction", "States": { "CreateTransaction": { "Type": "InvokeProduct", "Path": "persistence/transactions", "Method": "POST", "RequestPayload": {}, "Retry": { "MaxAttempts": 3, "IntervalSeconds": 5 }, "End": true } } } } ``` application/json Copy Bad Request ``` { "message": "Bad Request!" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job not found" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Job Name | | `description`required | `string` | Job Description | | `product_name` | `string` | Product Name | | `definition`required | `object` | Job Definition | | `StartAt`required | `string` | The first state | | `States`required | `object` | Job States | | `STATE_NAME` | `object` | Name of the State | | `Method` | `string` | Method | | `Path` | `string` | Path | | `PathParameters` | `object` | PathParameters | | `QueryParameters` | `object` | QueryParameters | | `RequestPayload` | `object` | RequestPayload | | `CallbackSettings` | `object` | CallbackSettings | | `WaitForCallback` | `object` | WaitForCallback | | `Projection` | `object` | Projection | | `After` | `object` | After Action | | `Type`required | `string` | State type`Choice``Data``Fail``InvokeProduct``MockData``OutputAggregate``Pass``Succeed``Wait``WaitForAction``WaitForCallback` | | `End` | `boolean` | End of the job definition | | `Next` | `string` | Next State Name | | `ExceptNext` | `string` | Next State if any error occurs | | `Retry` | `object` | Retry Settings | | `TimeoutSeconds` | `integer` | If the task runs longer than the specified seconds, this state fails with a Timeout. Must be a positive, non-zero integer. If not provided, the default value is 3600. | | `IterationSettings` | `object` | If you add IterationSetting to you state, InvokeProduct state will execute the same steps for multiple entries of an array in the state input | ##### Response `200``application/json` 4 fields Update Job | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Job Name | | `description` | `string` | Job Description | | `product_name` | `string` | Name of product | | `definition` | `object` | Job Definition | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `DELETE` `/jobs/{job_name}` #### Delete Job `deleteJob` Delete Job ##### Response 202400403404500 application/json Copy Delete Job ``` { "message": "Job is deleted!" } ``` application/json Copy Bad Request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job did not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | ##### Response `202``application/json` 1 fields Delete Job | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response Message | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Execution Iterations[new] `GET` `/jobs/{job_name}/executions/{execution_id}/iterations/{step_name}` #### Retrieve All `getExecutionIterationsStep` Get all Job Execution step iterations ##### Response 403404500 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | | `step_name` required | `string` path | `InvokeHealth` | Job Step Name | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` `GET` `/jobs/{job_name}/executions/{execution_id}/iterations/{step_name}/status` #### Retrieve Iteration Status `getExecutionIterationsStepLatestStatus` Get Job Execution step iteration status ##### Response 403404500 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | | `step_name` required | `string` path | `InvokeHealth` | Job Step Name | ##### Response `200``application/json` 8 fields Get all Job Execution step iterations | Field | Type | Description | | --- | --- | --- | | `status` | `string` | — | | `startDate` | `string` | — | | `stopDate` | `string` | — | | `maxConcurrency` | `integer` | — | | `toleratedFailurePercentage` | `string` | — | | `toleratedFailureCount` | `integer` | — | | `itemCounts` | `object` | — | | `pending` | `integer` | — | | `running` | `integer` | — | | `succeeded` | `integer` | — | | `failed` | `integer` | — | | `timedOut` | `integer` | — | | `aborted` | `integer` | — | | `total` | `integer` | — | | `resultsWritten` | `integer` | — | | `executionCounts` | `object` | — | | `pending` | `integer` | — | | `running` | `integer` | — | | `succeeded` | `integer` | — | | `failed` | `integer` | — | | `timedOut` | `integer` | — | | `aborted` | `integer` | — | | `total` | `integer` | — | | `resultsWritten` | `integer` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/jobs/{job_name}/executions/{execution_id}/iterations/{step_name}/results` #### Retrieve Iteration Results `getExecutionIterationsStepLatestResults` Get Job Execution step iteration results ##### Response 403404500 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | | `step_name` required | `string` path | `InvokeHealth` | Job Step Name | | `iteration` | `string` query | `iterationID` | Iteration ID. If not set, latest will be used | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` ### Execution References[new] `GET` `/jobs/{job_name}/executions/{execution_id}/references` #### Retrieve All `getExecutionReferences` Get Execution References ##### Response 403404500 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` ### Execution `POST` `/jobs/{job_name}/executions/{execution_id}/resume` #### Resume Execution `resumeExecution` ##### Request application/json Copy ``` { "foo": "bar" } ``` ##### Response 403404500 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Execution not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` `POST` `/jobs/{job_name}/executions/{execution_id}/stop` #### Stop Execution `stopExecution` ##### Request application/json Copy ``` { "foo": "bar" } ``` ##### Response 403404500 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Execution not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` ### Addendum Signed Document `POST` `/jobs/AddendumSignedDocument/executions` #### Run Addendum Signed Document `runAddendumSignedDocument` Set Addendum Signed Document Set Addendum Signed Document Run after dddendum is signed. Request example: ``` { "request_payload": { "loan_id": "87376716-9351-4abb-93d6-ddd08364f897", "blob_id": "01GGZQN05WG6GJX2HVQJHRNQER", "transaction_id": "01GG54QMC4GCQBQ5YY91VVDCVP" } } ``` ##### Request application/json Copy ``` { "request_payload": { "loan_id": "87376716-9351-4abb-93d6-ddd08364f897", "blob_id": "01GGZQN05WG6GJX2HVQJHRNQER", "transaction_id": "01GG54QMC4GCQBQ5YY91VVDCVP" } } ``` ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `request_payload`required | `object` | Addendum Payload | | `loan_id` | `string` | loan_id | | `blob_id` | `string` | blob_id | | `transaction_id` | `string` | transaction_id | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `message` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | Nothing matches the given URI | `GET` `/jobs/AddendumSignedDocument/executions/{job_id}` #### Get Addendum Signed Document `getAddendumSignedDocument` Get Addendum Signed Document Get Execution Status for addendum job. ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Execution ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `message` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | Nothing matches the given URI | ### PreOfferValuation `POST` `/jobs/PreOfferValuation/executions` #### Run PreOfferValuation `runPreOfferValuation` Run PreOfferValuation Run PreOfferValuation Request example: ``` { "request_payload": { "form_data": { "buyer_name": "Buyer Name", "buyer_2_name": "Co Buyer Name", "agent_name": "Agent-Name", "agent_email": "agent@staircase.co", "brokerage_name": "remax", "brokerage_phone": "34342342", "loan_officer_email": "lo@staircase.co", "loan_officer_name": "LO", "property_street_address": "209 N Highway 45", "property_city": "Bonanza", "property_state": "AR", "property_zip_coShow the restde": "72916", "down_payment_amount": 45000, "down_payment_percent": 5, "offer_amount": 120000, "loan_id": "87376716-9351-4abb-93d6-ddd08364f897", "preapproval_loan_amount": 114000, "loan_officer_phone": "", "lender_organization_name": "envoymortgage" }, "transaction_id": "01GG54QMC4GCQBQ5YY91VVDCVP", } } ``` ##### Request application/json Copy ``` { "request_payload": { "form_data": { "buyer_name": "Buyer Name", "buyer_2_name": "Co Buyer Name", "agent_name": "Agent-Name", "agent_email": "agent@staircase.co", "brokerage_name": "remax", "brokerage_phone": "34342342", "loan_officer_email": "lo@staircase.co", "loan_officer_name": "LO", "property_street_address": "209 N Highway 45", "property_city": "Bonanza", "property_state": "AR", "property_zip_code": "72916", "down_payment_amount": 45000, "down_payment_percent": 5, "offer_amount": 120000, "loan_id": "87376716-9351-4abb-93d6-ddd08364f897", "preapproval_loan_amount": 114000, "loan_officer_phone": "", "lender_organization_name": "envoymortgage" }, "blob_id": "01GGZQN05WG6GJX2HVQJHRNQER", "transaction_id": "01GG54QMC4GCQBQ5YY91VVDCVP" } } ``` ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `request_payload`required | `object` | PreOfferValuation Payload | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `GET` `/jobs/PreOfferValuation/executions/{job_id}` #### Get PreOfferValuation `getPreOfferValuation` Get PreOfferValuation Get PreOfferValuation ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Execution ID | ##### Response `200``application/json` 1 fields Return Job Status | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | ### CheckEligibility `POST` `/jobs/CheckEligibilityStatus/executions` #### Run CheckEligibility `runCheckEligibility` Run CheckEligibility Run CheckEligibility Request example: ``` { "request_payload": { "metadata": { "version": 2, "validation": true }, "data": { "loan_identifiers": [ { "@type": "loan_identifier", "@id": "01GEB6TJ17H9V8F0VZCP80242X", "has_loan_identifier_value": { "has_value": "87376716-9351-4abb-93d6-ddd08364f897" } } ] } } } ``` ##### Request application/json Copy ``` { "request_payload": {} } ``` ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `request_payload`required | `object` | PreOfferValuation Payload | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `POST` `/jobs/CheckEligibilityStatus/executions/{job_id}` #### Get CheckEligibility `getCheckEligibility` Get CheckEligibility Get CheckEligibility ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Execution ID | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | ### LeadoffExecuteContract `POST` `/jobs/LeadOffExecuteContract/executions` #### Run LeadoffExecuteContract `runLeadoffExecuteContract` Run LeadoffExecuteContract Run LeadoffExecuteContract Request example: ``` { "request_payload": { "loan_id": "87376716-9351-4abb-93d6-ddd08364f897", "blob_id": "01GGWA56R823XGMMCSQ1SMF9YK", "transaction_id": "01GGQ79GFCBVT0RFDC5YRD5FW4" } } ``` ##### Request application/json Copy ``` { "request_payload": { "loan_id": "87376716-9351-4abb-93d6-ddd08364f897", "blob_id": "01GGZQN05WG6GJX2HVQJHRNQER", "transaction_id": "01GG54QMC4GCQBQ5YY91VVDCVP" } } ``` ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `request_payload`required | `object` | PreOfferValuation Payload | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | `GET` `/jobs/LeadOffExecuteContract/executions/{job_id}` #### Get LeadoffExecuteContract `getLeadoffExecuteContract` Get LeadoffExecuteContract Get LeadoffExecuteContract ##### Response application/json Copy Bad request ``` { "message": { "schema_type": [ "Must be one of: create, update." ] } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | Execution ID | ##### Response `200``application/json` 1 fields Return Job ID | Field | Type | Description | | --- | --- | --- | | `job_id` | `string` | message | ##### Response `400``application/json` 1 fields Bad request | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message or object with additional properties. | ##### Response `403``application/json` 2 fields Forbidden | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Request forbidden -- authorization will not help | | `url` | `string (url)` | Indicates at which url the error occurs | ##### Response `404``application/json` 1 fields Partner not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Nothing matches the given URI | ### Executions `POST` `/jobs/{job_name}/executions` #### Execute Job `executeJob` Execute Job operation will create and run new Execution of a Job. To create a new Execution, you need to provide the below information: - Request Payload - Transaction ID. Will be used both for Job product to report operation to Health and as part of Request Payload. (Optional) - Callback URL (Optional) #### Runtime Variables `$.transaction_id` is always going to be available for any step in a flow. If Transaction ID was not provided in the Request Body, Job product will generate new Transaction ID. `$.job_name` represents Job Name. Can be used to Retrieve List of Executions. `$.execution_id` represents Job Executions ID. Can be used to Retrieve Execution Detail. `$.start_time` represents the Job start time. Can be used for logging or as a parameter invoking other Staircase products. For example, can be used for Console product Put Data saving default values. `$.api_key` have current environment `API_KEY` of the Job runtime. `$.host` have current environment `HOSTNAME` of the Job runtime. Show the rest Example of using runtime variables ``` { "definition": { "StartAt": "A", "States": { "A": { "Data": { "execution_id": "$.execution_id", "start_time": "$.start_time", "transaction_id": "$.transaction_id" }, "End": true, "Type": "Data" } } }, "name": "test" } ``` ##### Request application/json Copy ``` { "request_payload": { "key": "value" }, "transaction_id": "uuid", "callback_url": "https://webhook.site/6e36e3f0-f95a-4dec-b306-a97843095267" } ``` ##### Response 202400403404500 application/json Copy Create Job Execution Successfully ``` { "execution_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB" } ``` application/json Copy Bad Request ``` { "message": "request_payload is a required property" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` required | `string` path | `ExampleJobName` | Job Name | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `request_payload`required | `object` | Request Payload | | `transaction_id` | `string` | Transaction ID in Staircase. | | `callback_url` | `string` | Callback URL used by Job product when execution completes | ##### Response `202``application/json` 2 fields Create Job Execution Successfully | Field | Type | Description | | --- | --- | --- | | `execution_id` | `string (ulid)` | Job Execution IDExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `job_name` | `string` | Job Name | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/jobs/{job_name}/executions` #### Retrieve All Executions `listExecutions` Retrieve All Executions - `next_token` - `transaction_id` - Filter executions by Transaction ID - `sort` - Sort order `asc` or `desc` - `limit` - Limit number of executions in the response - `status` - Filter by Execution status `ABORTED`, `FAILED`, `RUNNING`, `SUCCEEDED`, `TIMED_OUT` - `start_date` - Filter by start date. Can be expression like `gt+2023-01-01T04:22:48.340000-04:00` or `gt+2023-01-01` or similar - `stop_date` - Filter by stop date ##### Response 200400403404500 application/json Copy Retrieve All Executions ``` { "results": [ { "name": "Job name 1", "status": "SUCCEEDED", "start_time": "2021-08-11T17:06:47.000Z", "stop_time": "2021-08-11T17:07:40.000Z" }, { "name": "Job name 2", "status": "FAILED", "start_time": "2021-08-11T15:54:47.000Z", "stop_time": "2021-08-11T15:54:59.000Z" } ], "next_token": "string" } ``` application/json Copy Bad Request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 8 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `NextToken` | If next_token is returned, there are more results available. The value of next_token is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error. | | `transaction_id` | `string` query | `FJSARJREJQ12` | You can filter executions by transaction_id | | `sort` | `string` query | `asc` | Sorting | | `limit` | `integer` query | `5` | Limit results | | `status` | `string` query | `RUNNING` | You can use this to filter jobs by status | | `start_date` | `string` query | `gt+2022-08-24T01:00:00.000000-04:00` | Filter by job Start Date | | `stop_date` | `string` query | `lt+2022-08-24T01:00:00.000000-04:00` | Filter by job Stop Date | | `job_name` required | `string` path | `ExampleJobName` | Job Name | ##### Response `200``application/json` 2 fields Retrieve All Executions | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination Token | | `results` | `object[]` | Array of executions | | `name` | `string` | Execution Name | | `status` | `string` | Execution status`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` | | `start_date` | `string` | ISO 8601 format with UTC | | `stop_date` | `string` | ISO 8601 format with UTC | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/jobs/{job_name}/executions/{execution_id}` #### Retrieve Execution Detail `getExecution` ##### Response 200 Get Job Execution Detail Succeeded200 Execution Details with Detailed=True200 Get Job Execution Detail Failed400403404500 application/json Copy Retrieve Execution Detail ``` { "status": "SUCCEEDED", "start_time": "2021-08-11T17:06:47.000Z", "stop_time": "2021-08-11T17:07:40.000Z", "health_logs_url": "https://documentation.staircaseapi.com/code-health-checker/metric/01FDCEJT790J22PY13MCP0B90K" } ``` application/json Copy Retrieve Execution Detail ``` { "start_date": "2021-12-21 13:19:53", "stop_date": "2021-12-21 13:19:58", "current_step": "CreateCollection", "status": "SUCCEEDED", "health_logs_url": "https://documentation.staircaseapi.com/code-health-checker/metric/01FQEJBYERMWGJEQDBFMG1X2D0", "execution_output": { "status": "COMPLETED", "response_payload": { "data": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "metadata": { "validation": false, "created_at": "2021-12-21T08:19:56.364778-05:00" }, "collection_id": "01FQEJC1EC11NTSE76WJJ574P5", "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827" }, "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] } }, "execution_data": [ { "event_id": 16, "event_type": "stateExitedEventDetails", "event_name": "CompleteState", "timestamp": "2021-12-21 13:19:58.335000+00:00", "previous_event_id": 15, "output": { "status": "COMPLETED", "response_payload": { "data": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "metadata": { "validation": false, "created_at": "2021-12-21T08:19:56.364778-05:00" }, "collection_id": "01FQEJC1EC11NTSE76WJJ574P5", "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827" }, "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] } } }, { "event_id": 12, "event_type": "stateEnteredEventDetails", "event_name": "CompleteState", "timestamp": "2021-12-21 13:19:56.484000+00:00", "previous_event_id": 11, "input": { "hit_count_map": { "CreateTransaction": 1, "CreateCollection": 1 }, "outputs": { "CreateTransaction": { "status_code": 201, "response_payload": { "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827", "_links": { "collections": "https://documentation.staircaseapi.com/persistence/transactions/01FQEJBYQN1RWAGWCTR8R2M827/collections" } } }, "response_payload": { "data": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "metadata": { "validation": false, "created_at": "2021-12-21T08:19:56.364778-05:00" }, "collection_id": "01FQEJC1EC11NTSE76WJJ574P5", "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827" }, "CreateCollection": { "status_code": 201, "response_payload": { "data": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "metadata": { "validation": false, "created_at": "2021-12-21T08:19:56.364778-05:00" }, "collection_id": "01FQEJC1EC11NTSE76WJJ574P5", "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827" } } }, "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "callback_url": "https://calball_url_site" } }, { "event_id": 11, "event_type": "stateExitedEventDetails", "event_name": "CreateCollection", "timestamp": "2021-12-21 13:19:56.475000+00:00", "previous_event_id": 10, "output": { "hit_count_map": { "CreateTransaction": 1, "CreateCollection": 1 }, "outputs": { "CreateTransaction": { "status_code": 201, "response_payload": { "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827", "_links": { "collections": "https://documentation.staircaseapi.com/persistence/transactions/01FQEJBYQN1RWAGWCTR8R2M827/collections" } } }, "response_payload": { "data": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "metadata": { "validation": false, "created_at": "2021-12-21T08:19:56.364778-05:00" }, "collection_id": "01FQEJC1EC11NTSE76WJJ574P5", "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827" }, "CreateCollection": { "status_code": 201, "response_payload": { "data": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "metadata": { "validation": false, "created_at": "2021-12-21T08:19:56.364778-05:00" }, "collection_id": "01FQEJC1EC11NTSE76WJJ574P5", "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827" } } }, "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "callback_url": "https://calball_url_site" } }, { "event_id": 7, "event_type": "stateEnteredEventDetails", "event_name": "CreateCollection", "timestamp": "2021-12-21 13:19:53.783000+00:00", "previous_event_id": 6, "input": { "hit_count_map": { "CreateTransaction": 1 }, "outputs": { "CreateTransaction": { "status_code": 201, "response_payload": { "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827", "_links": { "collections": "https://documentation.staircaseapi.com/persistence/transactions/01FQEJBYQN1RWAGWCTR8R2M827/collections" } } }, "response_payload": { "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827", "_links": { "collections": "https://documentation.staircaseapi.com/persistence/transactions/01FQEJBYQN1RWAGWCTR8R2M827/collections" } } }, "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "callback_url": "https://calball_url_site" } }, { "event_id": 6, "event_type": "stateExitedEventDetails", "event_name": "CreateTransaction", "timestamp": "2021-12-21 13:19:53.775000+00:00", "previous_event_id": 5, "output": { "hit_count_map": { "CreateTransaction": 1 }, "outputs": { "CreateTransaction": { "status_code": 201, "response_payload": { "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827", "_links": { "collections": "https://documentation.staircaseapi.com/persistence/transactions/01FQEJBYQN1RWAGWCTR8R2M827/collections" } } }, "response_payload": { "transaction_id": "01FQEJBYQN1RWAGWCTR8R2M827", "_links": { "collections": "https://documentation.staircaseapi.com/persistence/transactions/01FQEJBYQN1RWAGWCTR8R2M827/collections" } } }, "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "callback_url": "https://calball_url_site" } }, { "event_id": 2, "event_type": "stateEnteredEventDetails", "event_name": "CreateTransaction", "timestamp": "2021-12-21 13:19:53.420000+00:00", "previous_event_id": 0, "input": { "request_payload": { "loans": [ { "@id": "01FQ02RXN84KR9V9DR5VW1CGE5", "@type": "loan", "has_borrower_requested_loan_amount": { "has_value": 12345 } } ] }, "callback_url": "https://calball_url_site", "trigger_name": "" } } ] } ``` application/json Copy Retrieve Execution Detail ``` { "status": "FAILED", "start_time": "2021-08-11T15:54:47.000Z", "stop_time": "2021-08-11T15:54:59.000Z", "health_logs_url": "https://documentation.staircaseapi.com/code-health-checker/metric/01FDCEJT790J22PY13MCP0B90K" } ``` application/json Copy Bad Request ``` { "message": "Bad Request" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `NextToken` | If next_token is returned, there are more results available. The value of next_token is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error. | | `detailed` | `string` query | `false` | You can select whether execution data (input or output of a history event) is returned. The default is false | | `job_name` required | `string` path | `ExampleJobName` | Job Name | | `execution_id` required | `string` path | `01FEK7TACV6XP1CMBX44MJE4G3` | Execution ID | ##### Response `200``application/json` 7 fields Retrieve Execution Detail | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Job Execution Status`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT``WAIT_FOR_ACTION` | | `start_time` | `string` | ISO 8601 format with UTC | | `stop_time` | `string` | ISO 8601 format with UTC | | `health_logs_url` | `string` | Health URL for execution | | `execution_output` | `object` | Contains status, response_payload, request_payload. | | `execution_data` | `—` | Description | | `next_token` | `string` | If next_token is returned, there are more results available. | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Triggers `POST` `/triggers` #### Create Trigger `createTrigger` You can create rules that self-trigger on an automated schedule in Job Product using CRON or rate expressions. All scheduled events use UTC time zone. With using create trigger endpoint, you can create a custom triggers for you job executions #### Trigger: You can define your trigger type for job #### Trigger Types ##### SCHEDULE You can schedule event for you jobs ``` { "type": "SCHEDULE", "schedule_expression": "rate(5 minutes)" } ``` ###### Schedule Expression: - Cron Expressions - Rate Expressions ##### EVENT You can trigger the jobs from the messages arrived to jobs webhooks. Show the rest You can filter the messages and invoke your jobs according to your business needs ``` { "type": "EVENT", "filter_expression": { "source_name": ["LOS_NAME"], "event_type": ["LOAN_CREATED","LOAN_MODIFIED"] } } ``` ###### Filter Expression: You can only add filter expressions for the string elements in the message or the partner name - ###### Exact Matching Exact matching occurs when a filter expression value matches one or more message values. Consider the following policy attribute: ``` "football_team": ["liverpool", "chelsea"] ``` It matches the following message: ``` { "football_team": "liverpool", "players": [ "Salah", "Mane", "Firmino" ] } ``` However, it doesn't match the following message: ``` { "football_team": "man_united", "players": [ "Cavani", "Rashford", "Ronaldo" ] } ``` - ###### Prefix matching When a filter expression includes the keyword prefix, it matches any message value that begins with the specified characters. Consider the following policy attribute: ``` "sport": [{"prefix": "bas"}] ``` It matches either of the following messages: ``` { "sport": "baseball" } ``` ``` { "sport": "basketball" } ``` However, it doesn't match the following message: ``` { "sport": "rugby" } ``` - ###### Anything-but matching When a filter expression includes the keyword anything-but, it matches any message that doesn't include any of the filter expression values. Consider the following policy attribute: ``` "sport": [{"anything-but": ["rugby", "tennis"]}] ``` It matches either of the following message attributes: ``` { "sport": "baseball" } ``` ``` { "sport": "football" } ``` However, it doesn't match the following message: ``` { "sport": "rugby" } ``` ##### Request CreteTriggerWithCronCreteTriggerWithRateCreateTriggerWithEventExample1CreateTriggerWithEventExample2CreateTriggerWithEventExample3 application/json Copy ``` { "name": "trigger-1", "description": "Cron Trigger", "type": "SCHEDULE", "schedule_expression": "cron(0 * * * ? *)", "actions": { "target_jobs": [ { "name": "job-1", "request_payload": { "foo": null } } ] } } ``` application/json Copy ``` { "name": "trigger-2", "description": "Create Transaction every 5 minutes", "type": "SCHEDULE", "schedule_expression": "rate(5 minutes)", "actions": { "target_jobs": [ { "name": "job-1" } ] } } ``` application/json Copy ``` { "name": "trigger-3", "description": "Event Based Trigger", "type": "EVENT", "filter_expression": { "source_name": [ "los_name" ], "event_type": [ "LOAN_MODIFIED", "NEW_DOCUMENT_ADDED" ] }, "actions": { "target_jobs": [ { "name": "job-1" }, { "name": "job-2" } ] } } ``` application/json Copy ``` { "name": "trigger-4", "description": "Event Based Trigger", "type": "EVENT", "filter_expression": { "source_name": [ "staircase" ], "event_type": [ "CONNECTOR_RETURNED_RESPONSE" ] }, "actions": { "target_jobs": [ { "name": "call_translator_job" } ] } } ``` application/json Copy ``` { "name": "trigger-5", "description": "Event Based Trigger", "type": "EVENT", "filter_expression": { "source_name": [ "staircase" ], "event_type": [ "MARKETPLACE_UPDATED" ], "product_name": [ "Code", "Build", "Assess", "Deploy" ] }, "actions": { "target_jobs": [ { "name": "update_environment_job" } ] } } ``` ##### Response 201400 Already Exist400 Invalid Definition403404500503 Service Unavailable503 Exceeds The Limit application/json Copy Create Trigger API Response ``` { "message": "Triggers are created!" } ``` application/json Copy Bad Request ``` { "message": "A trigger/job pair with this name already exists" } ``` application/json Copy Bad Request ``` { "message": "Indicates that a request parameter does not comply with the associated constraints. Check your filter expression" } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job {job_name} not found!" } } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` application/json Copy Service Unavailable ``` { "message": "You must wait 60 seconds after deleting a trigger before you can create another with the same name." } ``` application/json Copy Service Unavailable ``` { "message": "Indicates that the number of filter polices in your account exceeds the limit." } ``` ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `name` | `string` | Name of a trigger | | `description` | `string` | Description of a trigger | | `type` | `string` | The trigger type`EVENT``SCHEDULE` | | `schedule_expression` | `string` | Schedule ExpressionExample `rate(5 minutes), cron(0 * * * ? *)` | | `filter_expression` | `object` | Filter Expression | | `key` | `string` | Parameter from event request payload | | `value` | `string[]` | Filter values for the key | | `actions` | `object` | Actions | | `target_jobs` | `object[]` | Job Names | | `name` | `string` | Name of job | | `request_payload` | `object` | Request Payload | | `callback_url` | `string` | Callback URL | ##### Response `201``application/json` 1 fields Create Trigger API Response | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response MessageExample `Triggers are created!` | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `503``application/json` 1 fields Service Unavailable | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/triggers` #### Retrieve Triggers `getTrigger` Retrieve Trigger Retrieves Triggers. Possible to filter by trigger name or job name ##### Response 200400403500 application/json Copy Retrieve Triggers ``` { "triggers": [ { "trigger_name": "", "job_name": "", "description": "", "type": "SCHEDULE", "schedule_expression": "rate(2 minutes)" } ] } ``` application/json Copy Bad Request ``` { "message": "job_name or trigger_name should be on the query parameters" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `job_name` | `string` query | `jobName` | Job name | | `trigger_name` | `string` query | `triggerNmae` | Trigger name | ##### Response `200``application/json` 1 fields Retrieve Triggers | Field | Type | Description | | --- | --- | --- | | `triggers` | `array` | Found triggers | ##### Response `400``application/json` 1 fields Bad Request | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `DELETE` `/triggers/{trigger_name}` #### Delete Trigger `deleteTrigger` ##### Response 202400403500 application/json Copy Retrieve Triggers ``` { "message": "Trigger is deleted" } ``` application/json Copy Bad Request! ``` { "message": "Bad Request!" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `trigger_name` required | `string` path | `trigger_name` | Trigger Name | ##### Response `202``application/json` 1 fields Retrieve Triggers | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response MessageExample `Trigger is deleted` | ##### Response `400``application/json` 1 fields Bad Request! | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response messageExample `Bad Request!` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Webhooks `POST` `/webhooks/{source_name}` #### Send Event `sendEvent` This endpoint allows you to send events to trigger event-based jobs. ##### Request LOSEventExampleCustomEventExample1CustomEventExample2CustomEventExample3 application/json Copy ``` { "los_name": "LOS NAME", "event_type": "LOAN_CREATED", "loan_id": "LOAN ID" } ``` application/json Copy ``` { "event_type": "TOKEN_EXPIRED" } ``` application/json Copy ``` { "event_type": "MARKETPLACE_UPDATED" } ``` application/json Copy ``` { "event_type": "NEW_ENVIRONMENT_CREATED", "domain": "DOMAIN_NAME" } ``` ##### Response 202400403404500 application/json Copy Event is accepted! ``` { "message": "Event is accepted!" } ``` application/json Copy Bad Request! ``` { "message": "Invalid Parameter!" } ``` 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" } ``` application/json Copy Not Found! ``` { "message": "Not Found!" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `source_name` required | `string` path | `partnerName` | Source name of the event | ##### Response `202``application/json` 1 fields Event is accepted! | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response messageExample `Event is accepted!` | ##### Response `400``application/json` 1 fields Bad Request! | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Response messageExample `Invalid Parameter!` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found! | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Not Found!Example `Not Found!` | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Operations `DELETE` `/jobs/{name}` #### Delete job `deleteJob` Delete an existing job and delete all job execution data ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `name` required | `string` path | Job name | ##### Other responses `200` `GET` `/jobs/{name}` #### Get job `getJob` Returns specific job details ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `name` required | `string` path | Job name | ##### Response `200``application/json` 5 fields Job | Field | Type | Description | | --- | --- | --- | | `name`required | `string` | Job name | | `description`required | `string` | Textual description of the job entry | | `definition` | `array` | Job Workflow Steps | | `cron`required | `string` | Cron expressions have six required fields, which are separated by white space. | | `status`required | `string` | Status`CREATING``DESTROYING``DISABLED``ENABLED``PENDING` | `PUT` `/jobs/{name}` #### Update job `updateJob` Update an existing job parameters ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `name` required | `string` path | Job name | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `description`required | `string` | Textual description of the job entry | | `definition` | `array` | Job Workflow Steps | | `cron`required | `string` | Cron expressions have six required fields, which are separated by white space. | ##### Other responses `200` `POST` `/jobs/disable/{job_name}` #### Disable job `disableJob` Disable a job to stop upcoming cron executions ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `job_name` required | `string` path | Job name | ##### Other responses `200` `POST` `/jobs/enable/{job_name}` #### Enable job `enableJob` Enable a job to allow cron executions ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `job_name` required | `string` path | Job name | ##### Other responses `200` `POST` `/jobs/execute/{job_name}` #### Execute job on demand `executeJob` Execute a job manually ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `job_name` required | `string` path | Job name | ##### Other responses `200` `GET` `/jobs/execution/{job_execution_id}` #### Get job execution `getJobExecution` Returns a Job Execution Details ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `job_execution_id` required | `string` path | Job Execution Id | ##### Response `200``application/json` 6 fields Job Execution Details | Field | Type | Description | | --- | --- | --- | | `job_execution_id` | `string` | Job execution UID | | `job_name`required | `string` | Job name | | `executed` | `string (date-time)` | Date-time of execution | | `finished` | `string (date-time)` | Date-time of completion | | `status` | `string` | Job execution status`ERROR``PENDING``RUNNING``SUCCESS` | | `flow_step_data` | `string` | Workflow data store | `GET` `/jobs/executions/{job_name}` #### Get job executions `getJobExecutions` Returns a list of job executions for specific job ##### Parameters 3 | Parameter | Type | Description | | --- | --- | --- | | `job_name` required | `string` path | Job name | | `page` | `number` query | Start from page | | `limit` | `number` query | Page limit | ##### Response `200``application/json` 2 fields Paginated list of Job executions | Field | Type | Description | | --- | --- | --- | | `data` | `array` | List of Job Executions | | `totalCount`required | `number` | Total number of Job Executions | ## Errors `400``403``404``500``503` ## More in Integration - Previous product: Connection - Next product: Product --- # Product # Product The registry that defines other products: their APIs, their flows, and the uniform endpoint surface every vertical inherits. A product is created, deployed and documented through this registry. It holds the API definitions, the flow bindings, and the generated interface description each product publishes. The uniform surface every mortgage vertical carries — request and response schema, the vendor ordering, invocation history, partner list, report templates — is defined once here rather than re-implemented per vertical. ## How it works Two products from different categories expose the same shape, so a caller that has integrated one has most of the work done for the next. The registry that creates an API is the registry that can list them, so the catalogue is readable as data rather than only as a document. ## Operations ### APIs `POST` `/apis` #### Create API `create_api` Creates API with provided product ID and base path. Next steps are: create resources, create method, deploy the API ##### Request application/json Copy ``` { "product_identifier": "ed011136-4199-4efe-8ba1-71b6eb302744", "base_path": "product-product", "product_category": "Integration", "product_family": "Platform", "product_name": "Product" } ``` ##### Response 201400 application/json Copy OK Response ``` { "api_id": "3f6eb765-459d-4a84-a985-620628e7a2cf", "product_identifier": "ed011136-4199-4efe-8ba1-71b6eb302744", "base_path": "credit" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `product_identifier` | `string (uuid)` | Product ID. | | `base_path` | `string` | Base path | | `product_category` | `string` | Product category from Staircase Ontology | | `product_family` | `string` | Product family from Staircase Ontology | | `product_name` | `string` | Product name from Staircase ontology | ##### Response `201``application/json` 3 fields OK Response | Field | Type | Description | | --- | --- | --- | | `api_id` | `string (uuid)` | API ID | | `product_identifier` | `string (uuid)` | Product ID | | `base_path` | `string` | Base path | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `409``application/json` 1 fields Resource already exists. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `422``application/json` 1 fields Resource already exists. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | `POST` `/apis/{product_identifier}/endpoints` #### Create Endpoint `create_endpoint` Create endpoint. Create endpoint for API, that was created with specified product identifier. Endpoint contains two parts: it's public definition, that will be available and will be presented in OpenAPI file and integration with any Staircase API. When your endpoint will be invoked request parameters and body will be mapped according to your definition and request will be sent to specified Staircase API, same will happen with the response. To create valid integration you need to specify HTTP method that will be used for request in `integration.http_method`, url without domain name, f.e. `/persistence/transactions` in `integration.url`, request schema, if needed, in `request_schema` in JSON Schema format. Incoming requests will be validated against that schema and in case of invalid request your customer will receive response with status code 400 and error message in body. To map request parameters you need to fill `integration.request_parameters` parameter with an object, where keys are location where to put them for request to Staircase service in format `{location}.{name}` where location is querystring , path , or header and name is a valid and unique parameter name and values are static value or, if you want to map them from the request, value should match patter request.{location}.{name} where location is querystring , path , or header and name must be a valid and unique method request parameter name. To map request body you need to specify `integration.request_template` in format of VTL template. VTL is simple template language, you can find information about all possibilities here. Basic examples can be found in request examples for this endpoint. Inside template, you will be to access two variables: `$input` and `$util`. The `$input` variable represents the method request payload and parameters to be processed by a mapping template. It provides four functions: Show the rest | Variable and function | Description | | --- | --- | | $input.body | Returns the raw request payload as a string. | | $input.json(x) | This function evaluates a JSONPath expression and returns the results as a JSON string. For example, $input.json('$.pets') returns a JSON string representing the pets structure. For more information about JSONPath, see JSONPath | | $input.params | Returns a map of all the request parameters. We recommend that you use $util.escapeJavaScript to sanitize the result to avoid a potential injection attack. For full control of request sanitization, use a proxy integration without a template and handle request sanitization in your integration. | | $input.params(x) | Returns the value of a method request parameter from the path, query string, or header value (searched in that order), given a parameter name string x. We recommend that you use $util.escapeJavaScript to sanitize the parameter to avoid a potential injection attack. For full control of parameter sanitization, use a proxy integration without a template and handle request sanitization in your integration. | | $input.path(x) | Takes a JSONPath expression string (x) and returns a JSON object representation of the result. This allows you to access and manipulate elements of the payload natively in Apache Velocity Template Language (VTL). | #### `$input` Variable template examples ##### Parameter mapping template example The following parameter-mapping example passes all parameters, including path, querystring, and header, through to the integration endpoint via a JSON payload: ``` #set($allParams = $input.params) { "params" : { #foreach($type in $allParams.keySet) #set($params = $allParams.get($type)) "$type" : { #foreach($paramName in $params.keySet) "$paramName" : "$util.escapeJavaScript($params.get($paramName))" #if($foreach.hasNext),#end #end } #if($foreach.hasNext),#end #end } } ``` In effect, this mapping template outputs all the request parameters in the payload as outlined as follows: ``` { "params" : { "path" : { "path_name" : "path_value", ... } "header" : { "header_name" : "header_value", ... } "querystring" : { "querystring_name" : "querystring_value", ... } } } ``` ##### Example JSON mapping template using `$input` The following example shows how to use a mapping to read a name from the query string and then include the entire POST body in an element: ``` { "name" : "$input.params('name')", "body" : $input.json('$') } ``` If the JSON input contains unescaped characters that cannot be parsed by JavaScript, a 400 response may be returned. Applying $util.escapeJavaScript($input.json('$')) above will ensure that the JSON input can be parsed properly. ##### Example mapping template using `$input` The following example shows how to pass a JSONPath expression to the json method. You could also read a specific property of your request body object by using a period (.), followed by your property name: ``` { "name" : "$input.params('name')", "body" : $input.json('$.mykey') } ``` If a method request payload contains unescaped characters that cannot be parsed by JavaScript, you may get 400 response. In this case, you need to call $util.escapeJavaScript function in the mapping template, as shown as follows: ``` { "name" : "$input.params('name')", "body" : $util.escapeJavaScript($input.json('$.mykey')) } ``` ##### Example request and response using `$input` Request template ``` Resource: /things/{id} With input template: { "id" : "$input.params('id')", "count" : "$input.path('$.things').size", "things" : $util.escapeJavaScript($input.json('$.things')) } POST /things/abc { "things" : { "1" : {}, "2" : {}, "3" : {} } } ``` Response: ``` { "id": "abc", "count": "3", "things": { "1": {}, "2": {}, "3": {} } } ``` #### $util Variables | Function | Description | | --- | --- | | $util.escapeJavaScript | Escapes the characters in a string using JavaScript string rules. Note: This function will turn any regular single quotes (') into escaped ones ('). However, the escaped single quotes are not valid in JSON. Thus, when the output from this function is used in a JSON property, you must turn any escaped single quotes (') back to regular single quotes ('). This is shown in the following example: ` $util.escapeJavaScript(data).replaceAll("\\'","'")` | | $util.parseJson | Takes "stringified" JSON and returns an object representation of the result. You can use the result from this function to access and manipulate elements of the payload natively in Apache Velocity Template Language (VTL). For example, if you have the following payload: `{"errorMessage":"{\"key1\":\"var1\",\"key2\":{\"arr\":[1,2,3]}}"}` and use the following mapping template `#set ($errorMessageObj = $util.parseJson($input.path('$.errorMessage'))) { "errorMessageObjKey2ArrVal" : $errorMessageObj.key2.arr[0] }` You will get the following output: `{"errorMessageObjKey2ArrVal": 1}` | | $util.urlEncode | Converts a string into "application/x-www-form-urlencoded" format. | | $util.urlDecode | Decodes an "application/x-www-form-urlencoded" string. | | $util.base64Encode | $util.base64Encode | | $util.base64Decode | Decodes the data from a base64-encoded string. | ##### Request POST request with request bodyGET request with path parameters mapping application/json Copy POST request with request body ``` { "path": "/loans", "http_method": "POST", "product_api_identifiers": [ "5b3b5eb4-f32f-487f-9969-2a9b0ddef89e", "e37b044f-b992-4c23-b588-1c34dbb3008b" ], "product_component": "Loans", "product_endpoint": "Create loan", "product_sequence": 1, "operation_id": "create_loan", "description": "Create Loan", "example": { "loan_label": "foo" }, "request_schema": { "type": "object", "properties": { "loan_label": { "type": "string" } }, "required": [ "loan_label" ], "additionalProperties": false }, "integration": { "http_method": "POST", "url": "/persistence/transactions", "request_template": "{\"label\": \"$input.path('$.loan_label')\"}", "responses": { "201": { "documentation": { "description": "Loan created.", "example": { "loan_label": "foo", "loan_id": "01GKF9A4QZ79RSCMJ041HEZSMK" } }, "schema": { "type": "object", "properties": { "loan_label": { "type": "string" }, "loan_id": { "type": "string" } } }, "response_template": "#set($inputRoot = $input.path('$'))\n{\n \"loan_label\": \"$inputRoot.label\",\n \"loan_id\": \"$inputRoot.transaction_id\"\n}\n" } } } } ``` application/json Copy GET request with path parameters mapping ``` { "path": "/loans/{loan_id}", "http_method": "GET", "product_api_identifiers": [ "fec297a3-973d-4b68-be48-d7a4aedcb07f" ], "product_component": "Loans", "product_endpoint": "Retrieve Loan", "product_sequence": 2, "operation_id": "retrieve_loan", "parameters": [ { "in": "path", "name": "loan_id", "required": true, "schema": { "type": "string" }, "example": "01GKKGSG9NHCTP1XM8W4W833QD" } ], "integration": { "http_method": "GET", "url": "/persistence/transactions/{transaction_id}", "request_parameters": { "path.transaction_id": "request.path.loan_id" }, "responses": { "200": { "response_template": "#set($inputRoot = $input.path('$')){ \"loan_label\": \"$inputRoot.label\", \"loan_id\": \"$inputRoot.transaction_id\", \"created_at\": \"$inputRoot.created_at\"}", "schema": { "type": "object", "properties": { "loan_label": { "type": "string", "description": "Loan label." }, "loan_id": { "type": "string", "description": "Loan ID." }, "created_at": { "type": "string", "format": "datetime", "description": "Loan created at." } } }, "documentation": { "description": "Loan", "example": { "loan_label": "foo", "loan_id": "01GKF9A4QZ79RSCMJ041HEZSMK", "created_at": "2022-12-04T21:23:54" } } }, "404": { "response_template": "$input.json('$')", "documentation": { "description": "Not found", "example": { "message": "Loan not found." } }, "schema": { "type": "object", "properties": { "message": { "type": "string", "description": "Error message." } } } } } } } ``` ##### Response 201400404 application/json Copy OK Response ``` { "product_identifier": "ed011136-4199-4efe-8ba1-71b6eb302744", "path": "/loans", "http_method": "POST" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_identifier` required | `string (uuid)` path | `foo` | Product ID | ##### Request body`application/json` 12 fields | Field | Type | Description | | --- | --- | --- | | `path`required | `string` | Path of your endpoint. Have to start with '/' | | `http_method`required | `string` | HTTP method of your endpoint.`DELETE``GET``PATCH``POST``PUT` | | `operation_id`required | `string` | Operation id of your endpoint. Used for OpenAPI generation. | | `request_schema` | `object` | Request schema | | `product_api_identifiers`required | `string[]` | Product API identifiers | | `product_component`required | `string` | Product component | | `product_endpoint`required | `string` | Product endpoint | | `product_sequence`required | `integer` | Product sequence for Site product | | `description` | `string` | Description | | `example` | `object` | Request body example | | `parameters` | `object[]` | Description and examples for path/query/headers parameters | | `in`required | `string` | Location, where your parameters is presented.`header``path``query` | | `name`required | `string` | Name of your parameter | | `schema`required | `object` | JSON schema of your parameter | | `type`required | `string` | Data type of your parameter`boolean``integer``number``string` | | `example`required | `string` | Example of your parameter | | `integration`required | `object` | Your integration information | | `http_method` | `string` | HTTP method of request your API will make to Staircase API | | `url` | `string` | URL part without domain name of request your API will make to Staircase API | | `request_template` | `string` | VTL request template that defines request body of request your API will make to Staircase API | | `request_parameters` | `string` | Mapping between path/query/header parameters from request that your API receives to the Staircase API | | `responses` | `object` | Information about processing responses from Staircase API, that you call. Key has to be status code, that will process. | ##### Response `201``application/json` 3 fields OK Response | Field | Type | Description | | --- | --- | --- | | `product_identifier` | `string (uuid)` | Product ID | | `path` | `string (string)` | path | | `http_method` | `string` | method | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/apis` #### List APIs [new] `list_apis` List APIs List APIs. Response may not have APIs but contains `next_token`. That means that there are results on next pages ##### Response 200400404 application/json Copy OK Response ``` { "next_token": "7b22504b223a2022666f6f222c2022534b223a2022626172227d", "apis": [ { "product_identifier": "ed011136-4199-4efe-8ba1-71b6eb302744", "base_path": "product-product", "is_deployed": true }, { "product_identifier": "0206ce61-ed46-492d-98be-9d7f5f166e7d", "base_path": "foo/bar", "is_deployed": false } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `next_token` | `string` query | `31132629274945519779805322857203735586714454643391594505` | Next token for pagination | | `limit` | `integer` query | `5` | Items limit | ##### Response `200``application/json` 2 fields OK Response | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination token | | `apis` | `object[]` | APIs | | `product_identifier` | `string (uuid)` | Product ID | | `base_path` | `string` | Base path | | `is_deployed` | `boolean` | Indicator if API was deployed at least once | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/apis/{product_identifier}/deploy` #### Deploy API `deploy_api` Deploys your API with specified product identifier. Deployed changes will be available in few minutes after deployment ##### Response 200400404 application/json Copy OK Response ``` { "product_identifier": "ed011136-4199-4efe-8ba1-71b6eb302744", "status": "DEPLOY_IN_PROGRESS" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_identifier` required | `string (uuid)` path | `foo` | Product ID | ##### Response `200``application/json` 2 fields OK Response | Field | Type | Description | | --- | --- | --- | | `product_identifier` | `string (uuid)` | Product ID | | `status` | `string` | Status | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields Too many requests. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | `GET` `/apis/{product_identifier}/openapi` #### Retrieve OpenAPI `get_openapi` Retrieve OpenAPI of deployment API. Changes that are not deployed will not be presented in the OpenAPI. ##### Response 200400404 application/json Copy OK Response ``` {} ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_identifier` required | `string (uuid)` path | `foo` | Product ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200` `GET` `/apis/{product_identifier}/logs` #### Retrieve Logs `get_logs` Retrieve list of API invocations logs. ##### Response 200400404 application/json Copy OK Response ``` { "logs": [ { "log_id": "05a50ea791fe0795d12a6745d010946f", "last_event_datetime": "2022-12-16T12:53:15.686298" } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_identifier` required | `string (uuid)` path | `foo` | Product ID | | `next_token` | `string` query | `31132629274945519779805322857203735586714454643391594505` | Next token for pagination | | `limit` | `integer` query | `5` | Items limit | ##### Response `200``application/json` 2 fields OK Response | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination token | | `logs` | `object[]` | Logs | | `log_id` | `string` | Log ID | | `last_event_datetime` | `string (date-time)` | Last event date time | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/apis/{product_identifier}/logs/{log_id}` #### Retrieve Log Events `get_log` Retrieve Logs Retrieve log events. ##### Response 200400404 application/json Copy OK Response ``` { "events": [ { "timestamp": "2022-12-16T10:33:29.067", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Extended Request Id: dOwF8HWWoAMF4BQ=" }, { "timestamp": "2022-12-16T10:33:29.068", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Verifying Usage Plan for request: 8f575720-12c8-46e3-93dd-315bca0e4d42. API Key: ******************************0300c8 API Stage: 4g92h4obi0/api" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Usage Plan check succeeded for API Key ******************************0300c8 and API Stage 4g92h4obi0/api" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Starting execution for request: 8f575720-12c8-46e3-93dd-315bca0e4d42" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) HTTP Method: POST, Resource Path: /c757967a-c988-4119-b857-1f4691508d02/loans" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) API Key: ******************************0300c8" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) API Key ID: 2i75ejp0oa" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method request path: {}" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method request query string: {}" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method request headers: {x-api-key=******************************0300c8, User-Agent=python-requests/2.28.1, X-Forwarded-Proto=https, X-Amz-Cf-Id=KbOkVNYF-kYDISmt1P2Np-Wlp6qIpxzKN5xbB0hk6CTWGZbFRrvuXw==, X-Forwarded-For=74.91.0.55, 15.158.35.43, content-type=application/json, Host=persistence.staircaseapi.com, X-Forwarded-Port=443, accept-encoding=gzip, deflate, X-Amzn-Trace-Id=Root=1-639c2d59-2293811d029398d96147cf54, accept=*/*, via=1.1 008cd6752eb718142dfefe2f7e847982.cloudfront.net (CloudFront)}" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method request body before transformations: {\"loan_label\": \"foo\"}" }, { "timestamp": "2022-12-16T10:33:29.070", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Request validation succeeded for content type application/json" }, { "timestamp": "2022-12-16T10:33:29.074", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Endpoint request URI: https://persistence.staircaseapi.com/persistence/transactions" }, { "timestamp": "2022-12-16T10:33:29.074", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Endpoint request headers: {x-amzn-apigateway-api-id=4g92h4obi0, Accept=application/json, x-api-key=******************************0300c8, User-Agent=AmazonAPIGateway_4g92h4obi0, X-Amzn-Trace-Id=Root=1-639c2d59-2293811d029398d96147cf54, Content-Type=application/json}" }, { "timestamp": "2022-12-16T10:33:29.074", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Endpoint request body after transformations: {\"label\": \"foo\"}" }, { "timestamp": "2022-12-16T10:33:29.074", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Sending request to https://persistence.staircaseapi.com/persistence/transactions" }, { "timestamp": "2022-12-16T10:33:32.561", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Received response. Status: 201, Integration latency: 3487 ms" }, { "timestamp": "2022-12-16T10:33:32.561", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Endpoint response headers: {Content-Type=application/json, Content-Length=245, Connection=keep-alive, Date=Fri, 16 Dec 2022 08:33:32 GMT, x-amzn-RequestId=4eb2676a-9f6d-4a71-abd3-8d51ab2075fd, access-control-allow-origin=*, strict-transport-security=max-age=31536000; includeSubDomains; preload, access-control-allow-headers=Authorization,Content-Type,X-Amz-Date,X-Amz-Security-Token,X-Api-Key, x-amz-apigw-id=dOwF9ELkIAMFUtw=, X-Amzn-Trace-Id=Root=1-639c2d59-2293811d029398d96147cf54;Sampled=1, X-Cache=Miss from cloudfront, Via=1.1 640e1fde1214554c9f15c8cb85df826a.cloudfront.net (CloudFront), X-Amz-Cf-Pop=IAD55-P2, X-Amz-Cf-Id=ybYqTc-fhx_uPoQPcRLyd0VofrIirq_NFEEAWNjOmrOPpusYN4HNsw==}" }, { "timestamp": "2022-12-16T10:33:32.561", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Endpoint response body before transformations: {\"label\": \"foo\",\"created_at\": \"2022-12-16T03:33:32.498711-05:00\",\"transaction_id\": \"01GMD12CAJ5FCV4SW837WCJZ2Y\",\"_links\": {\"collections\": \"https://persistence.staircaseapi.com/persistence/transactions/01GMD12CAJ5FCV4SW837WCJZ2Y/collections\"}}" }, { "timestamp": "2022-12-16T10:33:32.561", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method response body after transformations: {\"loan_label\": \"foo\",\"loan_id\": \"01GMD12CAJ5FCV4SW837WCJZ2Y\"}" }, { "timestamp": "2022-12-16T10:33:32.562", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method response headers: {X-Amzn-Trace-Id=Root=1-639c2d59-2293811d029398d96147cf54;Sampled=1, Access-Control-Allow-Headers=Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token,X-Amz-User-Agent, Access-Control-Allow-Origin=*, Access-Control-Allow-Methods=GET,DELETE,OPTIONS,PATCH,POST,PUT, Strict-Transport-Security=max-age=31536000; includeSubDomains; preload, Content-Type=application/json}" }, { "timestamp": "2022-12-16T10:33:32.562", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Successfully completed execution" }, { "timestamp": "2022-12-16T10:33:32.562", "message": "(8f575720-12c8-46e3-93dd-315bca0e4d42) Method completed with status: 201" } ] } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_identifier` required | `string (uuid)` path | `foo` | Product ID | | `log_id` required | `string` path | `05a50ea791fe0795d12a6745d010946f` | Log ID | | `next_token` | `string` query | `31132629274945519779805322857203735586714454643391594505` | Next token for pagination | | `limit` | `integer` query | `5` | Items limit | ##### Response `200``application/json` 2 fields OK Response | Field | Type | Description | | --- | --- | --- | | `next_token` | `string` | Pagination token | | `events` | `—` | Events | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `DELETE` `/apis/{product_identifier}` #### Delete API `delete_api` Delete API. Service deletes the API and all the endpoints of this API. ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource is not found ``` { "message": "Resource is not found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `product_identifier` required | `string (uuid)` path | `b1e98e0e-adnf-4cdd-b065-16feb5493049` | Product ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `429``application/json` 1 fields Too many requests. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Other responses `204` ### Api Examples `POST` `/apis-examples/subsets` #### Generate Subset `generate_subset` Extract the part of the JSON data by the provided api schema definition in `Lexicon` format. ##### Request application/json Copy ``` { "api_data_example": { "foo": [ { "bar1": "baz1" }, { "bar2": "baz2" } ], "bar": { "biz": "baz", "booz": "baz" } }, "root_schema_fields": [ "foo_schema_id", "bar_schema_id" ], "all_schema_fields": [ { "@id": "foo_schema_id", "@type": "api_schema", "name": "foo", "requirement_indicator": true, "has_graph_entity": "01H28AB7BRQ066FJCHXEN1SW7T", "has_api_schema_field": [ "bar1_schema_id" ] }, { "@id": "bar1_schema_id", "@type": "api_schema", "name": "bar1", "requirement_indicator": false, "has_graph_entity": "01H28AB7BRGBRJDC3CD7Y3S0C7" }, { "@id": "bar_schema_id", "@type": "api_schema", "name": "bar", "requirement_indicator": true, "has_graph_entity": "01H28AB7BRQ066FJCHXEN1SW7O", "has_api_schema_field": [ "booz_schema_id" ] }, { "@id": "booz_schema_id", "@type": "api_schema", "name": "booz", "requirement_indicator": false, "has_graph_entity": "01H28AB7BRGBRJDC3CD7Y3S0C7" } ] } ``` ##### Response 201400 application/json Copy Created item successfully ``` { "example_data_subset": { "foo": [ { "bar1": "baz1" } ], "bar": { "booz": "baz" } } } ``` application/json Copy Request data failed validation ``` { "detailedMessage": "Bad request exception" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `api_data_example`required | `one of` | The complete JSON data to be processed. | | `root_schema_fields`required | `string[]` | The @id-s of the root data children datapoints. | | `all_schema_fields`required | `object[]` | The api schema definition in `Lexicon` format. | | `name`required | `string` | Data property name. | | `has_api_schema_fields` | `string[]` | JSON-LD @id-s of the schema definitions for the child data points. | ##### Response `201``application/json` 1 fields Created item successfully | Field | Type | Description | | --- | --- | --- | | `example_data_subset` | `one of` | Generated subset of the API example data. | ##### Response `400``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `detailedMessage` | `string` | Message | | `code` | `string` | Code | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Loans `POST` `/loans` #### Create loan Create Loan ##### Request application/json Copy ``` { "loan_label": "foo" } ``` ##### Response application/json Copy Loan created. ``` { "loan_label": "foo", "loan_id": "01GKF9A4QZ79RSCMJ041HEZSMK" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | — | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `loan_label`required | `string` | — | ##### Response `201``application/json` 2 fields Loan created. | Field | Type | Description | | --- | --- | --- | | `loan_label` | `string` | — | | `loan_id` | `string` | — | ### Operations `GET` `/{product}/connector-configurations` #### Retrieve Connector Configurations `retrieve-connector-configurations` Retrieve the all connector configurations for the given product. The `configuration` field can be passed as a path parameter the `/setups` endpoint. ##### Response 200403404 application/json Copy Connector Configurations Found ``` [ { "configuration": "test", "partners": [ { "partner": "plaid" }, { "partner": "finicity" } ] }, { "configuration": "production", "partners": [ { "partner": "plaid" }, { "partner": "finicity" } ] } ] ``` 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" } ``` application/json Copy Connector configuration not found ``` { "message": "Unable to retrieve configurations for given product." } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `product` required | `string` path | Staircase product name | ##### Response `200``application/json` 2 fields Connector Configurations Found | Field | Type | Description | | --- | --- | --- | | `configuration` | `string` | Name of the configuration. Can be passed into the /setups endpoint. | | `partners` | `object[]` | An array of vendors associated with the configuration | | `partner` | `string` | Name of the vendor | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Connector configuration not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `400` `POST` `/{product}/connector-configurations/{configuration}/setups` #### Set up Connector Configuration `setup-connector-configuration` Set up a connector configuration by passing product and configuration name. You can check the type of configurations by using the GET /connector-configurations endpoint. ##### Response 200403404 application/json Copy Configuration set up successfully ``` { "message": "Configuration is set up successfully." } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to retrieve configurations for given product." } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `product` required | `string` path | Staircase product name | | `configuration` required | `string` path | Product configuration name | ##### Response `200``application/json` 1 fields Configuration set up successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `400` `POST` `/build` #### Build payload Build a payload for collections, where the pathes can be taken from appropriate endpoint. Values, that are passed is validated against the JSON schema. ##### Request application/json Copy ``` { "$.deal_sets[0].parties[0].individual.first_name": "Mykyta", "$.deal_sets[0].parties[0].roles[0].party_type": "Borrower", "$.deal_sets[0].parties[0].roles[0].employers[0].legal_entity_name": "Truework Inc", "$.deal_sets[0].parties[0].taxpayer_identifiers[0].value": "999-00-0000" } ``` ##### Response application/json Copy 200 response ``` { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": "Mykyta" }, "roles": { "role": [ { "role_detail": { "party_type": "Borrower" }, "borrower": { "employers": { "employer": [ { "legal_entity": { "legal_entity_detail": { "full_name": "Truework Inc" } } } ] } } } ] }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "type": "EmployerIdentificationNumber", "value": "999-00-0000" } ] } } ] } } ] } } ] } } ``` ##### Other responses `200` `POST` `/hello-world` #### Hello World Dummy hello world endpoint ##### Other responses `200` `GET` `/loans/{loan_id}` ##### Response 200404 application/json Copy Loan ``` { "loan_label": "foo", "loan_id": "01GKF9A4QZ79RSCMJ041HEZSMK", "created_at": "2022-12-04T21:23:54" } ``` application/json Copy Not found ``` { "message": "Loan not found." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | — | | `loan_id` required | `string` path | `01GKKGSG9NHCTP1XM8W4W833QD` | — | ##### Response `200``application/json` 3 fields Loan | Field | Type | Description | | --- | --- | --- | | `loan_label` | `string` | Loan label. | | `loan_id` | `string` | Loan ID. | | `created_at` | `string (datetime)` | Loan created at. | ##### Response `404``application/json` 1 fields Not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/schema` #### Retrieve part of staircase json schema by json path returns the schema for specified JSON path, that it is used for payload validation ##### Response application/json Copy 200 response ``` { "type": "string", "description": "An identifier for the current instance of VIEW. The party assigning the identifier should be provided using the IdentifierOwnerURI." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `json_path` required | `string` query | `$.deal_sets[0].parties[0].individual.first_name` | — | ##### Other responses `200` `POST` `/sdks` #### Generate SDK for the specific service Using input link to swagger and request details generate SDK for the service ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `service_name` | `string` | Name of service for which sdk need to be generated | | `swagger_link` | `string` | Link to swagger (OpenAPI) json file which need to be used for SDK generation | | `programming_language` | `string` | Programming language for which we need to generate SDK | | `service_version` | `string` | Version of service | ##### Response `201``application/json` 3 fields SDK generated successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Status message of SDK generation process | | `success` | `boolean` | Does operation generate SDK | | `generated_sdk_url` | `string` | URL to generated SDK on s3 bucket | ##### Response `400``application/json` 2 fields Bad request body | Field | Type | Description | | --- | --- | --- | | `error_message` | `string` | Short error reason message | | `error_description` | `string` | Long description of error cause | ##### Response `409``application/json` 3 fields SDK with provided parameters already exist | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Status message of SDK generation process | | `success` | `boolean` | Does operation generate SDK | | `generated_sdk_url` | `string` | URL to generated SDK on s3 bucket | `DELETE` `/sdks/{programming_language}/{service_name}` #### Delete existing SDK with service_version bucket Delete SDK inside service_version bucket and this bucket itself ##### Parameters 3 | Parameter | Type | Description | | --- | --- | --- | | `programming_language` required | `string` path | SDK client language | | `service_name` required | `string` path | Name of service | | `service_version` required | `string` query | The version of service for which we need delete SDK | ##### Response `200``application/json` 2 fields SDK and service_version bucket was deleted successfully | Field | Type | Description | | --- | --- | --- | | `success` | `boolean` | Show the success status of deletion process | | `description` | `string` | Short description message of success status | ##### Response `404``application/json` 2 fields Not found any SDK's related to requested parameters | Field | Type | Description | | --- | --- | --- | | `success` | `boolean` | Show the success status of deletion process | | `description` | `string` | Short description message of success status | ##### Other responses `400` `GET` `/sdks/{programming_language}/{service_name}` #### Get S3 bucket url's to SDK's for reuqested parameters Get all existing S3 bucket url's to SDK's for the requested programming language , service name and version ##### Parameters 3 | Parameter | Type | Description | | --- | --- | --- | | `programming_language` required | `string` path | Name of programming language for which we need to download SDK | | `service_name` required | `string` path | Name of service for the requested SDK | | `service_version` | `string` query | Version of service | ##### Response `200``multipart/form-data` 2 fields Found SDK's for the requested parameters | Field | Type | Description | | --- | --- | --- | | `sdk_version` | `string` | Version of service SDK | | `generated_sdk_url` | `string` | URL of generated SDK to S3 bucket | ##### Other responses `404` `POST` `/validate` #### Validate OpenAPI file ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `url` | `string` | url to swagger file | ##### Response `400``application/json` 1 fields Validator found some errors | Field | Type | Description | | --- | --- | --- | | `errors` | `object[]` | — | | `error_type` | `string` | — | | `message` | `string` | — | ##### Other responses `200` `POST` `/validate/{language}` #### Validate element `validate_element` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | API key | | `language` required | `string` path | Language name | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `values` | `object` | — | | `element_type` | `string` | — | ##### Response `200``application/json` 2 fields Element is valid | Field | Type | Description | | --- | --- | --- | | `values` | `object` | — | | `element_type` | `string` | — | ##### Response `400``application/json` 1 fields Validation failed | Field | Type | Description | | --- | --- | --- | | `errors` | `object[]` | — | | `error_type` | `string` | — | | `message` | `string` | — | ## Errors `400``403``404``409``422``429` ## More in Integration - Previous product: Job - Next product: Workflow --- # Workflow # Workflow Process orchestration against the system that holds the loan file: document requests, condition clearing and milestone advances executed without a person touching each step. Origination systems carry their own workflow — a condition raised on a file, a document requested from a borrower, a task assigned to a processor. Driving that work from outside means operating the system's workflow rather than only its data. The slot covers those actions: raising and clearing conditions, requesting documents, and advancing milestones from the products that produced the underlying result. No specification survives in the recorded definitions. The catalogue names the slot and the page carries no endpoint detail. ## How it works Connection carries the transport of a call to an outside system and Job carries its scheduling. This carries the sequence: which step follows which, and what each one is waiting on. The three together are what a product means when it says it reaches a system it does not own. ## More in Integration - Previous product: Product --- # Products # Products The mortgage and real-estate functions: what each does, its operations, the canonical fields it reads and writes, and the vendors serving it. Eight categories, each answering one question about a loan. Verification asks whether what the borrower said is true. Assessment asks what the collateral is and what it is worth. Eligibility asks whether someone will buy the loan. Contract asks what the documents and the numbers are. Validation asks whether the artifacts produced are correct. Automation moves the loan without a person. Integration reaches the systems of record, and Adapters connects to the origination system itself. Seven products appear in two categories, because they genuinely answer two of those questions. The category is what distinguishes them. A product's contract never names the vendor behind it, so a vendor can be introduced, reordered or replaced without a caller changing anything. The vendors themselves are under Providers. Every product inherits the same endpoint surface: request and response schema, the vendor ordering, invocation history, the partner list and report templates. That surface is defined once, in Product, rather than re-implemented per vertical. - Appraisal - Approval - Asset - Boarding - Closing - Compliance - Credit - Document - Electronic - Employment - Fee - Fraud - Government - Identity - Income - Insurance - Lexicon - Listing - LOS - Notary - POS - Price - Property - Rating - Servicing - Signature - Tax - Title - Valuation --- # Adapters # Adapters Connect to the loan origination system itself: the read and write path beneath every product that touches a loan file. Connect to the loan origination system itself. The origination system is where the loan lives, so this category is the layer everything else depends on rather than a peer of the other categories. Two slots. The adapter carries the read and write path and the mapping into the canonical model; the workflow slot drives the origination system's own workflow — raising and clearing conditions, requesting documents — rather than only its data. ## Products In the order the value chain runs. 1. LOS has a recorded specification --- # LOS # LOS The origination-system adapter, in its Adapters listing: the connective layer beneath every product that touches the loan file. This is the same slot as LOS under Integration, carried in both categories because the source catalogue lists it in both. The Integration listing is the vendor-facing view; this one is the platform-facing view. What sits here is the read and write path into the loan file: a product asks the adapter for the loan, works in canonical classes, and writes back through the same layer. ## Dual listing LOS is filed under two categories. The other listing is LOS under Integration , and the recorded specifications resolve there — its 10 operations render on that page. ## Operations ### Byte Service Application `POST` `/job/jobs/los-byte-VOI/executions` #### Income Service Application `byteIncomeAutomation` Invoke Income Verification Income Service Application You can start an Income Verification for a loan in Byte using this endpoint. This endpoint takes file_data_id which is the file id in Byte. ##### Request application/json Copy ``` { "file_data_id": 1000032 } ``` ##### Response 201400403500 application/json Copy Income Verification Triggered Successfully ``` { "execution_id": "01FDYNKEP7DRV8HAE4X6J580NP" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `file_data_id`required | `string` | Byte File ID | ##### Response `201``application/json` 1 fields Income Verification Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `execution_id` | `string` | Execution ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/job/jobs/los-byte-VOI/{execution_id}` #### Retrieve Execution Status `retrieveByteIncomeExecutionStatus` Retrieve Adapter Invocation Response Retrieves Execution Status ##### Response 201 Get Execution Detail Succeeded201 Get Execution Detail Failed400403 application/json Copy Successfully finished execution. ``` { "status": "SUCCEEDED", "start_time": "2021-08-11T17:06:47.000Z", "stop_time": "2021-08-11T17:07:40.000Z", "health_logs_url": "https://documentation.staircaseapi.com/code-health-checker/metric/01FDCEJT790J22PY13MCP0B90K" } ``` application/json Copy Successfully finished execution. ``` { "status": "FAILED", "start_time": "2021-08-11T15:54:47.000Z", "stop_time": "2021-08-11T15:54:59.000Z", "health_logs_url": "https://documentation.staircaseapi.com/code-health-checker/metric/01FDCEJT790J22PY13MCP0B90K" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `execution_id` required | `string (ulid)` path | `01FEK8V6RT027SRAW903G97DPF` | Execution ID | ##### Response `201``application/json` 7 fields Successfully finished execution. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Job Execution Status`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT``WAIT_FOR_ACTION` | | `start_time` | `string` | ISO 8601 format with UTC | | `stop_time` | `string` | ISO 8601 format with UTC | | `health_logs_url` | `string` | Health URL for execution | | `execution_output` | `object` | Contains status, response_payload, request_payload. | | `execution_data` | `—` | Description | | `next_token` | `string` | If next_token is returned, there are more results available. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Setup `GET` `/partners` #### Get Partners `getPartners` Get list of all LOS partners Retrieve Partners retrieves an object containing all active partners for LOS. ##### Response 200400403422500 application/json Copy Successfully returned the partner object ``` [ { "partner": "partner_name_1", "active": true, "status": "active" }, { "partner": "partner_name_2", "active": true, "status": "active" }, { "partner": "partner_name_3", "active": false, "status": "upcoming" } ] ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Response `200``application/json` 3 fields Successfully returned the partner object | Field | Type | Description | | --- | --- | --- | | `active` | `boolean` | If set to "True" partner can be used for verification. If set to "False" partner will be disabled for verification and excluded from the waterfall. | | `status` | `string` | Parameter for documentation. Can be set to "active" and "upcoming". | | `partner` | `string` | Partner name. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/partners/{partner_name}/schema` #### Get Partner Schema `getPartnerSchema` Get list of all LOS partners Retrieve Partner Credentials Schema retrieves the required partner schema for credentials. ##### Response 200400403422500 application/json Copy Successfully returned the partner schema object ``` { "$schema": "http://json-schema.org/draft-07/schema", "$id": "http://example.com/example.json", "type": "object", "title": "Partner root schema", "description": "Partner credentials schema for connector flows.", "webhook": false, "default": {}, "examples": [ { "key1": "value1", "key2": "value2" } ], "required": [ "key1", "key2" ], "properties": { "key1": { "$id": "#/properties/key1", "type": "string", "title": "Partner key1 schema", "description": "Partner key1", "default": "", "examples": [ "value1" ] }, "key2": { "$id": "#/properties/key2", "type": "string", "title": "Partner key2 schema", "description": "Partner key2", "default": "", "examples": [ "value2" ] } }, "additionalProperties": true } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `partner_name` required | `string` path | `partner_name` | Name of the partner for which we wan't to retrieve schema | ##### Response `200``application/json` 10 fields Successfully returned the partner schema object | Field | Type | Description | | --- | --- | --- | | `schema` | `string` | Schema URL | | `id` | `string` | Schema ID | | `type` | `string` | JSON type | | `title` | `string` | Schema title | | `description` | `string` | Schema description | | `webhook` | `boolean` | Value that indicates if partner requires webhook setup | | `default` | `object` | Default value for schema | | `examples` | `object[]` | List of examples | | `key1` | `string` | Example 1 | | `key2` | `string` | Example 2 | | `required` | `string[]` | Required fields | | `properties` | `object` | Properties of Schema | | `key1` | `object` | Key 1 Schema | | `id` | `string` | Property ID | | `type` | `string` | Property value type | | `title` | `string` | Title for property | | `description` | `string` | Description for property | | `default` | `string` | Default value if exists | | `examples` | `string[]` | List of examples for given property | | `key2` | `object` | Key 2 Schema | | `id` | `string` | Property ID | | `type` | `string` | Property value type | | `title` | `string` | Title for property | | `description` | `string` | Description for property | | `default` | `string` | Default value if exists | | `examples` | `string[]` | List of examples for given property | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/byte/credentials` #### Get Byte Credentials `getByteCredentials` Get Byte Credentials except the password ##### Response 200400403422500 application/json Copy Byte Credentials Response ``` { "site_name": "YOUR Byte Site Name", "username": "admin", "Authorization Key": "YOUR Authorization Key" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `credentials_type` | `string` query | `test` | Credentials type: production or test | ##### Response `200``application/json` 4 fields Byte Credentials Response | Field | Type | Description | | --- | --- | --- | | `site_name`required | `string` | The Byte Site Name | | `username`required | `string` | The username | | `authorization_key`required | `string` | Authorization Key | | `server_url`required | `string` | Authorization Key | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `POST` `/byte/credentials` #### Set Byte Credentials `setByteCredentials` ##### Request application/json Copy ``` { "site_name": "YOUR Byte Site Name", "username": "admin", "password": "------", "Authorization Key": "YOUR Authorization Key" } ``` ##### Response 200400403422500 application/json Copy Create Adapter API Triggered Successfully ``` { "message": "Credentials are saved and verified" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `credentials_type` | `string` | Credentials Type`production``test` | | `server_url`required | `string` | The url of Byte site | | `site_name`required | `string` | The Byte Site Name | | `username`required | `string` | The username | | `password`required | `string` | The password | | `authorization_key`required | `string` | Authorization Key | ##### Response `200``application/json` 1 fields Create Adapter API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/encompass/credentials` #### Get Encompass Credentials `getEncompassCredentials` Get Encompass Credentials except the password ##### Response 200400403422500 application/json Copy Encompass Credentials Response ``` { "encompass_instance_id": "TEBE1234", "username": "admin", "client_id": "YOUR CLIENT ID", "client_secret": "" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Response `200``application/json` 4 fields Encompass Credentials Response | Field | Type | Description | | --- | --- | --- | | `encompass_instance_id` | `string` | Encompass instance ID | | `username` | `string` | Username | | `client_id` | `string` | The unique identifier for the client application. | | `client_secret` | `string` | The secret for the client application. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `POST` `/encompass/credentials` #### Set Encompass Credentials `setEncompassCredentials` Important: You do not need to use this endpoint to use Staircase Service integrations in Encompass Applications! Set Encompass Credentials makes our services available by securely storing your credentials in staircase systems. #### Credentials Table | Credential | Description | Services that need | | --- | --- | --- | | Encompass Instance ID | Used for setting up staircase service inside encompass | `Process Automations`,`Input Adapters`,`Output Adapters`, `Staircase Automatizations` | | Username | Used for setting up staircase service inside encompass | `Process Automations`,`Input Adapters`,`Output Adapters`, `Staircase Automatizations` | | Password | Used for setting up staircase service inside encompass | `Process Automations`,`Input Adapters`,`Output Adapters`,`Staircase Automatizations` | | Client ID | Used for setting up staircase automations service inside encompass | `Input Adapters`,`Output Adapters`, `Staircase Automatizations` | | Client Secret | Used for setting up staircase automations service inside encompass | `Input Adapters`,`Output Adapters`, `Staircase Automatizations` | #### How to obtain Client ID and Client Secret? You can obtain these credentials from the Encompass Developer Connect Console. Show the rest #### Setting up Staircase Services inside Encompass After successfully registering your credentials, you can enable Staircase Services automatically by using Process Automations Service. ##### Request application/json Copy ``` { "encompass_instance_id": "TEBE1234", "username": "admin", "password": "------", "client_id": "YOUR CLIENT ID", "client_secret": "" } ``` ##### Response 200400403422500 application/json Copy Create Adapter API Triggered Successfully ``` { "message": "Credentials are saved and verified" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `encompass_instance_id` | `string` | The Encompass instance ID | | `username` | `string` | The username | | `password` | `string` | The grant type must be "password" for resource owner password credentials | | `client_id` | `string` | The unique identifier for the client application. Replace with the API client ID portion of the API key available from your Encompass Super Administrator | | `client_secret` | `string` | The secret for the client application. Replace with the API client secret portion of the API key available from your Encompass Super Administrator | ##### Response `200``application/json` 1 fields Create Adapter API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/encompass-epc/credentials` #### Get Encompass (EPC) Credentials `getEncompassEPCCredentials` ##### Response 200400403422500 application/json Copy Encompass EPC Credentials Response ``` { "client_id": "YOUR EPC CLIENT ID", "client_secret": "" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Response `200``application/json` 2 fields Encompass EPC Credentials Response | Field | Type | Description | | --- | --- | --- | | `client_id` | `string` | The unique identifier for the client application. | | `client_secret` | `string` | The secret for the client application. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `POST` `/encompass-epc/credentials` #### Set Encompass (EPC) Credentials `setEncompassEPCCredentials` EPC uses the Client Credentials grant type to give Partner products secure access to lender-owned resources. With the Client Credentials grant type, a client application sends its own credentials (its Client ID and Client Secret) to an Ellie Mae oAuth2 Identity Service endpoint that generates an access token. In order to be able to use Staircase Service Application component for processing your EPC transactions, you need to set your credentials. ##### Request application/json Copy ``` { "client_id": "YOUR EPC CLIENT ID", "client_secret": "" } ``` ##### Response 200400403422500 application/json Copy Create Adapter API Triggered Successfully ``` { "message": "Credentials are saved and verified" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `client_id` | `string` | The unique identifier for the client application. | | `client_secret` | `string` | The secret for the client application. | ##### Response `200``application/json` 1 fields Create Adapter API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` ### Sales Boomerang Adapter `POST` `/products/los-sales-boomerang/invocations/` #### Invoke Sales Boomerang Adapter `salesBoomerang` Sales Boomerang Adapter #### Usage You can send a request in two different ways: - Using `request_data`: If you provide this parameter, flow invocation would use the data here as input. If you also provide a `transaction_id` in the request body, Response Collection would be created in the related Transaction object. If you don't provide a `transaction_id` we will automatically create a Transaction for you and Response Collection would be created in this new Transaction as well. - Using `transaction_id` and `request_collection_id`: If you already have a request collection, you can provide its details using these two parameters. Note that in this case Response Collection would be created in the provided Transaction. #### Retrieving the Invocation Result After invocation, endpoint returns an `invocation_id` which you can poll for its status using Retrieve Invocation Response endpoint. Once the invocation is completed, the Response Collection is populated with these search results. Show the rest If you would rather receive a callback once the invocation is completed instead of polling it, you can set `callback_url` parameter in the request body. #### Supported Staircase Products Flows - `create_loan` - `update_loan` - `list_loans` - `delete_loan` #### How to Use Sales Boomerang Adapter with any Staircase CRM Integration The following diagram illustrates the general overview about integration ##### Request Create LoanUpdate LoanDelete LoanList LoansStaircase Lexicon Example Loan Collection application/json Copy ``` { "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X", "product_flow_name": "create_loan", "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3", "options": { "credentials": { "api_key": "" } } } ``` application/json Copy ``` { "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X", "product_flow_name": "update_loan", "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3", "options": { "credentials": { "api_key": "" } } } ``` application/json Copy ``` { "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X", "product_flow_name": "delete_loan", "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3", "options": { "credentials": { "api_key": "" } } } ``` application/json Copy ``` { "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X", "product_flow_name": "list_loans", "request_data": {}, "options": { "credentials": { "api_key": "" }, "query": { "modified_from": "2022-03-17T00:00:00" } } } ``` application/json Copy ``` { "metadata": { "version": 2, "validation": false }, "data": { "loans": [ { "@id": "01FT93DZJRD06E7VC5SK08M9X2", "@type": "loan", "has_loan_role_type": { "has_value": "subject_loan" }, "has_loan_status_type": { "has_value": "new_loan" }, "has_mortgage_type": { "has_value": "conventional" }, "has_originator_loan_identifier": { "has_value": "01FT93DYZG12384RHJBP2RKHSG" }, "has_relocation_loan_indicator": { "has_value": false }, "secured_by_property": [ "01FT93F8YJ1AHDYXEBN803KM2M" ], "with_borrower": [ "_:b28" ] } ], "notes": [ { "has_notes_comment": { "has_value": "" } } ], "addresses": [ { "@id": "01FT93F8YJ2VXJBWPAF4PPWK1B", "@type": "residential_address", "has_address_line_1_text": { "has_value": "126 4TH ST" }, "has_city_name": { "has_value": "Texas" }, "has_county_name": { "has_value": "Collin" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "TX" } }, { "@id": "01FT93DZJQYP1J2C6XBJZNM1BW", "@type": "address", "has_address_line_1_text": { "has_value": "126 4th St" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Atlanta" }, "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } }, { "@id": "01FT93DZJQYP1J2C6XBJZNTEST", "@type": "address", "has_address_line_1_text": { "has_value": "126 4th St" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Atlanta" }, "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } } ], "contact_information": [ { "@id": "01FT93DZJQDE98K6BT0HDX52PD", "@type": "contact_information", "has_email_address": { "has_value": "test@email.com" }, "has_phone_number": { "has_value": "1231231232" } } ], "credit_information": [ { "@id": "01FT93ETHH63K1X8MG3QSWW4KM", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-01-25" }, "has_credit_report_identifier": { "has_value": "DEVWM6" }, "has_credit_report_last_updated_date": { "has_value": "2022-01-25" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "with_credit_score_information": [ "01FT93ETMMKVN9BPR713GEWME0" ] } ], "credit_score_information": [ { "@id": "01FT93ETMMKVN9BPR713GEWME0", "@type": "credit_score_information", "has_credit_report_identifier": { "has_value": "DEVWM6" }, "has_credit_score": { "has_value": "00660" } } ], "employment": [ { "@id": "01FT93DZJRDQ78KW9J9GKM5H4G", "@type": "employment", "has_current_employment_indicator": { "has_value": "True" }, "has_employment_classification_type": { "has_value": "secondary" }, "has_employment_monthly_income_amount": { "has_value": 15000 }, "has_employment_position_description": { "has_value": "Software Engineer" }, "has_employment_start_date": { "has_value": "2008-04-15" }, "has_ownership_interest_type": { "has_value": "greater_than_or_equal_to_25_percent" }, "has_self_employment_indicator": { "has_value": true }, "has_special_borrower_employer_relationship_indicator": { "has_value": false }, "has_time_in_line_of_work_months_count": { "has_value": 132 }, "provided_by": [ "01FT93DZJQNEP4GAQXGGGTTPXG" ] } ], "loan_identifiers": [ { "@type": "loan_identifier", "has_loan_identifier_type": { "has_value": "other" }, "has_loan_identifier_type_other_description": { "has_value": "sales_boomerang_id" }, "has_loan_identifier_value": { "has_value": 31042953 } }, { "@type": "loan_identifier", "has_loan_identifier_type": { "has_value": "other" }, "has_loan_identifier_type_other_description": { "has_value": "surefire" }, "has_loan_identifier_value": { "has_value": "01FYBVPJSQ81YNGEWRQ5WR5849" } } ], "organizations": [ { "@id": "01FT93DZJQNEP4GAQXGGGTTPXG", "@type": "organization", "has_organization_name": { "has_value": "Amazon" }, "with_address": [ "01FT93DZJQYP1J2C6XBJZNTEST" ] } ], "people": [ { "@id": "_:b28", "@type": "borrower", "contact_at": [ "01FT93DZJQDE98K6BT0HDX52PD" ], "employed_as": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ], "has_birth_date": { "has_value": "1958-12-12" }, "has_first_name": { "has_value": "TEST1" }, "has_last_name": { "has_value": "test" }, "has_marital_status_type": { "has_value": "unmarried" }, "has_middle_name": { "has_value": "" }, "has_taxpayer_identifier_value": { "has_value": "999008881" }, "lives_at": [ "01FT93DZJQ5E5QHAKC2NJMZ0ZM" ], "with_address": [ "01FT93DZJQYP1J2C6XBJZNM1BW" ], "with_credit_information": [ "01FT93ETHH63K1X8MG3QSWW4KM" ] } ], "properties": [ { "@id": "01FT93F8YJ1AHDYXEBN803KM2M", "@type": "subject_property", "has_financed_unit_count": { "has_value": 1 }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise" }, "has_project_type": { "has_value": "condominium" }, "has_property_usage_type": { "has_value": "primary_residence" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FT93F8YJ2VXJBWPAF4PPWK1B" ], "with_sales_contract": [ "01FT93F8YJNBJX6VCEED94ZFCR" ], "with_value": [ "01FT93F8YJCQG6R0D3Y7P74C6F" ] } ], "property_valuations": [ { "@id": "01FT93F8YJCQG6R0D3Y7P74C6F", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 200000 } } ], "residences": [ { "@id": "01FT93DZJQ5E5QHAKC2NJMZ0ZM", "@type": "residence", "has_borrower_residency_type": { "has_value": "current" }, "has_residency_basis_type": { "has_value": "living_rent_free" }, "has_residency_duration_months_count": { "has_value": 30 }, "with_address": [ "01FT93DZJQYP1J2C6XBJZNM1BW" ] } ], "sales_contracts": [ { "@id": "01FT93F8YJNBJX6VCEED94ZFCR", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 200000 } } ] } } ``` ##### Response 403404 Example404 application/json 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" } ``` application/json Copy Resource is not found. ``` { "message": "Unable to retrieve configurations for given product." } ``` application/json Copy Resource is not found. ``` 03/03/2021, 8:24:04 AM EST ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200``400``422` `GET` `/products/los-sales-boomerang/invocations/{invocation_id}` #### Get Invocation Status `RetrieveProductFlowInvocationStatus` Retrieves the status of running Product flow invocation. ##### Response 200 ProductFlowStatus200 WaterfallStatusCompleted200 WaterfallStatusFailed400403404500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "invocation_status": "COMPLETED", "product_flow_name": "VOE", "service_invocation": { "Connector": { "connector_flow_name": "demo_flow", "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e", "status": "COMPLETED" }, "Translator": { "output": { "translation_id": "ad985392-1255-4dc0-8a26-bc166744c60c", "language_name": "argyle", "status": "COMPLETED" }, "convert_output": { "translation_id": "5382d495-9ec9-4619-8e46-299879c1e92e", "language_name": "argyle", "status": "COMPLETED" }, "input": { "translation_id": "0742bc3d-07ca-45fb-a4b7-e9bf627108d0", "language_name": "test", "status": "COMPLETED" }, "convert_input": { "translation_id": "57082d7c-9964-49b6-945c-7c655768e56a", "language_name": "test", "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, "report_download_urls": { "voe_template": { "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": "demo_flow", "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e", "status": "COMPLETED" }, "Translator": { "output": { "translation_id": "ad985392-1255-4dc0-8a26-bc166744c60c", "language_name": "argyle", "status": "COMPLETED" }, "convert_output": { "translation_id": "5382d495-9ec9-4619-8e46-299879c1e92e", "language_name": "argyle", "status": "COMPLETED" }, "input": { "translation_id": "0742bc3d-07ca-45fb-a4b7-e9bf627108d0", "language_name": "test", "status": "COMPLETED" }, "convert_input": { "translation_id": "57082d7c-9964-49b6-945c-7c655768e56a", "language_name": "test", "status": "COMPLETED" } } } } }, "options": { "dry_run": false }, "tags": [ "manual verification" ] } ``` application/json Copy Successfully returned status of the Product flow Invocation. ``` { "invocation_id": "fbc19f9b-1d37-4ced-9f1d-d2769b018b0a", "invocation_status": "COMPLETED", "request_collection_id": "01FCWK741N7GWYBVG4Z3N74V16", "callback_url": "https://webhook.site/68a4aa6a-bf18-4f7d-be7d-bc26503adeb2", "transaction_id": "01FCWK72GC1MFM5003SXJHMWNG", "request_collection": { "data": { "foo": "bar", "biz": "baz" }, "metadata": { "created_at": "2021-08-12T03:11:25.749933-04:00", "validation": false }, "transaction_id": "01FCWK72GC1MFM5003SXJHMWNG", "collection_id": "01FCWK741N7GWYBVG4Z3N74V16" }, "response_collection": { "data": {}, "collection_id": "01FCWSMVWW7192SZXR9MP52B4A", "transaction_id": "01FCWSMNZM271WVQY6FDS2CB6M", "metadata": { "created_at": "2021-08-12T05:03:47.612771-04:00", "validation": false, "report_download_urls": { "voe_template": { "download_url": "https://dev-data-manager-blobs-bucket-us-east-1-873429376159.s3.amazonaws.com/01FJYAHNJR", "blob_id": "01FCWSAQD3QDKEW91K7CPXN4Y2", "status": "Succeeded" } } } }, "flows_responses": { "flow1": { "response_collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2", "invocation_id": "7a8980a1-73ac-4313-ada5-e0e976c38ebb", "invocation_status": "FAILED", "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7", "product_flow_name": "demo_product_flow_422", "failure_reason": "Service Connector failed. Connector flow failed. Response payload: {'Error': 'CallVendorError', 'Cause': {'errorMessage': '', 'errorType': 'CallVendorError'}}", "response_collection": { "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2", "data": {}, "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7", "metadata": { "created_at": "2021-08-12T04:58:15.331517-04:00", "validation": false } } }, "flow2": { "response_collection_id": "01FCWSMVWW7192SZXR9MP52B4A", "invocation_id": "c861def5-5e5d-4690-9313-2f25427029a8", "invocation_status": "COMPLETED", "transaction_id": "01FCWSMNZM271WVQY6FDS2CB6M", "product_flow_name": "demo_product_flow" }, "metadata": { "actual_flow_name": "flow2", "response_collection_id": "01FCWSMVWW7192SZXR9MP52B4A" } } } ``` application/json Copy Successfully returned status of the Product flow Invocation. ``` { "invocation_id": "fbc19f9b-1d37-4ced-9f1d-d2769b018b0a", "invocation_status": "FAILED", "request_collection_id": "01FCWK741N7GWYBVG4Z3N74V16", "callback_url": "https://webhook.site/68a4aa6a-bf18-4f7d-be7d-bc26503adeb2", "transaction_id": "01FCWK72GC1MFM5003SXJHMWNG", "failure_reason": "All product flows were failed.", "request_collection": { "data": { "foo": "bar", "biz": "baz" }, "metadata": { "created_at": "2021-08-12T03:11:25.749933-04:00", "validation": false }, "transaction_id": "01FCWK72GC1MFM5003SXJHMWNG", "collection_id": "01FCWK741N7GWYBVG4Z3N74V16" }, "response_collection": { "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2", "data": {}, "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7", "metadata": { "created_at": "2021-08-12T04:58:15.331517-04:00", "validation": false } }, "flows_responses": { "flow1": { "response_collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2", "invocation_id": "7a8980a1-73ac-4313-ada5-e0e976c38ebb", "invocation_status": "FAILED", "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7", "product_flow_name": "demo_product_flow_422", "failure_reason": "Service Connector failed. Connector flow failed. Response payload: {'Error': 'CallVendorError', 'Cause': {'errorMessage': '', 'errorType': 'CallVendorError'}}" } }, "metadata": { "actual_flow_name": "flow1" } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | Product flow invocation identifier | ##### Response `200``application/json` 13 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `request_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `response_collection_id` | `string` | Response Collection ID. | | `response_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `report_download_urls`required | `object` | Information about each generated report identified by template name. | | `callback_url` | `string` | URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished. | | `widget_url` | `string (uri)` | URL of the widget. | | `metadata` | `object` | Response Collection ID. | | `options` | `—` | Options that were passed to the flow invocation. | | `connector_job_id` | `string` | Connector job ID. | | `service_invocation`required | `object` | Includes underlying services invocation. | | `Connector` | `object` | Response from Connector service. | | `connector_flow_name` | `string` | Vendor flow name. | | `invocation_id` | `string (uuid)` | Connector job ID. | | `status` | `string` | Connector flow status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING` | | `Translator` | `object` | Response from Translator service about input and output translation. | | `input` | `object` | Input translation status. | | `language_name` | `string` | Input translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Input translation status.`COMPLETED``FAILED``RUNNING` | | `convert_input` | `object` | Convert input translation status. | | `language_name` | `string` | Input translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Input translation status.`COMPLETED``FAILED``RUNNING` | | `output` | `object` | Output translation status. | | `language_name` | `string` | Output translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Output translation status.`COMPLETE``FAILED``RUNNING` | | `convert_output` | `object` | Convert output translation status. | | `language_name` | `string` | Output translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Output translation status.`COMPLETE``FAILED``RUNNING` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Platform `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Request application/json Copy ``` { "label": "first_transaction", "callback_url": "https://webhook.site/0c1c4e00-79d9-490b-a0f3-bab8b12a61d5" } ``` ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` 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" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string (url)` | URL for receiving events about changes inside transaction | | `label` | `string` | Transaction label | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` Retrieve Transaction Collections returns the content of a given collection_id associated with a specific transaction_id. ##### Response 200400403404500 application/json Copy Transaction collection retrieved successfully ``` { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "Thomas", "last": "Alex" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "12345" } ] }, "roles": { "role": [ { "borrower": { "residences": { "residence": [ { "address": { "line_text": "street 101", "city": "example city", "state": "state", "postal_code": "1234", "street_name": "street 23" } } ] } } } ] } } ] } } ] } } ] } } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Transaction collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `array` | Collection data | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /get-collection ##### Request application/json Copy ``` { "data": { "organizations": [ { "has_organization_name": { "has_value": "Enterprise One" }, "@type": "organization", "@id": "01FD6ZNGNFKY3B7CX0YN6NH56E" } ], "contact_information": [ { "has_email_address": { "has_value": "test@test.com" }, "@type": "contact_information", "@id": "01FD6ZNGJW9X96WGWX2BD37CFY" } ], "addresses": [ { "has_address_line_1_text": { "has_value": "33 IRVING PLACE" }, "has_state_code": { "has_value": "NY" }, "@type": "address", "@id": "01FD6ZNGJADZ0RB1H96FSE8BAB", "has_country_name": { "has_value": "US" }, "has_address_line_2_text": { "has_value": "a" }, "has_postal_code": { "has_value": "10003" }, "has_city_name": { "has_value": "NEW YORK" } } ], "people": [ { "contact_at": [ "01FD6ZNGJW9X96WGWX2BD37CFY" ], "has_taxpayer_identifier_value": { "has_value": "666234390" }, "has_birth_date": { "has_value": "12/28/1958" }, "with_address": [ "01FD6ZNGJADZ0RB1H96FSE8BAB" ], "has_last_name": { "has_value": "Jackson" }, "@id": "01FD6ZKZD7WGZXYFGJBVPVP2Q5", "works_for": [ "01FD6ZNGNFKY3B7CX0YN6NH56E" ], "has_first_name": { "has_value": "John" } } ] } } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "data": {}, "metadata": {} } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collection data" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction ID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `people` | `object[]` | — | | `@id` | `string` | — | | `has_first_name` | `object` | — | | `has_value` | `string` | — | | `has_last_name` | `object` | — | | `has_value` | `string` | — | | `has_birth_date` | `object` | — | | `has_value` | `string` | — | | `has_taxpayer_identifier_value` | `object` | — | | `has_value` | `string` | — | | `with_address` | `string[]` | — | | `contact_at` | `string[]` | — | | `works_for` | `string[]` | — | | `addresses` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value` | `string` | — | | `has_address_line_2_text` | `object` | — | | `has_value` | `string` | — | | `has_city_name` | `object` | — | | `has_value` | `string` | — | | `has_state_code` | `object` | — | | `has_value` | `string` | — | | `has_postal_code` | `object` | — | | `has_value` | `string` | — | | `has_country_name` | `object` | — | | `has_value` | `string` | — | | `contact_information` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_email_address` | `object` | — | | `has_value` | `string` | — | | `organizations` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_organization_name` | `object` | — | | `has_value` | `string` | — | | `metadata` | `object` | Metadata of the collection | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `array` | Collection data | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 200 response_collection_example200 request_collection_example403404 GetCollectionError404 GetCollectionsError500 application/json Copy Successfully Retrieved Collection ``` { "data": { "credit_information": [ { "has_credit_report_identifier": { "has_value": "2-d0a38e38-1639-4493-8", "data_sourced_from": [ "01FCZHG9EGC306GQ34ZNZ36A67" ] }, "has_credit_request_data_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_frozen_status_experian_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_trans_union_indicator": { "has_value": "false" }, "has_data_version_equifax_identifier": { "has_value": "4" }, "@type": "credit_information", "has_credit_bureau_name": { "has_value": null }, "has_credit_rating_code_type": { "has_value": "equifax" }, "has_credit_report_merge_type": { "has_value": "list_and_stack" }, "has_credit_frozen_status_trans_union_indicator": { "has_value": "false" }, "has_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_credit_repository_included_equifax_indicator": { "has_value": "false" }, "has_credit_request_data_credit_repository_included_experian_indicator": { "has_value": "false" }, "has_requesting_party_name": { "has_value": null }, "has_credit_repository_included_trans_union_indicator": { "has_value": "true" }, "has_credit_report_first_issued_date": { "has_value": "2021-08-13" }, "@id": "01FCZHG9ED6FP1B3853716DDBJ", "has_credit_frozen_status_equifax_indicator": { "has_value": "false" }, "with_credit_score_information": [ "01FCZHG9EVWB7XSMY2VAK0QAJ1" ], "has_data_version_credmo_identifier": { "has_value": "1.3" } } ], "credit_score_information": [ { "has_credit_report_identifier": { "has_value": "2-d0a38e38-1639-4493-8", "data_sourced_from": [ "01FCZHG9EGC306GQ34ZNZ36A67" ] }, "has_credit_score_model_name_type_other_description": { "has_value": "TransUnionVantageScore3.0" }, "has_credit_score": { "has_value": "677", "data_sourced_from": [ "01FCZHG9EGC306GQ34ZNZ36A67" ] }, "has_credit_score_model_name_type": { "has_value": "Other" }, "with_credit_score_factor": [ [ "01FCZHG9G3Y586GW0QXYH9GEY1", "01FCZHG9G372Z31MSTBYD1RZRT", "01FCZHG9G3C36KNGA1WSY9KGSW", "01FCZHG9G30MEQG7RSHZTZD3RB", "01FCZHG9G30BENG7W0ERGN939G" ] ], "@type": "credit_score_information", "has_credit_score_facta_inquiries_indicator": { "has_value": "true" }, "has_credit_repository_source_type": { "has_value": "trans_union" }, "@id": "01FCZHG9EVWB7XSMY2VAK0QAJ1", "has_credit_score_date": { "has_value": "2015-06-09" } } ], "credit_score_factors": [ { "has_credit_score_factor_code": { "has_value": "63" }, "has_credit_score_factor_text": { "has_value": "Lack of sufficient relevant real estate account information" }, "@id": "01FCZHG9G3Y586GW0QXYH9GEY1", "@type": "credit_score_factor" }, { "has_credit_score_factor_code": { "has_value": "12" }, "has_credit_score_factor_text": { "has_value": "The date that you opened your oldest account is too recent" }, "@id": "01FCZHG9G372Z31MSTBYD1RZRT", "@type": "credit_score_factor" }, { "has_credit_score_factor_code": { "has_value": "14" }, "has_credit_score_factor_text": { "has_value": "Lack of sufficient credit history" }, "@id": "01FCZHG9G3C36KNGA1WSY9KGSW", "@type": "credit_score_factor" }, { "has_credit_score_factor_code": { "has_value": "30" }, "has_credit_score_factor_text": { "has_value": "Too few of your bankcard or other revolving accounts have high limits" }, "@id": "01FCZHG9G30MEQG7RSHZTZD3RB", "@type": "credit_score_factor" }, { "has_credit_score_factor_code": { "has_value": "I" }, "has_credit_score_factor_text": { "has_value": "Inquiries did impact the credit score" }, "@id": "01FCZHG9G30BENG7W0ERGN939G", "@type": "credit_score_factor" } ] } } ``` application/json Copy Successfully Retrieved Collection ``` { "data": { "organizations": [ { "has_organization_name": { "has_value": "Enterprise One" }, "@type": "organization", "@id": "01FD6ZNGNFKY3B7CX0YN6NH56E" } ], "contact_information": [ { "has_email_address": { "has_value": "test@test.com" }, "@type": "contact_information", "@id": "01FD6ZNGJW9X96WGWX2BD37CFY" } ], "addresses": [ { "has_address_line_1_text": { "has_value": "33 IRVING PLACE" }, "has_state_code": { "has_value": "NY" }, "@type": "address", "@id": "01FD6ZNGJADZ0RB1H96FSE8BAB", "has_country_name": { "has_value": "US" }, "has_address_line_2_text": { "has_value": "a" }, "has_postal_code": { "has_value": "10003" }, "has_city_name": { "has_value": "NEW YORK" } } ], "people": [ { "contact_at": [ "01FD6ZNGJW9X96WGWX2BD37CFY" ], "has_taxpayer_identifier_value": { "has_value": "666234390" }, "has_birth_date": { "has_value": "12/28/1958" }, "with_address": [ "01FD6ZNGJADZ0RB1H96FSE8BAB" ], "has_last_name": { "has_value": "Jackson" }, "@id": "01FD6ZKZD7WGZXYFGJBVPVP2Q5", "works_for": [ "01FD6ZNGNFKY3B7CX0YN6NH56E" ], "has_first_name": { "has_value": "John" } } ] } } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 2 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `people` | `object[]` | — | | `@id` | `string` | — | | `has_first_name` | `object` | — | | `has_value` | `string` | — | | `has_last_name` | `object` | — | | `has_value` | `string` | — | | `has_birth_date` | `object` | — | | `has_value` | `string` | — | | `has_taxpayer_identifier_value` | `object` | — | | `has_value` | `string` | — | | `with_address` | `string[]` | — | | `contact_at` | `string[]` | — | | `works_for` | `string[]` | — | | `addresses` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value` | `string` | — | | `has_address_line_2_text` | `object` | — | | `has_value` | `string` | — | | `has_city_name` | `object` | — | | `has_value` | `string` | — | | `has_state_code` | `object` | — | | `has_value` | `string` | — | | `has_postal_code` | `object` | — | | `has_value` | `string` | — | | `has_country_name` | `object` | — | | `has_value` | `string` | — | | `contact_information` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_email_address` | `object` | — | | `has_value` | `string` | — | | `organizations` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_organization_name` | `object` | — | | `has_value` | `string` | — | | `metadata` | `object` | Metadata of the collection | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` ### Encompass Input Adapter `POST` `/products/los-encompass-input-adapter/invocations` #### Invoke Input Adapter `invokeEncompassInputAdapter` You can invoke byte input adapters by using this endpoint. This endpoint takes customer_transaction_id from the partner. This should be the unique parameter to identify the loans. For input adapters, invocation responses are always transaction_id and collection_id. With using these two parameters, you can invoke the Staircase products. Adapters guarantee that the same transaction_id is used for each customer transaction_id. For each invocation adapters create transaction_id, request_collection_id and response_collection_id. Supported Staircase Products Flows - employment - income - assets - credit - data extraction - document classification - fees ##### Request InvokeEmploymentInputAdapterInvokeDocumentClassificationInputAdapterInvokeFeesInputAdapter application/json Copy ``` { "product_flow_name": "employment", "transaction_id": "01FK0TWGPYFVYA81ACDQY651CE", "request_data": { "loans": [ { "has_loan_identifier_value": { "has_value": "e8f84935-0384-4978-a5fb-aac7f3af987e" } } ] } } ``` application/json Copy ``` { "product_flow_name": "document-classification", "transaction_id": "01FK0TWGPYFVYA81ACDQY651CE", "request_data": { "loans": [ { "has_loan_identifier_value": { "has_value": "63d64559-0af1-42d1-9d7d-70a6ce4e27f3" } } ], "foreign_object": [ { "@type": "attachment", "has_foreign_object_identifier_value": { "has_value": "ed17561f-e5e3-4cf5-abf3-bbb5fb931e82" } } ] } } ``` application/json Copy ``` { "product_flow_name": "fees", "transaction_id": "01FK0TWGPYFVYA81ACDQY651CE", "request_data": { "loans": [ { "has_loan_identifier_value": { "has_value": "63d64559-0af1-42d1-9d7d-70a6ce4e27f3" } } ], "foreign_object": [ { "@type": "attachment", "has_foreign_object_identifier_value": { "has_value": "ed17561f-e5e3-4cf5-abf3-bbb5fb931e82" }, "has_object_name": { "has_value": "conveyance_deed" } }, { "@type": "attachment", "has_foreign_object_identifier_value": { "has_value": "ed17561f-e5e3-4cf5-abf3-aac7f3af987e" }, "has_object_name": { "has_value": "note" } } ] } } ``` ##### Response 201400403500 application/json Copy Create Adapter API Triggered Successfully ``` { "invocation_id": "01FDYNKEP7DRV8HAE4X6J580NP" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Staircase Transaction ID used for invocation | | `product_flow_name` | `string` | Supported Staircase Product Name`assets``credit``data-extraction``document-classification``employment``fees``income` | | `request_data` | `object` | Encompass Input Adapter Request Schema | | `loans` | `object[]` | Loans | | `@type` | `string` | Loan ID | | `has_loan_identifier_value` | `object` | Encompass Loan ID | | `has_value` | `string` | Encompass Loan ID Value | | `foreign_object` | `object[]` | Foreign Objects | | `@type` | `string` | Attachment | | `has_foreign_object_identifier_value` | `object` | Encompass Document Attachment ID. Only use in Document related products | | `has_value` | `string` | Encompass Document Attachment ID Value | | `has_object_name` | `object` | Encompass Document Type (conveyance_deed or note). Required for Fees product | | `has_value` | `string` | Encompass Document Type Value | ##### Response `201``application/json` 1 fields Create Adapter API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/products/los-encompass-input-adapter/invocations/{invocation_id}` #### Retrieve Adapter Invocation Response `getEncompassInputAdapterInvocationResponse` Retrieve Encompass Adapter Invocation Response Retrieves Invocation Response ##### Response 201400403 application/json Copy Successfully started flow invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "invocation_status": "STARTED", "product_flow_name": "credit", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `invocation_id` required | `string (ulid)` path | `01FEK8V6RT027SRAW903G97DPF` | Invocation ID | ##### Response `201``application/json` 9 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Encompass Output Adapter `POST` `/products/los-encompass-output-adapter/invocations` #### Invoke Output Adapter `invokeEncompassOutputAdapter` Output adapters are used to receive output from a technology partner and return it to the LOS or POS. When the technology partner completes a request, it sends the response to Staircase APIs. Staircase APIs translate and persist the response, then forward it to the LOS/POS. #### Prerequisite ##### Set up Encompass credentials Call Setup Encompass Credentials to store your Encompass credentials for adapters use. Show the rest #### Usage You can send a request in two different ways: - Using `request_data`: If you provide this parameter, flow invocation would use the data here as input. If you also provide a `transaction_id` in the request body, Response Collection would be created in the related Transaction object. If you don't provide a `transaction_id` we will automatically create a Transaction for you and Response Collection would be created in this new Transaction as well. - Using `transaction_id` and `request_collection_id`: If you already have a request collection, you can provide its details using these two parameters. Note that in this case Response Collection would be created in the provided Transaction. #### Retrieving the Invocation Result After invocation, endpoint returns an `invocation_id` which you can poll for its status using Retrieve Invocation Response endpoint. Once the invocation is completed, the Response Collection is populated with these search results. If you would rather receive a callback once the invocation is completed instead of polling it, you can set `callback_url` parameter in the request body. #### Supported Staircase Products Flows - `preapproval` - `employment` - `document classification` - `fees` #### Encompass Preapproval Output Adapter Encompass Preapproval Output Adapter takes staircase collection as an input and converts it to encompass loan object. In examples, you can find sample data that you can use to create a loan. When the process is completed successfully, the adapter will create the loan under the "pipeline" loan folder. In response collection data, you will find loan identifier and loan case number. ##### Request Preapproval Output Adapter Request Payload ExampleInvokeEmploymentOutputAdapterInvokeDocumentClassificationOutputAdapterStaircase Lexicon Example Collection application/json Copy ``` { "product_flow_name": "preapproval", "transaction_id": "01FTG980NW4C0S8YX12Z7E3WZ6", "request_collection_id": "01FTG981VT214W97Y9NGSYA9JQ" } ``` application/json Copy ``` { "product_flow_name": "employment", "request_collection_id": "01FK0TY3FRH7P6WJCETM5HTW7V", "options": { "customer_transaction_id": "746edd67-dedd-480b-a94a-c17080c920d7" } } ``` application/json Copy ``` { "product_flow_name": "document-classification", "request_collection_id": "01FK0TY3FRH7P6WJCETM5HTW7V", "options": { "customer_transaction_id": "746edd67-dedd-480b-a94a-c17080c920d7", "customer_document_id": "0a88a069-731e-4869-b160-1f7f1912d3ce", "customer_doc_type": "IRS W-2" } } ``` application/json Copy ``` { "metadata": { "version": 2, "validation": false }, "data": { "addresses": [ { "@id": "01FT93F8YJ2VXJBWPAF4PPWK1B", "@type": "residential_address", "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_address_line_1_text": { "has_value": "126 4TH ST" }, "has_city_name": { "has_value": "Texas" }, "has_postal_code": { "has_value": "30014" } }, { "@id": "01FT93ETM2HZXV86F2E7VJ0A4P", "@type": "residential_address", "has_address_line_1_text": { "has_value": "126 4TH ST" }, "has_city_name": { "has_value": "ATLANTA" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } }, { "@id": "01FT93DZJQYP1J2C6XBJZNM1BW", "@type": "address", "has_address_line_1_text": { "has_value": "126 4th St" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Atlanta" }, "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } }, { "@id": "01FT93DZJQYP1J2C6XBJZNTEST", "@type": "address", "has_address_line_1_text": { "has_value": "126 4th St" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Atlanta" }, "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } } ], "arm_adjustments": [ { "@id": "01FT93F8YHHE8ZGJBKYF9JC422", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": "60" } } ], "assets": [ { "@id": "01FT93E928K563KRN8VDGC6PT6", "@type": "checking_account", "has_market_value_amount": { "has_value": 10000 }, "has_account_identifier": { "has_value": "1523421245" }, "held_by_financial_institution": [ "01FS2DZ9F8QXS2QA8NQ675TJA9" ], "owned_by": [ "01FT93DZJQGV9JJZV0RWHS8PK6" ] }, { "@id": "01FT93E928K563KRN8VDGC6PT7", "@type": "checking_account", "has_market_value_amount": { "has_value": 20000 }, "has_account_identifier": { "has_value": "1523421245" }, "held_by_financial_institution": [ "01FS2DZ9F8QXS2QA8NQ675TJA9" ], "owned_by": [ "01FT93DZJQGV9JJZV0RWHS8PK6" ] } ], "automated_underwriting": [ { "@id": "01FT93F8YHVSSQPWW8KBQYP04J", "@type": "automated_underwriting" } ], "buydowns": [ { "@id": "01FT93F8YHXJKVS06NEYEBBGT3", "@type": "buydown", "has_buydown_type": { "has_value": "one_zero" } } ], "contact_information": [ { "@id": "01FT93DZJQDE98K6BT0HDX52PD", "@type": "contact_information", "has_email_address": { "has_value": "test@email.com" }, "has_phone_number": { "has_value": "1231231232" } } ], "credit_information": [ { "@id": "01FT93ETHH63K1X8MG3QSWW4KM", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-01-25" }, "has_credit_report_identifier": { "has_value": "DEVWM6" }, "has_credit_report_last_updated_date": { "has_value": "2022-01-25" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "with_credit_score_information": [ "01FT93ETMMKVN9BPR713GEWME0" ] } ], "credit_score_factors": [ { "@type": "credit_score_factor" }, { "@type": "credit_score_factor" } ], "credit_score_information": [ { "@id": "01FT93ETMMKVN9BPR713GEWME0", "@type": "credit_score_information", "has_credit_report_identifier": { "has_value": "DEVWM6" }, "has_credit_score": { "has_value": "00660" } } ], "declarations": [ { "@id": "01FT93DZJQ65ZSBDCBBA7DN6X4", "@type": "declarations", "has_bankruptcy_indicator": { "has_value": false }, "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_intent_to_occupy_indicator": { "has_value": true } } ], "employment": [ { "@id": "01FT93DZJRDQ78KW9J9GKM5H4G", "@type": "employment", "has_current_employment_indicator": { "has_value": "True" }, "has_self_employment_indicator": { "has_value": true }, "has_employment_start_date": { "has_value": "2008-04-15" }, "has_employment_classification_type": { "has_value": "secondary" }, "has_employment_position_description": { "has_value": "Software Engineer" }, "has_employment_monthly_income_amount": { "has_value": 15000 }, "has_ownership_interest_type": { "has_value": "greater_than_or_equal_to_25_percent" }, "has_special_borrower_employer_relationship_indicator": { "has_value": false }, "has_time_in_line_of_work_months_count": { "has_value": 132 }, "provided_by": [ "01FT93DZJQNEP4GAQXGGGTTPXG" ] } ], "housing_expenses": [ { "@id": "01FT93DZJQ6WWC8B513W0PMTDE", "@type": "housing_expenses", "has_present_first_mortgage_principal_and_interest_monthly_amount": { "has_value": 0 }, "has_present_first_mortgage_principal_interest_taxes_and_insurance_piti_monthly_amount": { "has_value": 0 }, "has_present_flood_insurance_monthly_amount": { "has_value": 0 }, "has_present_homeowners_association_dues_and_condominium_fees_monthly_amount": { "has_value": 0 }, "has_present_homeowners_insurance_monthly_amount": { "has_value": 0 }, "has_present_mortgage_insurance_monthly_amount": { "has_value": 0 }, "has_present_other_mortgage_loan_principal_and_interest_monthly_amount": { "has_value": 0 }, "has_present_other_mortgage_loan_principal_interest_taxes_and_insurance_monthly_amount": { "has_value": 0 }, "has_present_property_tax_monthly_amount": { "has_value": 0 }, "has_present_supplemental_property_insurance_monthly_amount": { "has_value": 0 }, "has_present_total_monthly_payment_amount": { "has_value": 0 } } ], "income": [ { "@_label": "incomes", "@id": "01FTDVFEFEHM2MBZ9BF0NQWJP7", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 40000 }, "has_income_amount": { "has_value": 100000 }, "has_income_year": { "has_value": 2021 }, "has_net_income_amount": { "has_value": 66500 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "incomes", "@id": "01FTDVFEFEQFY10AZVTY1PCPAD", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 40000 }, "has_income_amount": { "has_value": 100000 }, "has_income_year": { "has_value": 2020 }, "has_net_income_amount": { "has_value": 66500 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "incomes", "@id": "01FTDVFEFEG6E9HHZEFSRE95MW", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 30000 }, "has_income_amount": { "has_value": 85000 }, "has_income_year": { "has_value": 2019 }, "has_net_income_amount": { "has_value": 56525 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGVM8AV0NJSDA33S3GP", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGVSVRV5XNR6PPZVVNJ", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWCWVKNJQ557E8TY7N", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 20000 }, "has_net_income_amount": { "has_value": 9975 }, "has_base_income_amount": { "has_value": 5000 }, "has_income_pay_date": { "has_value": "27-01-2022" }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWCWMA6HR67C7EV9YY", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWF33EA7RX4WS0VN9X", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGW923Z4WF7G5F5T49G", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGW3CN37DQKYVPAA56G", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWT5C5V2JT8D63P5JD", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWH8GFQR1BT1M31PZQ", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWMX5D6XHJ1FFB6E8P", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGW4E07YKNTMHZVJ013", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWX4BWDKFYGYJZMKXD", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGW5FG0B4SQWHFDJJBY", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWP6RNCEMF18CCBR0V", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGWD4E9PM9WW90CV9FP", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGX99MPQK453AR7QWXH", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXEJ6TBG188XR70XEN", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXS33610PXGVRDFVR2", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXQ2MV68EYDDDQX9NA", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGX4J6CS19FY4ASEZSK", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXV6ED2KJEQ8PH4DRA", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXGZ51M0GSKB9P5J4N", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" } }, { "@_label": "paystubs", "@id": "01FTDVFEGXD57CF7NKSX37HRX3", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXMTBBPZ1YABPEXX2S", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXZ47C2SQF4P9C53JM", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGXB6G4N8XJX79BRMHW", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" } }, { "@_label": "paystubs", "@id": "01FTDVFEGXQ6KQQSX738GP5DJF", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGYZEC5VXV9CV82N7P6", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGYVV1D5M005DQ7H8Q8", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGY2599ZE5XJN4VRH2D", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGY9ARMVNM184ARPBCQ", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGYAV79WMACMQC9QM65", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGYTN382MZ7RG3CHTXJ", "@type": "employment_income", "has_bonus_income_amount": { "has_value": 10000 }, "has_income_amount": { "has_value": 15000 }, "has_net_income_amount": { "has_value": 9975 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGY35VDA7782QKWV0R9", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] }, { "@_label": "paystubs", "@id": "01FTDVFEGYEDJXNCKRKHZA0AQW", "@type": "employment_income", "has_income_amount": { "has_value": 5000 }, "has_net_income_amount": { "has_value": 3325 }, "has_income_pay_frequency_type": { "has_value": "monthly" }, "earned_from": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] } ], "insurance": [ { "@id": "01FT93F8YJYWS7TJ7SWS9903NF", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "liabilities": [ { "@id": "01FT93DZJQ5SFFBXVWCHFEJ468", "@type": "liability", "has_liability_payment_amount": { "has_value": 2000 }, "has_liability_unpaid_balance_amount": { "has_value": 2000 } } ], "loan_documentation": [ { "@id": "01FT93F8YJ23KFZ56PW2TYFT1M", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FT93F8YJWBRPGH181JNHS2Q7", "@type": "loan_summary", "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 660 }, "has_total_debt_expense_to_income_dti_ratio": { "has_value": 25 }, "has_total_monthly_income_amount": { "has_value": 8125 } } ], "loan_terms": [ { "@id": "01FT93F8YHDQ7M6KNRFE7A1JQR", "@type": "loan_terms", "has_base_loan_amount": { "has_value": 15000 }, "has_buydown_indicator": { "has_value": true }, "has_construction_loan_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": "True" }, "has_interest_only_indicator": { "has_value": false }, "has_lien_position_type": { "has_value": "first_lien" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_pledged_assets_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_refinance_type": { "has_value": "no_cash_out" } } ], "loans": [ { "@id": "01FT93DZJRD06E7VC5SK08M9X2", "@type": "loan", "has_loan_role_type": { "has_value": "subject_loan" }, "has_loan_status_type": { "has_value": "prequalification" }, "has_mortgage_type": { "has_value": "conventional" }, "has_originator_loan_identifier": { "has_value": "01FT93DYZG12384RHJBP2RKHSG" }, "has_relocation_loan_indicator": { "has_value": false }, "secured_by_property": [ "01FT93F8YJ1AHDYXEBN803KM2M" ], "serviced_by": [ "01FT93F8YJV09Z71WCV6F9E33H" ], "with_arm_adjustment": [ "01FT93F8YHHE8ZGJBKYF9JC422" ], "with_automated_underwriting": [ "01FT93F8YHVSSQPWW8KBQYP04J" ], "with_borrower": [ "01FT93DZJQGV9JJZV0RWHS8PK6" ], "with_buydown": [ "01FT93F8YHXJKVS06NEYEBBGT3" ], "with_documentation": [ "01FT93F8YJ23KFZ56PW2TYFT1M" ], "with_insurance": [ "01FT93F8YJYWS7TJ7SWS9903NF" ], "with_loan_terms": [ "01FT93F8YHDQ7M6KNRFE7A1JQR" ], "with_quote_request": [ "01FT93F8YJFHVYEM9MYHQ3RB5J" ], "with_summary": [ "01FT93F8YJWBRPGH181JNHS2Q7" ] } ], "mortgage_products": [ { "@id": "01FT93F8YJHD220HNMAWJS4EZB", "@type": "pricing", "has_partner_name": { "has_value": "Optimal Blue" } }, { "@id": "01FT93F8YJSR6NR90J310GR0KQ", "@type": "automated_underwriting_system", "has_credit_report_vendor_identifier": { "has_value": "" } }, { "@id": "01FT93ETGV4ZTNE2753H4E87F3", "@type": "credit" } ], "organizations": [ { "@id": "01FT93F8YJV09Z71WCV6F9E33H", "@type": "servicer" }, { "@id": "01FT93DZJQNEP4GAQXGGGTTPXG", "@type": "organization", "has_organization_name": { "has_value": "Amazon" }, "with_address": [ "01FT93DZJQYP1J2C6XBJZNTEST" ] }, { "@id": "01FT93DZJQKRNR64A20R2H9C0W", "@type": "customer", "has_transaction_identifier": { "has_value": "01FT93DYZG12384RHJBP2RKHSG" } }, { "@id": "01FS2DZ9F8QXS2QA8NQ675TJA9", "@type": "financial_institution", "has_organization_name": { "has_value": "BankA" } } ], "people": [ { "@id": "01FT93DZJQGV9JJZV0RWHS8PK6", "@type": "borrower", "contact_at": [ "01FT93DZJQDE98K6BT0HDX52PD" ], "earns": [ "01FTDVFEFEHM2MBZ9BF0NQWJP7", "01FTDVFEFEQFY10AZVTY1PCPAD", "01FTDVFEFEG6E9HHZEFSRE95MW", "01FTDVFEGVM8AV0NJSDA33S3GP", "01FTDVFEGVSVRV5XNR6PPZVVNJ", "01FTDVFEGWCWVKNJQ557E8TY7N", "01FTDVFEGWCWMA6HR67C7EV9YY", "01FTDVFEGWF33EA7RX4WS0VN9X", "01FTDVFEGW923Z4WF7G5F5T49G", "01FTDVFEGW3CN37DQKYVPAA56G", "01FTDVFEGWT5C5V2JT8D63P5JD", "01FTDVFEGWH8GFQR1BT1M31PZQ", "01FTDVFEGWMX5D6XHJ1FFB6E8P", "01FTDVFEGW4E07YKNTMHZVJ013", "01FTDVFEGWX4BWDKFYGYJZMKXD", "01FTDVFEGW5FG0B4SQWHFDJJBY", "01FTDVFEGWP6RNCEMF18CCBR0V", "01FTDVFEGWD4E9PM9WW90CV9FP", "01FTDVFEGX99MPQK453AR7QWXH", "01FTDVFEGXEJ6TBG188XR70XEN", "01FTDVFEGXS33610PXGVRDFVR2", "01FTDVFEGXQ2MV68EYDDDQX9NA", "01FTDVFEGX4J6CS19FY4ASEZSK", "01FTDVFEGXV6ED2KJEQ8PH4DRA", "01FTDVFEGXGZ51M0GSKB9P5J4N", "01FTDVFEGXD57CF7NKSX37HRX3", "01FTDVFEGXMTBBPZ1YABPEXX2S", "01FTDVFEGXZ47C2SQF4P9C53JM", "01FTDVFEGXB6G4N8XJX79BRMHW", "01FTDVFEGXQ6KQQSX738GP5DJF", "01FTDVFEGYZEC5VXV9CV82N7P6", "01FTDVFEGYVV1D5M005DQ7H8Q8", "01FTDVFEGY2599ZE5XJN4VRH2D", "01FTDVFEGY9ARMVNM184ARPBCQ", "01FTDVFEGYAV79WMACMQC9QM65", "01FTDVFEGYTN382MZ7RG3CHTXJ", "01FTDVFEGY35VDA7782QKWV0R9", "01FTDVFEGYEDJXNCKRKHZA0AQW" ], "has_birth_date": { "has_value": "1958-12-12" }, "has_first_name": { "has_value": "Frodo" }, "has_last_name": { "has_value": "Baggins" }, "has_marital_status_type": { "has_value": "unmarried" }, "has_taxpayer_identifier_type": { "has_value": "individual_taxpayer_identification_number" }, "has_taxpayer_identifier_value": { "has_value": "999008881" }, "lives_at": [ "01FT93DZJQ5E5QHAKC2NJMZ0ZM" ], "owes_liability": [ "01FT93DZJQ5SFFBXVWCHFEJ468" ], "owns_asset": [ "01FT93E928K563KRN8VDGC6PT6", "01FT93E928K563KRN8VDGC6PT7" ], "with_address": [ "01FT93DZJQYP1J2C6XBJZNM1BW" ], "with_credit_information": [ "01FT93ETHH63K1X8MG3QSWW4KM" ], "with_declarations": [ "01FT93DZJQ65ZSBDCBBA7DN6X4" ], "with_housing_expenses": [ "01FT93DZJQ6WWC8B513W0PMTDE" ], "works_for": [ "01FT93DZJQNEP4GAQXGGGTTPXG" ], "employed_as": [ "01FT93DZJRDQ78KW9J9GKM5H4G" ] } ], "properties": [ { "@id": "01FT93F8YJ1AHDYXEBN803KM2M", "@type": "subject_property", "has_financed_unit_count": { "has_value": 1 }, "has_in_project_indicator": { "has_value": false }, "has_manufactured_home_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_number_of_units_type": { "has_value": "one" }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_project_design_type": { "has_value": "midrise" }, "has_project_type": { "has_value": "condominium" }, "has_project_usage_type": { "has_value": false }, "has_property_usage_type": { "has_value": "primary_residence" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FT93F8YJ2VXJBWPAF4PPWK1B" ], "with_sales_contract": [ "01FT93F8YJNBJX6VCEED94ZFCR" ], "with_value": [ "01FT93F8YJCQG6R0D3Y7P74C6F" ] } ], "property_valuations": [ { "@id": "01FT93F8YJCQG6R0D3Y7P74C6F", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 200000 } } ], "quote_amortization_terms": [ { "@id": "01FT93F8YJ1DKRB33X4C9SCHWQ", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": "360" } } ], "quote_requests": [ { "@id": "01FT93F8YJFHVYEM9MYHQ3RB5J", "@type": "loan_price_quote_request", "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": "False" }, "has_include_ballon_loans_indicator": { "has_value": "False" }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": "True" }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": "False" }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "include_loans_with_amortization_term": [ "01FT93F8YJ1DKRB33X4C9SCHWQ" ] } ], "residences": [ { "@id": "01FT93DZJQ5E5QHAKC2NJMZ0ZM", "@type": "residence", "has_borrower_residency_type": { "has_value": "current" }, "has_residency_basis_type": { "has_value": "living_rent_free" }, "has_residency_duration_months_count": { "has_value": 30 }, "with_address": [ "01FT93DZJQYP1J2C6XBJZNM1BW" ] } ], "sales_contracts": [ { "@id": "01FT93F8YJNBJX6VCEED94ZFCR", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 200000 } } ] } } ``` ##### Response 201400403500 application/json Copy Create Adapter API Triggered Successfully ``` { "invocation_id": "01FDYNKEP7DRV8HAE4X6J580NP" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Staircase Transaction ID used for invocation | | `request_collection_id` | `string` | Output collection of Staircase product | | `product_flow_name` | `string` | Supported Staircase Product Name`document-classification``employment``fees``preapproval` | | `options` | `object` | Request Collection Data | | `customer_transaction_id` | `string` | Encompass Loan ID | | `customer_document_id` | `string` | Encompass Document ID. Only use in Document related products | | `customer_doc_type` | `string` | Encompass Document Type. Only use in Document related products | ##### Response `201``application/json` 1 fields Create Adapter API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/products/los-encompass-output-adapter/invocations/{invocation_id}` #### Retrieve Invocation Response `getEncompassOutputAdapterInvocationResponse` Retrieves Invocation Response ##### Response 201 Example201 Preapproval Product Flow Complete Response Example400403 application/json Copy Successfully started flow invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "invocation_status": "STARTED", "product_flow_name": "credit", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK" } ``` application/json Copy Successfully started flow invocation. ``` { "connector_job_id": "e5ce2145-61b3-4fb4-89b8-9ce7f722e3f9", "invocation_id": "3e475ba5-2e1f-4f1b-a39b-54a8e70249eb", "invocation_status": "COMPLETED", "product_flow_name": "preapproval", "request_collection_id": "01FTGERYJ41RF4TFE9E9ER9EH6", "response_collection": { "collection_id": "01FTGES37P2W9QK2HBA9CRRAXG", "data": { "loan_identifiers": [ { "@id": "01FTGET8G3F0GYNH1CKNAHGYTC", "@type": "loan_identifier", "has_loan_identifier_other_desctiption": { "has_value": "encompass" }, "has_loan_identifier_type": { "has_value": "lender_loan" }, "has_loan_identifier_value": { "has_value": "adb0479a-3e41-4b82-8380-b356bcf3c33d" } }, { "@id": "01FTGET8G6FMQ2WS2HMF3HTTSS", "@type": "loan_identifier", "has_loan_identifier_other_desctiption": { "has_value": "encompass" }, "has_loan_identifier_type": { "has_value": "lender_case" }, "has_loan_identifier_value": { "has_value": "TEST220100423" } } ] }, "metadata": { "created_at": "2022-01-28T08:42:44.215009-05:00", "invocation_status": "COMPLETED", "last_updated_at": "2022-01-28T08:43:31.553466-05:00", "partner_language": "encompass-to-lexicon-output-adapter", "service_invocation": { "Connector": { "connector_flow_name": "create_or_update_loan", "invocation_id": "e5ce2145-61b3-4fb4-89b8-9ce7f722e3f9", "status": "COMPLETED" }, "Translator": { "output": { "invocation_id": "3bb1b3eb-fcdb-4802-ae16-039e51927fb1", "language_name": "encompass-to-lexicon-output-adapter", "status": "COMPLETED" } } }, "staircase_language_version": 0, "validation": false, "version": 0 }, "transaction_id": "01FTGERXD9JVQQ09KP4GQNZWF9" }, "response_collection_id": "01FTGES37P2W9QK2HBA9CRRAXG", "service_invocation": { "Connector": { "connector_flow_name": "create_or_update_loan", "invocation_id": "e5ce2145-61b3-4fb4-89b8-9ce7f722e3f9", "status": "COMPLETED" }, "Translator": { "output": { "invocation_id": "3bb1b3eb-fcdb-4802-ae16-039e51927fb1", "language_name": "encompass-to-lexicon-output-adapter", "status": "COMPLETED" } } }, "transaction_id": "01FTGERXD9JVQQ09KP4GQNZWF9" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `invocation_id` required | `string (ulid)` path | `01FEK8V6RT027SRAW903G97DPF` | Invocation ID | ##### Response `201``application/json` 9 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Encompass Service Application `POST` `/products/los-encompass-service-application/invocations` #### Service Application `invokeEncompassServiceApplicationPP` This is a product component invocation endpoint. You can use service application features with this endpoint. What you need to do is provide an input to the invocation with `request_data` and specify the feature of the product component with `product_flow_name` that you want to use. This product component has two different flows. You can get detailed information about the services provided by staircase in EPC with `get_services`, or with `process_transaction`, you can process your EPC transaction with the staircase product of your choice and inject your processed data into Encompass. Show the rest After you invoke product component, product will create transaction, and request-response collections from the request_data you provided. #### Staircase Glossary Transaction: What is a transaction? When do I create a transaction? Collection: What is a collection? #### Retrieving the Invocation Result After invocation, endpoint returns an `invocation_id` which you can poll for its status using Retrieve Invocation Response endpoint. Once the invocation is completed, the Response Collection is populated with these search results. If you would rather receive a callback once the invocation is completed instead of polling it, you can set `callback_url` parameter in the request body. ##### How Callbacks are working? `callback_url` is used by the product to send a callback, when the flow invocation status changes, including changes in status of underlying services invocation. Invocation data is included throughout the invocation. Either response payload or failure reason is sent when invocation completed/failed. ##### How you can validate the callback messages? Each work unit (invocation) is represented with three distinct ID. - Transaction - Request Collection ID - Response Collection ID Combination of these three id can be used for validating callback messages related with invocation. You will retrieve these ids in the request body of callback payload. You can find the callback sample messages response examples. #### Process Transaction ! Prerequisite (Setup EPC Credentials): If you want to use Staircase credentials by default, you don't need to do anything. But if you want to use Staircase LOS Adapter as your EPC Integration backend, you need to set your EPC credentials `Process Transaction` flow allows you to process Encompass EPC transactions. Flow is doing following items after during invocation: 1. Extracts transaction data. 1. Converts transaction data to Staircase Lexicon. 1. Invokes the Staircase product 1. After the invocation is completed, the results are sent to Encompass and the transaction is complete. ##### How to create EPC transaction with using Encompass Partner JS API ! When creating a transaction with the Encompass Partner JS API, you should add three important information to request.options. - applicationId: Application ID field - borrowerType: Type of borrower (borrower or coborrower) - employmentId: Employment ID field - updateLoan: Flag for service application to update the loan after verification - uploadStaircaseReport: Flag for service application to upload the verification report generated by Staircase - uploadPartnerReport: Flag for service application to upload the verification report generated by the partner (if exists) Check EPC Transaction Management Developer Guide to create transaction Check below code to create EPC Transaction with Encompass Partner JS API ``` import host from '@elliemae/em-ssf-guest' ... let transactionRequest = { request: { type: 'NEW_REQUEST', options: { applicationId: "", borrowerType: "borrower", employmentId: "", updateLoan: true, uploadStaircaseReport: true, uploadPartnerReport: true } } } async function createTransaction(transactionRequest) { try { const transactionObject = await host.getObject('transaction') const transactionData = await transactionObject.create(transactionRequest) applicationState.transactionId = transactionData.id } catch (error) { console.log({error}) } } createTransaction(transactionRequest) ``` ! A single verification can be triggered with a single invocation. ##### Working with webhooks If you are using the EPC webhook integration, you will get an event like below when you create the transaction. If you want to process the transaction in Staircase Service Application, you can find the epc transaction in the $.meta.resourceId path in the incoming message. ``` { "eventTime" : "2020-05-02T11:08:52Z", "eventType" : "created", "meta" : { "resourceType" : "urn:elli:epc:transaction", "resourceId" : "{{EPC_TRANSACTION_ID}}", "instanceId" : "{{PRODUCT_NAME}}", "resourceRef" : "" } } ``` ##### Map your EPC Transaction to request data ``` { "organizations": [ { "@type": "customer", "@id": "01FD6ZNGJADZ0RB1H96FSE8ABC", "has_transaction_identifier": { "has_value": "{{EPC_TRANSACTION_ID}}" } } ], "staircase_products": [ { "@type": "staircase_product", "@id": "AB2D6ZNGJADZ0RB1H96FSE8FTG", "has_product_name": { "has_value": "income" } } ] } ``` ##### Updated entitlements after successful application run ###### Verification of Employment - Start Date - End Date - Start Date - Position Description ###### Verification of Income - Base Pay Amount - Overtime Amount - Bonus Amount - Commissions Amount ##### Verification of Asset (VoD) - Holder Name - Type - Account Identifier - Cash Or Market Value Amount - Depository Account Name #### Get Services It provides the partner services and details that Staircase offers within the encompass system. #### Please check the links below to get detailed information about Staircase Encompass EPC Integration - See how Staircase verification APIs can be embedded within Encompass to aggregate data from multiple best-in-class partners, to fully over all data needed to underwrite Staircase APIs/Encompass Integration Use Case - How to configure and call Staircase services in Encompass Staircase APIs/Encompass Integration Quick Start Guide ##### Request Get ServicesProcess Transaction application/json Copy ``` { "product_flow_name": "get_services", "request_data": {} } ``` application/json Copy ``` { "product_flow_name": "process_transaction", "request_data": { "organizations": [ { "@type": "customer", "@id": "01FD6ZNGJADZ0RB1H96FSE8ABC", "has_transaction_identifier": { "has_value": "25613a9c-8d08-40fe-bdac-6eea58794d1d" } } ], "staircase_products": [ { "@type": "staircase_product", "@id": "AB2D6ZNGJADZ0RB1H96FSE8FEW", "has_product_name": { "has_value": "income" } } ] } } ``` ##### Response 201 InvokeAdapterResp201 Callback flow started example201 Callback flow running example201 Callback flow completed example201 Callback flow failed example400403500 application/json Copy Create Invocation Triggered Successfully ``` { "invocation_id": "01FDYNKEP7DRV8HAE4X6J580NP" } ``` application/json Copy Create Invocation Triggered Successfully ``` { "invocation_id": "5025ade0-709d-443d-9307-c05ea0a92c02", "invocation_status": "STARTED", "transaction_id": "01G10A1WJ1E610MH0AC3QE16W6", "request_collection_id": "01G10A1WSYCSR8F9Y1G7HYHEBS", "response_collection_id": "01G10A1WWADH75MTDT0DSC0KZW", "service_invocation": {}, "data": { "organizations": [ { "@type": "customer", "has_transaction_identifier": { "has_value": "25613a9c-8d08-40fe-bdac-6eea58794d1d" } } ], "staircase_products": [ { "@type": "staircase_product", "has_product_name": { "has_value": "employment" } } ] } } ``` application/json Copy Create Invocation Triggered Successfully ``` { "invocation_id": "28ab302d-d146-4c3d-94ae-91f7f373be2b", "invocation_status": "RUNNING", "transaction_id": "01G10A9WZH3S31WM8DFK68GT0T", "request_collection_id": "01G10A9X8HM7QR51HJH6F964G8", "response_collection_id": "01G10A9XB8CBCPQA58Z7ZT1GXP", "service_invocation": { "Connector": { "connector_flow_name": "process_transaction", "invocation_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "status": "RUNNING" } }, "connector_job_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "data": { "organizations": [ { "@type": "customer", "has_transaction_identifier": { "has_value": "b51b9d92-2d0e-482a-9504-42d41cce1fa0" } } ], "staircase_products": [ { "@type": "staircase_product", "has_product_name": { "has_value": "employment" } } ] } } ``` application/json Copy Create Invocation Triggered Successfully ``` { "invocation_id": "28ab302d-d146-4c3d-94ae-91f7f373be2b", "invocation_status": "COMPLETED", "transaction_id": "01G10A9WZH3S31WM8DFK68GT0T", "request_collection_id": "01G10A9X8HM7QR51HJH6F964G8", "response_collection_id": "01G10A9XB8CBCPQA58Z7ZT1GXP", "service_invocation": { "Connector": { "status": "COMPLETED", "invocation_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "connector_flow_name": "process_transaction" } }, "connector_job_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "response_data": { "message": "EPC Transaction Completed." }, "data": { "organizations": [ { "@type": "customer", "has_transaction_identifier": { "has_value": "b51b9d92-2d0e-482a-9504-42d41cce1fa0" } } ], "staircase_products": [ { "@type": "staircase_product", "has_product_name": { "has_value": "employment" } } ] } } ``` application/json Copy Create Invocation Triggered Successfully ``` { "invocation_id": "28ab302d-d146-4c3d-94ae-91f7f373be2b", "invocation_status": "FAILED", "transaction_id": "01G10A9WZH3S31WM8DFK68GT0T", "request_collection_id": "01G10A9X8HM7QR51HJH6F964G8", "response_collection_id": "01G10A9XB8CBCPQA58Z7ZT1GXP", "product_flow_name": "process_transaction", "service_invocation": { "Connector": { "status": "FAILED", "invocation_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "connector_flow_name": "process_transaction" } }, "connector_job_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "failure_reason": "Failure reason message" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `request_data` | `object` | Empty Object | | `organizations` | `object[]` | Organizations Array | | `@type` | `string` | Organization's Type`customer` | | `@id` | `string` | Object's ID | | `has_transaction_identifier` | `object` | EPC Transaction ID | | `has_value` | `string` | Value | | `staircase_products` | `object[]` | Staircase Product Array. You can select only one target product for the process transaction flow. Transaction process allows only one transaction at a time. If you want to trigger another invocation, you can change the target product and invoke it again. | | `@type` | `string` | Product Type | | `@id` | `string` | Object's ID | | `has_product_name` | `object` | The business name of a product, which is a provider defined offering of goods or services, including mortgage loans. | | `has_value` | `string` | Value`employment``income` | | `product_flow_name` | `string` | Select product flow`get_services``process_transaction` | | `transaction_id` | `string` | Staircase Transaction ID used for invocation | | `callback_url` | `string` | The callback url | ##### Response `201``application/json` 1 fields Create Invocation Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/products/los-encompass-service-application/invocations/{invocation_id}` #### Retrieve Invocation Response `getEncompassServiceAppInvocationResponse` Retrieves Invocation Response ##### Response 201 Example201 Flow running example201 Flow completed example201 Flow failed example400403 application/json Copy Successfully started flow invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "invocation_status": "STARTED", "product_flow_name": "credit", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK" } ``` application/json Copy Successfully started flow invocation. ``` { "request_collection_id": "01G10CQPDSFST529E6ZMVDEWNZ", "response_collection_id": "01G10CQPG8QDF8DPN9JMRWHQPH", "service_invocation": { "Connector": { "status": "RUNNING", "invocation_id": "f6ff74d0-ee98-4988-a8ca-7c2f79035890", "connector_flow_name": "process_transaction" } }, "callback_url": "https://webhook.site/cc202161-980d-4f8a-bdd3-c0781fcd004e", "widget_url": {}, "metadata": {}, "options": {}, "invocation_id": "5321578a-e17a-4139-aea2-3b8bbaa39795", "invocation_status": "RUNNING", "transaction_id": "01G10CQP6A1F63HFD6EX6RYE5T", "product_flow_name": "process_transaction", "connector_job_id": "f6ff74d0-ee98-4988-a8ca-7c2f79035890", "request_collection": { "data": { "organizations": [ { "@type": "customer", "has_transaction_identifier": { "has_value": "b51b9d92-2d0e-482a-9504-42d41cce1fa0" } } ], "staircase_products": [ { "@type": "staircase_product", "has_product_name": { "has_value": "employment" } } ] }, "transaction_id": "01G10CQP6A1F63HFD6EX6RYE5T", "collection_id": "01G10CQPDSFST529E6ZMVDEWNZ", "metadata": { "created_at": "2022-04-19T03:49:03.033961-04:00", "validation": false } }, "response_collection": { "transaction_id": "01G10CQP6A1F63HFD6EX6RYE5T", "metadata": { "created_at": "2022-04-19T03:49:03.112350-04:00", "invocation_status": "STARTED", "last_updated_at": "2022-04-19T03:49:14.969533-04:00", "product_name": "los-encompass-service-application", "service_invocation": { "Connector": { "status": "RUNNING", "invocation_id": "f6ff74d0-ee98-4988-a8ca-7c2f79035890", "connector_flow_name": "process_transaction" } }, "validation": false }, "collection_id": "01G10CQPG8QDF8DPN9JMRWHQPH", "data": {} }, "flows_responses": {}, "_links": { "health_metrics": "https://russell-dev.staircaseapi.com/code-health-checker/metric/01G10CQP6A1F63HFD6EX6RYE5T?product_name=los-encompass-service-application" } } ``` application/json Copy Successfully started flow invocation. ``` { "request_collection_id": "01G10A9X8HM7QR51HJH6F964G8", "response_collection_id": "01G10A9XB8CBCPQA58Z7ZT1GXP", "service_invocation": { "Connector": { "status": "COMPLETED", "invocation_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "connector_flow_name": "process_transaction" } }, "callback_url": "https://webhook.site/cc202161-980d-4f8a-bdd3-c0781fcd004e", "widget_url": {}, "metadata": {}, "options": {}, "invocation_id": "28ab302d-d146-4c3d-94ae-91f7f373be2b", "invocation_status": "COMPLETED", "transaction_id": "01G10A9WZH3S31WM8DFK68GT0T", "product_flow_name": "process_transaction", "connector_job_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "request_collection": { "metadata": { "created_at": "2022-04-19T03:06:34.129585-04:00", "validation": false }, "collection_id": "01G10A9X8HM7QR51HJH6F964G8", "data": { "organizations": [ { "@type": "customer", "has_transaction_identifier": { "has_value": "b51b9d92-2d0e-482a-9504-42d41cce1fa0" } } ], "staircase_products": [ { "@type": "staircase_product", "has_product_name": { "has_value": "employment" } } ] }, "transaction_id": "01G10A9WZH3S31WM8DFK68GT0T" }, "response_collection": { "metadata": { "created_at": "2022-04-19T03:06:34.216863-04:00", "invocation_status": "COMPLETED", "last_updated_at": "2022-04-19T03:08:33.526311-04:00", "product_name": "los-encompass-service-application", "service_invocation": { "Connector": { "status": "RUNNING", "invocation_id": "d4c2e290-887b-4e20-808f-c3bfafd170da", "connector_flow_name": "process_transaction" } }, "validation": false }, "collection_id": "01G10A9XB8CBCPQA58Z7ZT1GXP", "data": { "message": "EPC Transaction Completed." }, "transaction_id": "01G10A9WZH3S31WM8DFK68GT0T" }, "flows_responses": {}, "_links": { "health_metrics": "https://russell-dev.staircaseapi.com/code-health-checker/metric/01G10A9WZH3S31WM8DFK68GT0T?product_name=los-encompass-service-application" } } ``` application/json Copy Successfully started flow invocation. ``` { "request_collection_id": "01FX2ZTZEVR0QW15HV0M1X953S", "response_collection_id": "01FX2ZTZGP8GTVDXE1ECSKTF2A", "service_invocation": { "Connector": { "status": "FAILED", "invocation_id": "c3b02a42-53c9-49c7-981a-b3da462db747", "connector_flow_name": "process_transaction" }, "Translator": {} }, "metadata": {}, "options": {}, "invocation_id": "61fa5822-56a5-4f03-ac96-06c88831ca8a", "invocation_status": "FAILED", "transaction_id": "01FX2ZTZ7A8615R3R35TC794X7", "product_flow_name": "process_transaction", "connector_job_id": "c3b02a42-53c9-49c7-981a-b3da462db747", "failure_reason": "Service Connector failed. Connector flow failed. Response payload: {'Error': 'FailStateError', 'Cause': {'errorMessage': 'EPC Transaction Failed', 'errorType': 'FailStateError', 'requestId': 'c5bb2503-a108-40b6-90ec-319157320d0a'}}", "request_collection": { "collection_id": "01FX2ZTZEVR0QW15HV0M1X953S", "transaction_id": "01FX2ZTZ7A8615R3R35TC794X7", "data": { "organizations": [ { "@type": "customer", "has_transaction_identifier": { "has_value": "2a47215f-d9f0-49cd-959d-95aec2f8a4f2" } } ], "staircase_products": [ { "@type": "staircase_product", "has_product_name": { "has_value": "income" } } ] }, "metadata": { "created_at": "2022-03-01T09:58:35.099460-05:00", "validation": false } }, "response_collection": { "collection_id": "01FX2ZTZGP8GTVDXE1ECSKTF2A", "transaction_id": "01FX2ZTZ7A8615R3R35TC794X7", "data": {}, "metadata": { "created_at": "2022-03-01T09:58:35.158772-05:00", "invocation_status": "FAILED", "last_updated_at": "2022-03-01T10:00:00.978478-05:00", "service_invocation": { "Connector": { "status": "FAILED", "invocation_id": "c3b02a42-53c9-49c7-981a-b3da462db747", "connector_flow_name": "process_transaction" }, "Translator": {} }, "validation": false } }, "flows_responses": {}, "_links": { "health_metrics": "https://russell-dev.staircaseapi.com/code-health-checker/metric/01FX2ZTZ7A8615R3R35TC794X7?product_name=los-encompass-service-application" } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `invocation_id` required | `string (ulid)` path | `01FEK8V6RT027SRAW903G97DPF` | Invocation ID | ##### Response `201``application/json` 9 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ### Encompass Process Automation `POST` `/products/los-encompass-ui-process-automation/invocations` #### Process Automation `invokeEncompassProcessAutomationPP` Process Automation Adapters are RPA (Robotic Process Automation) system that emulate humans actions interacting with Encompass systems. Process Automation service can interact with system the same way people do #### Prerequisite ##### Set up Encompass credentials Call Setup Encompass Credentials to store your Encompass credentials for adapters use. #### Staircase Encompass Services The services we currently support are as follows. You can check the Service Application to get the collection of these services defined in the staircase lexicon. Show the rest - Staircase Employment Verification - Staircase Income Verification - Staircase Asset Verification #### How to Use Setup Staircase Service It creates requested Staircase service if it's not created before and changes service credentials so that it works with the current environment. 1. RPA system goes under the menu Admin > Company/User Setup 1. Opens Service Management 1. If the service sent in the request is not in the list, it adds this service first. 1. Then, it completes the installation process by injecting the credentials you added with the setup service. `Important notice`: You can set up only one service at a time with this product flow! #### Create Loan It creates loan on the Encompass system with the provided information. #### Order Verification It orders a verification of a selected Staircase service for the given loan number. Setup Staircase Service must be called for the service before ordering a verification. ##### Request Create LoanSetup Staircase ServiceOrder Verification application/json Copy ``` { "product_flow_name": "create_loan", "request_data": { "people": [ { "@type": "borrower", "has_first_name": { "has_value": "John" }, "has_last_name": { "has_value": "Jackson" }, "has_birth_date": { "has_value": "1993-11-01" }, "has_taxpayer_identifier_value": { "has_value": 666234390 }, "with_address": [ { "@type": "address", "has_address_line_1_text": { "has_value": "33 IRVING PLACE" }, "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_at": [ { "@type": "contact_information", "has_email_address": { "has_value": "test@test.com" } }, { "@type": "contact_information", "has_email_address": { "has_value": 1 } } ], "works_for": [ { "@type": "organization", "has_organization_name": { "has_value": "Amazon" } } ] } ] } } ``` application/json Copy ``` { "product_flow_name": "setup_staircase_service", "request_data": { "services": [ { "has_service_name": { "has_value": "Staircase Employment Demo" } }, { "has_service_name": { "has_value": "Staircase Income Demo" } } ] } } ``` application/json Copy ``` { "product_flow_name": "order_verification", "request_data": { "services": [ { "loans": [ { "with_loan_identifier": [ { "has_loan_identifier": { "has_value": "TEST211200121" } } ] } ] }, { "has_service_name": { "has_value": "Staircase Employment Demo" } } ] } } ``` ##### Response 201400403500 application/json Copy Create Invocation Triggered Successfully ``` { "invocation_id": "01FDYNKEP7DRV8HAE4X6J580NP" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Staircase Transaction ID used for invocation | | `request_data` | `object` | Empty Object | | `people` | `object[]` | Person Array | | `@type` | `string` | Person's Type`borrower` | | `has_first_name` | `object` | Borrower's First Name | | `has_value` | `string` | Value | | `has_last_name` | `object` | Borrower's Last Name | | `has_value` | `string` | Value | | `has_birth_date` | `object` | Borrower's Birthday | | `has_value` | `string` | Value | | `has_taxpayer_identifier_value` | `object` | Borrower's Taxpayer Identifier Value (SSN) | | `has_value` | `string` | Value | | `with_address` | `object[]` | Borrower's Address Array | | `@type` | `string` | Object Type`address` | | `has_address_line_1_text` | `object` | Address Line 1 | | `has_city_name` | `object` | City | | `has_state_code` | `object` | State Code | | `has_postal_code` | `object` | Postal Code | | `has_country_name` | `object` | Country Name | | `contact_at` | `object[]` | Contact Information Array | | `@type` | `string` | Object Type`contact_information` | | `has_email_address` | `object` | Email Address | | `has_phone_number` | `object` | Phone Number | | `works_for` | `object[]` | Employment Information Array | | `@type` | `string` | Object Type`organization` | | `has_organization_name` | `object` | Organization Name | | `services` | `object[]` | Services Array | | `has_service_name` | `object` | Name of the service to be used in Encompass automation | | `has_value` | `string` | Service Name | | `mortgage_products` | `object[]` | Mortgage Products Array | | `has_partner_name` | `object` | Name of the partner to be used for verification | | `has_value` | `string` | Partner Name | | `loans` | `object[]` | Loans Array | | `with_loan_identifier` | `object[]` | Loan Identifier Array | | `has_loan_identifier` | `object` | Loan Identifier | | `product_flow_name` | `string` | Select product flow`create_loan``order_verification``setup_staircase_service` | ##### Response `201``application/json` 1 fields Create Invocation Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` `GET` `/products/los-encompass-ui-process-automation/invocations/{invocation_id}` #### Retrieve Invocation Response `getEncompassProcessAutomationInvocationResponse` Retrieves Invocation Response ##### Response 201400403 application/json Copy Successfully started flow invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "invocation_status": "STARTED", "product_flow_name": "create_loan", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | | `invocation_id` required | `string (ulid)` path | `01FEK8V6RT027SRAW903G97DPF` | Invocation ID | ##### Response `201``application/json` 7 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` ## Providers - Byte Software - ICE Mortgage Technology - LendingPad ## Errors `400``403``404``405``422``500` --- # Assessment # Assessment The property record, valuation, appraisal intake, listings and property tax. What is the collateral, and what is it worth? The category runs from the physical record to the number. The property record is the parcel-level fact set every other product here reads; appraisal and listing are two independent opinions of value with different failure modes; valuation blends them; tax carries the assessed position and its history. ## Products In the order the value chain runs. 1. Appraisal has a recorded specification 1. Listing has a recorded specification 1. Property has a recorded specification 1. Tax has a recorded specification 1. Valuation has a recorded specification ## How the chain fits together Physical characteristics come from the assessor's record rather than a listing, because listing fields are agent-entered, inconsistent between markets, and absent entirely for a property never offered for sale. The later and larger expression of the same decision is the property model under Data. --- # Appraisal # Appraisal Appraisal ordering and intake: placing the order, receiving the report, and normalising it against the loan file. An appraisal arrives as a form with a defined field set, and normalising it means reading those fields into the canonical model — subject characteristics, comparables with their adjustments, and the reconciled value. Checking the report for internal correctness is the dual-listed slot, Appraisal under Validation. Intake and validation are separated because a report can be received and stored before anyone has decided whether it is acceptable. The operations below come from the collateral service, which routes appraisal alongside valuation, inspection and hazard insurance. Ordering an appraisal and ordering an automated valuation are the same shape of call against different evidence, which is why they share a surface. ## Dual listing Appraisal is filed under two categories. The other listing is Appraisal under Validation, and neither listing carries a recorded specification. ## Operations ### Workflow `POST` `/products/collateral-underwriting/invocations` #### Invoke Product Flow `InvokeSpecificProductFlow` This endpoint allows you to underwrite an appraisal document. #### Usage - Before running this endpoint, you need to create a Staircase Blob with appraisal report content. Then, you can set `$.documents.0.has_staircase_blob_identifier.has_value` to this blob identifier. - A unique identifier for this loan should be given in the following path `$.loans.0.has_loan_identifier_value.has_value` - After invocation is completed, Collateral Underwriting will watch status changes in partner, and whenever there is a status changed an `ORDER_STATUS_UPDATED` Job event will be published. You can process these events by catching with this trigger expression. ``` { "name": "collateral-underwriting-trigger", "description": "Event Trigger", "type": "EVENT", "filter_expression": { "source_name": [ "collateral-underwriting" ], "event_type": [ "ORDER_STATUS_UPDATED" ] }, "actions": { "target_jobs": [ "collateral-underwriting-test-job" ] } } ``` When `vendor_name` is set to `"homevision"`, the captured event will be in the following format: Show the rest ``` { "transaction_id": "01G390E72SN9KK98146AG1WCRX", "flow_name": "homevision-flow", "homevision_loan_identifier": "01G390E72SN9KK98146AG1WCRX", "response_collection_id": "01G390EH4QYS7CNVPVZSP7AZ3S", "request_collection_id": "01G390EH4QYS7CNVPVZSP7AZ3S", "domain": "aus-dev.staircaseapi.com", "homevision_event_type": 4, "homevision_order_id": 8109, "homevision_internal_url": "", "homevision_order_status": "Order Completed", "homevision_message": "A new event has occurred for this order", "homevision_pdf_url": "", "homevision_xml_url": "", "homevision_env_url": "", "event_type": "ORDER_STATUS_UPDATED" } ``` ##### Request Flow Invocation with Collection IDConventional ExampleFha Example application/json Copy ``` { "vendor_name": "homevision", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN" } ``` application/json Copy ``` { "vendor_name": "homevision", "request_data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` application/json Copy ``` { "vendor_name": "homevision", "request_data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "government_loans": [ { "@id": "government_loan_id", "@type": "government_loan", "has_fha_case_number": { "has_value": "FHA111111111" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" }, "with_government_loan": [ "government_loan_id" ] } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` ##### Response 201400403404500 application/json Copy Successfully started flow invocation. ``` { "product_flow_name": "collateral-underwriting", "metadata": {}, "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "STARTED", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Response `201``application/json` 7 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID. | | `invocation_status` | `string` | The status of the invocation.`STARTED` | | `transaction_id` | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name.`collateral-underwriting` | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/collateral-underwriting/invocations/{invocation_id}` #### Retrieve Invocation Status `RetrieveProductFlowInvocationStatus` Retrieve status of a Product Flow Invocation Retrieves the status of running Product flow invocation. ##### Response 200400403404500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "response_collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "metadata": {}, "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "RUNNING", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "product_flow_name": "collateral-underwriting", "request_collection": { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } }, "response_collection": { "metadata": { "created_at": "2021-09-14T03:36:45.193268-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "data": { "services": [ { "@id": "service_id", "@type": "service", "has_service_name": { "has_value": "Collateral Underwriting" }, "has_service_vendor_name": { "has_value": "homevision" }, "with_foreign_object": [ "f1", "f2", "f3", "f4" ] } ], "foreign_objects": [ { "@id": "f1", "@type": "foreign_object", "has_object_name": { "has_value": "internal_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/xmlqc/2394077" } }, { "@id": "f2", "@type": "foreign_object", "has_object_name": { "has_value": "pdf_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/123456/pdf.pdf" } }, { "@id": "f3", "@type": "foreign_object", "has_object_name": { "has_value": "xml_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/123456/xml.xml" } }, { "@id": "f4", "@type": "foreign_object", "has_object_name": { "has_value": "env_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/123456/env.env" } } ] } } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Product flow invocation identifier | ##### Response `200``application/json` 9 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_status`required | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `request_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `response_collection_id` | `string` | Response Collection ID. | | `response_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | — | | `services`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_service_name`required | `object` | — | | `has_service_vendor_name`required | `object` | — | | `with_foreign_object`required | `string[]` | — | | `foreign_objects`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_object_name`required | `object` | — | | `has_object_url_value` | `object` | — | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `callback_url` | `string` | URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished. | | `widget_url` | `string (uri)` | URL of the widget. | | `metadata` | `object` | Response Collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/collateral-underwriting/request-schema` #### Retrieve Request Schema `retrieveRequestSchema` 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. ##### Response 200 Schema200 Schema with Examples400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "required": [ "addresses", "documents", "loans", "loan_terms", "organizations", "people", "properties", "property_valuations", "residences", "roles", "sales_contracts" ], "properties": { "addresses": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_state_code", "has_city_name", "has_postal_code", "has_address_line_1_text" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "documents": { "type": "array", "items": { "type": "object", "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_staircase_blob_identifier": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } }, "required": [ "@id", "@type", "has_staircase_blob_identifier" ] } }, "loans": { "type": "array", "items": { "type": "object", "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_government_loan": { "type": "array", "items": { "type": "string" } }, "has_loan_identifier_value": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } }, "required": [ "@id", "@type", "has_loan_identifier_value" ] } }, "government_loans": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_fha_case_number" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_fha_case_number": { "type": "object", "properties": { "has_value": { "type": "string" } }, "required": [ "has_value" ] } } } }, "loan_terms": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_loan_purpose_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_loan_purpose_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "organizations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_organization_name", "with_address" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "with_address": { "type": "array", "items": { "type": "string" } } } } }, "people": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_full_name" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_appraisal_sub_committee_appraiser_identifier": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_full_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "lives_at": { "type": "array", "items": { "type": "string" } } } } }, "properties": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_address", "with_sales_contract" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_address": { "type": "array", "items": { "type": "string" } }, "with_sales_contract": { "type": "array", "items": { "type": "string" } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_property_inspection_type_other_description" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_property_inspection_type_other_description": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "residences": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_address" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_address": { "type": "array", "items": { "type": "string" } } } } }, "roles": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_appraiser" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_appraiser": { "type": "array", "items": { "type": "string" } } } } }, "sales_contracts": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_sales_contract_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_sales_contract_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } } }, "description": "The data that is needed for invocation. It should follow the request schema" } } ``` application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "required": [ "addresses", "documents", "loans", "loan_terms", "organizations", "people", "properties", "property_valuations", "residences", "roles", "sales_contracts" ], "properties": { "addresses": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_state_code", "has_city_name", "has_postal_code", "has_address_line_1_text" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "documents": { "type": "array", "items": { "type": "object", "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_staircase_blob_identifier": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } }, "required": [ "@id", "@type", "has_staircase_blob_identifier" ] } }, "loans": { "type": "array", "items": { "type": "object", "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_government_loan": { "type": "array", "items": { "type": "string" } }, "has_loan_identifier_value": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } }, "required": [ "@id", "@type", "has_loan_identifier_value" ] } }, "government_loans": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_fha_case_number" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_fha_case_number": { "type": "object", "properties": { "has_value": { "type": "string" } }, "required": [ "has_value" ] } } } }, "loan_terms": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_loan_purpose_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_loan_purpose_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "organizations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_organization_name", "with_address" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "with_address": { "type": "array", "items": { "type": "string" } } } } }, "people": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_full_name" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_appraisal_sub_committee_appraiser_identifier": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_full_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "lives_at": { "type": "array", "items": { "type": "string" } } } } }, "properties": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_address", "with_sales_contract" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_address": { "type": "array", "items": { "type": "string" } }, "with_sales_contract": { "type": "array", "items": { "type": "string" } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_property_inspection_type_other_description" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_property_inspection_type_other_description": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "residences": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_address" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_address": { "type": "array", "items": { "type": "string" } } } } }, "roles": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_appraiser" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_appraiser": { "type": "array", "items": { "type": "string" } } } } }, "sales_contracts": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_sales_contract_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_sales_contract_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } } }, "description": "The data that is needed for invocation. It should follow the request schema" }, "examples": [ { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] }, { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "government_loans": [ { "@id": "government_loan_id", "@type": "government_loan", "has_fha_case_number": { "has_value": "FHA111111111" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" }, "with_government_loan": [ "government_loan_id" ] } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Request schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | Schema for the Request Collection | | `examples` | `object` | Each item in the dictionary corresponds to the name of the example and dictionary content is the sample response. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/collateral-underwriting/response-schema` #### Retrieve Response Schema `retrieveResponseSchema` Retrieve Response Schema returns the JSON schema for the response collection, created by an invocation. If you would like to retrieve examples along with the schema, you can provide `return_examples=True` query parameter. ##### Response 200 Schema200 Schema with Examples Response400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "required": [ "services", "foreign_objects" ], "properties": { "services": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_service_name", "has_service_vendor_name", "with_foreign_object" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_service_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_service_vendor_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "with_foreign_object": { "type": "array", "items": { "type": "string" } } } } }, "foreign_objects": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_object_name" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_object_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_object_url_value": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } } } } } ``` application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "required": [ "services", "foreign_objects" ], "properties": { "services": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_service_name", "has_service_vendor_name", "with_foreign_object" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_service_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_service_vendor_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "with_foreign_object": { "type": "array", "items": { "type": "string" } } } } }, "foreign_objects": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_object_name" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_object_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_object_url_value": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } } } }, "examples": [ { "services": [ { "@id": "service_id", "@type": "service", "has_service_name": { "has_value": "Collateral Underwriting" }, "has_service_vendor_name": { "has_value": "homevision" }, "with_foreign_object": [ "f1", "f2", "f3", "f4" ] } ], "foreign_objects": [ { "@id": "f1", "@type": "foreign_object", "has_object_name": { "has_value": "internal_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/xmlqc/2394077" } }, { "@id": "f2", "@type": "foreign_object", "has_object_name": { "has_value": "pdf_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/123456/pdf.pdf" } }, { "@id": "f3", "@type": "foreign_object", "has_object_name": { "has_value": "xml_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/123456/xml.xml" } }, { "@id": "f4", "@type": "foreign_object", "has_object_name": { "has_value": "env_url" }, "has_object_url_value": { "has_value": "https://app.homevision.co/123456/env.env" } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Response schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | JSON-Schema as a single object | | `examples` | `object` | A key-value pair for the examples. Keys are the example names, while values correspond to the example values for the response collections you can retrieve. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Platform `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /products/collateral-underwriting/invocations ##### Request Conventional ExampleFha Example application/json Copy ``` { "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` application/json Copy ``` { "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "government_loans": [ { "@id": "government_loan_id", "@type": "government_loan", "has_fha_case_number": { "has_value": "FHA111111111" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" }, "with_government_loan": [ "government_loan_id" ] } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collectionchr\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction\nID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data that is needed for invocation. It should follow the request schema | | `addresses`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code`required | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text`required | `object` | — | | `has_value`required | `string` | — | | `has_county_name` | `object` | — | | `has_value`required | `string` | — | | `documents`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_staircase_blob_identifier`required | `object` | — | | `has_value`required | `string` | — | | `loans`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_government_loan` | `string[]` | — | | `has_loan_identifier_value`required | `object` | — | | `has_value`required | `string` | — | | `government_loans` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_fha_case_number`required | `object` | — | | `has_value`required | `string` | — | | `loan_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_loan_purpose_type`required | `object` | — | | `has_value`required | `string` | — | | `organizations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_organization_name`required | `object` | — | | `has_value`required | `string` | — | | `with_address`required | `string[]` | — | | `people`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_appraisal_sub_committee_appraiser_identifier` | `object` | — | | `has_value`required | `string` | — | | `has_full_name`required | `object` | — | | `has_value`required | `string` | — | | `lives_at` | `string[]` | — | | `properties`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_address`required | `string[]` | — | | `with_sales_contract`required | `string[]` | — | | `property_valuations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_property_inspection_type_other_description`required | `object` | — | | `has_value`required | `string` | — | | `residences`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_address`required | `string[]` | — | | `roles`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_appraiser`required | `string[]` | — | | `sales_contracts`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_sales_contract_amount`required | `object` | — | | `has_value`required | `integer` | — | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 403404 GetCollectionError404 GetCollectionsError500 application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 4 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | — | | `collection_id`required | `string` | — | | `metadata`required | `object` | — | | `created_at`required | `string` | — | | `validation`required | `boolean` | — | | `data`required | `object` | — | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` Retrieve Transaction Collections returns the content of a given `collection_id` associated with a specific `transaction_id`. ##### Response 200400403404500 application/json Copy Transaction collection retrieved successfully ``` { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": {} } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Transaction collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given `collection_id` associated with a `transaction_id`. ##### Request Conventional ExampleFha Example application/json Copy ``` { "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` application/json Copy ``` { "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "government_loans": [ { "@id": "government_loan_id", "@type": "government_loan", "has_fha_case_number": { "has_value": "FHA111111111" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" }, "with_government_loan": [ "government_loan_id" ] } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` ##### Response 200400 UpdateCollectionError400 text/html403404 UpdateCollectionError404 text/html500 application/json Copy Collection updated successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "addresses": [ { "@id": "address_id", "@type": "business_address", "has_state_code": { "has_value": "CA" }, "has_city_name": { "has_value": "Bankville" }, "has_postal_code": { "has_value": 2138 }, "has_address_line_1_text": { "has_value": "123 Lending Lane" } }, { "@id": "subject_property_address_id", "@type": "subject_property_address", "has_county_name": { "has_value": "Pinellas" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } }, { "@id": "borrower_address_id", "@type": "residential_address", "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Salem" }, "has_postal_code": { "has_value": "2138" }, "has_address_line_1_text": { "has_value": "456 Main Street" } } ], "documents": [ { "@id": "document_id", "@type": "document", "has_staircase_blob_identifier": { "has_value": "01G2YVWSGPQC9Y9A6AXTHYMDET" } } ], "loans": [ { "@id": "loan_id", "@type": "loan", "has_loan_identifier_value": { "has_value": "01G313MDG9KVKW62YK8S1WNMWB" } } ], "loan_terms": [ { "@id": "loan_term_id", "@type": "loan_terms", "has_loan_purpose_type": { "has_value": "refinance" } } ], "organizations": [ { "@id": "organization_id", "@type": "organization", "has_organization_name": { "has_value": "Liberty Lending" }, "with_address": [ "address_id" ] } ], "people": [ { "@id": "appraiser_id", "@type": "appraiser", "has_appraisal_sub_committee_appraiser_identifier": { "has_value": "A12345" }, "has_full_name": { "has_value": "Alan Appraiser" } }, { "@id": "borrower_id", "@type": "borrower", "has_full_name": { "has_value": "Jane Doe" }, "lives_at": [ "residence_id" ] }, { "@id": "co_borrower_id", "@type": "borrower", "has_full_name": { "has_value": "John Doe" } } ], "properties": [ { "@id": "subject_property_id", "@type": "subject_property", "with_address": [ "subject_property_address_id" ], "with_sales_contract": [ "sales_contract_id" ] } ], "property_valuations": [ { "@id": "property_valution_id", "@type": "property_valuation", "has_property_inspection_type_other_description": { "has_value": "1004" } } ], "residences": [ { "@id": "residence_id", "@type": "residence", "with_address": [ "borrower_address_id" ] } ], "roles": [ { "@id": "role_id", "@type": "role", "with_appraiser": [ "appraiser_id" ] } ], "sales_contracts": [ { "@id": "sales_contract_id", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 123456 } } ] } } ``` application/json Copy Error ``` { "description": "Error details.", "message": "Unable to update collection. Please check the collection\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data that is needed for invocation. It should follow the request schema | | `addresses`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code`required | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text`required | `object` | — | | `has_value`required | `string` | — | | `has_county_name` | `object` | — | | `has_value`required | `string` | — | | `documents`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_staircase_blob_identifier`required | `object` | — | | `has_value`required | `string` | — | | `loans`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_government_loan` | `string[]` | — | | `has_loan_identifier_value`required | `object` | — | | `has_value`required | `string` | — | | `government_loans` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_fha_case_number`required | `object` | — | | `has_value`required | `string` | — | | `loan_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_loan_purpose_type`required | `object` | — | | `has_value`required | `string` | — | | `organizations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_organization_name`required | `object` | — | | `has_value`required | `string` | — | | `with_address`required | `string[]` | — | | `people`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_appraisal_sub_committee_appraiser_identifier` | `object` | — | | `has_value`required | `string` | — | | `has_full_name`required | `object` | — | | `has_value`required | `string` | — | | `lives_at` | `string[]` | — | | `properties`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_address`required | `string[]` | — | | `with_sales_contract`required | `string[]` | — | | `property_valuations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_property_inspection_type_other_description`required | `object` | — | | `has_value`required | `string` | — | | `residences`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_address`required | `string[]` | — | | `roles`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_appraiser`required | `string[]` | — | | `sales_contracts`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_sales_contract_amount`required | `object` | — | | `has_value`required | `integer` | — | ##### Response `200``application/json` 4 fields Collection updated successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` ### Operations `POST` `/appraisal` #### Create Appraisal `post-appraisal` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Appraisal request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Appraisal request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `GET` `/appraisal/elements` #### Retrieve Elements `get-appraisal-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request. | Field | Type | Description | | --- | --- | --- | | `elements` | `object` | List of elements | `POST` `/appraisal/elements/complete` #### Validate Collection `post-appraisal-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `collection`required | `object` | — | ##### Response `400``application/json` 2 fields Collection is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/appraisal/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-appraisal-status` Retrieve Status checks status of your request. Possible statuses: - REQUEST_MADE - REQUEST_ACCEPTED - WAITING_FOR_RESPONSE - COMPLETED ##### Response 200400 application/json Copy Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Current execution status | ##### Response `400``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | `POST` `/appraisal/transactions` #### Create Transaction `post-appraisal-transaction` Create Transaction creates a transaction in Staircase. A transaction in Staircase is an acknowledgement that you want to call a Staircase product. It's a container for everything associated with that product invocation, and is correlated with a collection related to the product (e.g. a document). You need to create a new transaction every time you want to connect with a Staircase product. Staircase then associates everything, from a data and API execution standpoint, to that transaction. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | `POST` `/appraisal/transactions/{transaction_id}/collections` #### Create Collection `post-appraisal-collection` Create Collection creates a collection of elements . The elements within the collection are required. ##### Request application/json Copy ``` { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully created. ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `PUT` `/appraisal/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-appraisal-collection` Update Collection updates a collection of elements by new elements. ##### Request application/json Copy ``` { "sets": { "set": [ { "properties": { "property": [ { "propety_entry": { "propety_entries": { "datetime": "2020-05-05", "description": "Test Description", "event_type": "TestType" } }, "propety_class": { "propety_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully updated ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "properties": { "property": [ { "property_data": { "property_class": { "datetime": "2020-05-05", "description": "Info", "event_type": "TestEvent" } }, "document_classification": { "document_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | ## Errors `400``403``404``405``500` ## More in Assessment - Next product: Listing --- # Listing # Listing Listing-data ingestion: bulk feeds, incremental updates, and normalisation of price, commission and sale history. Two ingestion modes. A bulk feed loads the market's full inventory; an incremental extract picks up what changed since the last run. Both land in the same canonical listing classes. Listing history is kept as a timeline rather than as a current state. A price reduction and its date are the signal; the current asking price alone is not. ## How it works Listing data is treated as evidence about the market rather than as fact about the property. Physical characteristics come from the assessor record in Property; what the listing contributes is price, timing and the agent's account of condition. ## Operations ### Address Autocomplete `GET` `/api/address-autocomplete` #### Address Autocomplete `addressAutocomplete` Provide address autocomplete suggestions using Typesense database. ##### Response 200400404 application/json Copy Success ``` { "result": [ { "full_address": "1303 North 24th Street, Fort Pierce, FL 34950-5706, USA", "listing_identifier": "RX-10996641" } ] } ``` application/json Copy Parsing error ``` { "message": "Something went wrong while parsing data." } ``` application/json Copy Not Found ``` { "message": "Not Found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `address` required | `string` query | `1303 N 24th St` | Address to search suggestions for. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `result` | `object[]` | Address suggestions | | `highlight` | `string` | Highlighted addressExample `18419 SE Wood Haven Ln Jupiter FL 33469` | | `address_identifier` | `string` | Address identifierExample `1` | | `full_address` | `string` | Full addressExample `1303 North 24th Street, Fort Pierce, FL 34950-5706, USA` | | `mls_number_identifier` | `string` | Listing identifierExample `RX-10996641` | ##### Other responses `400``404` ### Featured Listings `GET` `/api/featured-listings` #### List Featured Listings `listFeaturedListings` ##### Response application/json Copy Success ``` { "total_listings": 13, "listings": [ { "id": "R10948321", "bathroom_count": 5, "bedroom_count": 6, "price": "$5600000", "photo_links": [ "https://dev-data-manager-blobs-bucket-us-east-1-284201000534.s3.amazonaws.com/01J0RAA48B3V8R3H6E2ABKADX7.csv?" ], "size_sqft": 16174, "address": { "number": "17392", "direction": "S", "name": "Beach Rd", "city": "Jupiter", "state": "Florida", "stateabrv": "FL", "unit_identifier": null, "zip": "33478" } } ], "page": 5, "limit": 1 } ``` ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `total_listings` | `integer` | Number of propertiesExample `500` | | `listings` | `object[]` | Listings | | `id` | `string` | Listing IdentifierExample `R10960478` | | `bathroom_count` | `integer` | Bathroom CountExample `11` | | `bedroom_count` | `integer` | Bedroom CountExample `6` | | `price` | `string` | Property priceExample `$74,950,000` | | `photo_links` | `string[]` | Status | | `size_sqft` | `integer` | Size of the propertyExample `19666` | | `address` | `object` | Address of the property | | `page` | `integer` | Page of searchExample `1` | | `limit` | `integer` | Count of returned listingsExample `5` | ### Verified Listings[new] `GET` `/api/listings` #### List Listings `listListings` ##### Response 200400 application/json Copy Success ``` { "total_listings": 500, "listings": [ { "id": "R10960478", "bathroom_count": 11, "bedroom_count": 6, "price": "$74,950,000", "photo_links": [ "https://api-trestle.corelogic.com/trestle/Media/FTL.FTL_RMLS/Property/PHOTO-jpeg/1061293103/1/MzczLzE5MTEvMjA/MjAvNTg4MS8xNzE0NTExNzAz/VyYmk00oHFgbkHESRbSVGqgKvoQrLVhMDkfeiOQSJGk" ], "size_sqft": 19666 } ], "page": 1, "limit": 1 } ``` application/json Copy Parsing error ``` { "message": "Something went wrong while parsing data." } ``` ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `total_listings` | `integer` | Number of propertiesExample `500` | | `listings` | `object[]` | Listings | | `id` | `string` | Listing IdentifierExample `R10960478` | | `bathroom_count` | `integer` | Bathroom CountExample `11` | | `bedroom_count` | `integer` | Bedroom CountExample `6` | | `price` | `string` | Property priceExample `$74,950,000` | | `photo_links` | `string[]` | Status | | `size_sqft` | `integer` | Size of the propertyExample `19666` | | `page` | `integer` | Page of searchExample `1` | | `limit` | `integer` | Count of returned listingsExample `5` | ##### Other responses `400` `POST` `/api/delete-search-cache` #### Delete Search Cache `deleteSearchCache` Execute Search Cache Deletion. This operation clean up address search cache and list listings v2 CloudFront cache. ##### Response application/json Copy Success ``` { "operation_id": "01F7S0NA7CQ31DZQYVSVPN66GNK", "operation_status": "In Progress" } ``` ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `operation_id` | `string` | Operation identifierExample `01F7S0NA7CQ31DZQYVSVPN66GNK` | | `operation_status` | `string` | Operation statusExample `In Progress` | `PUT` `/commissions` #### Upload Commissions `uploadCommission` Update DynamoDB with new MLS commissions. ##### Response application/json Copy Success ``` { "presigned_url": "https://verified-listings-search-dev-listingsbucket-tazledfrubic.s3.amazonaws.com/commission/20240704/update.csv?AWSAccessKeyId=&Signature=&content-type=text%2Fcsv&x-amz-security-token=&Expires=1720100100" } ``` ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `presigned_url` | `string` | Link for table PUT item operationExample `https://verified-listings-search-dev-listingsbucket-tazledfrubic.s3.amazonaws.com/commission/20240704/update.csv?AWSAccessKeyId=&Signature=&content-type=text%2Fcsv&x-amz-security-token=&Expires=1720100100` | `GET` `/listing/{id}` #### Search `listingsSearchId` Get Listing Get raw data from IDX. ##### Response application/json Copy Success ``` { "listing": { "street": "8346 NW 118 Way", "city": "Coral Springs", "state": "Florida", "zipcode": "33076", "status": "Active", "price": "800000", "bathroom_count": "2", "bedroom_count": "3", "lease_price": null, "sale_price": null, "square_footage": "1904", "sold_date": null, "description": "Turn key*Quick closing ok* immaculate Single Family Home with serene wide water views located in a Guard Gated Golf course Cmnty* Impact Glass* potential to convert to a 4 Bedroom* Tile in living areas* wood in one room* Tankless gas Wtr Htr* Gas Range for gourmet cooking* Snack Bar Island w/sink* SS Appliances* Granite counters & 42 inch Cabinets* high volume ceilings, recessed lighting* knockdown texture* crown molding*some coffered ceilings* Master has a Huge walk in closet * amenities galore* close to shopping, places of worship, schools, parks, Equestrian center and much more*", "primary_features": { "county": "Broward County", "partial_bathrooms": null, "property_sub_type": "Single Family Residence", "property_type": "Residential", "subdivision": "Somerset", "year_built": "2013" }, "interior": { "appliances": "Some Gas Appliances, Dryer, Dishwasher, Disposal, Gas Range, Gas Water Heater, Microwave, Refrigerator, Washer", "building_area_total": "2574", "cooling": "Central Air, Ceiling Fan(s), Electric", "fireplace_features": null, "flooring": "Carpet, Ceramic Tile, Tile, Wood", "heating": "Central, Electric", "interior_features": "Breakfast Bar, Dual Sinks, High Ceilings, Living/Dining Room, Main Level Primary, Pantry, Split Bedrooms, Separate Shower, Walk-In Closet(s), Attic", "spa_features": null, "stories_total": null }, "external": { "construction_materials": "Block, Other", "covered_spaces": "2", "door_features": null, "exterior_features": "Enclosed Porch, Security/High Impact Doors", "garage_spaces": "2", "lot_features": "Other, Sprinklers Automatic, < 1/4 Acre", "lot_size_area": "6841", "lot_size_square_feet": "6841", "parking_features": "Attached, Driveway, Garage", "patio_and_porch_features": "Porch, Screened", "pool_features": "None, Community", "roof": "Spanish Tile", "sewer": "Public Sewer", "utilities": "Cable Available", "water_source": "Public", "window_features": "Blinds, Drapes, Impact Glass" }, "location": { "association_amenities": null, "community_features": "Clubhouse, Gated, Home Owners Association, Pool", "complex_name": null, "elementary_school": "Heron Heights", "mls_area_major": "3614", "mls_area_minor": "North Broward 441 To Everglades (3611-3642)", "postal_city": "Coral Springs", "view": "Canal, Water", "waterfront_features": "Canal Front", "zoning_description": "RS-6" }, "additional": { "builder_model": "Azalea", "housing_older_persons_act": "No HOPA", "mls_status": "Active", "pets_allowed": "Size Limit, Yes", "property_condition": "Resale", "property_sub_type_additional": "Single Family Residence", "security_features": "Smoke Detector(s)", "year_built_details": "Resale" }, "financial": { "association_fee": "838", "association_fee_frequency": "Quarterly", "association_fee_includes": "Common Area Maintenance, Recreation Facilities, Security", "disclosures": null, "listing_terms": "Conventional", "possession": "Closing & Funding", "special_listing_conditions": "Listed As-Is", "tax_annual_amount": "9611", "tax_year": "2023" } } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `R10823327` | ID of the listing to get. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `listing` | `object` | Listing object | ##### Other responses `404` `GET` `/api/delete-search-cache/{operation_id}` #### Get Search Cache Deletion Status `getDeleteSearchCacheStatus` Get the status of the search cache deletion operation. ##### Response 200400404 application/json Copy Success ``` { "operation_id": "01F7S0NA7CQ31DZQYVSVPN66GNK", "operation_status": "Completed" } ``` application/json Copy Parsing error ``` { "message": "Something went wrong while parsing data." } ``` application/json Copy Not Found ``` { "message": "Not Found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `operation_id` required | `string` path | `01F7S0NA7CQ31DZQYVSVPN66GNK` | Operation identifier | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `operation_id` | `string` | Operation identifierExample `01F7S0NA7CQ31DZQYVSVPN66GNK` | | `operation_status` | `string` | Operation statusExample `Completed` | ##### Other responses `400``404` `GET` `/api/v2/listings` #### List Listings V2 `listListingsV2` This endpoint returns a list of verified listings. The response includes the total number of listings, the listings themselves, the page number, and the limit of listings per page. This endpoint supports query parameters following this structure: `lexicon_listing_property[operator]=value`, where lexicon_listing_property is the property to filter by (staircase_discount_price_amount, current_list_price_amount, days_on_market_count), operator is the operator to use for the filter (gte, lte, eq, gt, lt), and value is the value to filter by. Show the rest Examples of query parameters: `staircase_discount_price_amount[gte]=1000000`, `current_list_price_amount[lt]=500000`, `days_on_market_count[eq]=30`, `featured_home_indicator[eq]=true`, `deals_home_indicator[eq]=true`, `pets_allowed_indicator[eq]=true`, `private_pool_indicator[eq]=true`, `gated_community_indicator[eq]=true`, `school_indicator[eq]=true`, `water_front_indicator[eq]=true`, `garage_spaces[gte]=0`. To perform Radius search to retrieve all of the listings around a desired location by specific radius provide the following: - Latitude of the location. - Longitude of the location. - Radius that will be used to perform search. - Number of listings to retrieve while performing search Note: if the provided Radius return number of listings that is less than the expected number, the radius will automatically increase by 1 mi, until the desired number of listings reached or max radius of 50 mi reached. Examples of query parameters: `latitude=26.6755617`,`longitude=-80.2620304`,`radius=5`,`number_of_listings=50` ##### Response 200400 application/json Copy Success ``` { "page": 1, "limit": 10, "total_listings": 10, "listings": [ { "id": "FX-10397327", "bathroom_count": 5, "bedroom_count": 6, "price": "$5,600,000", "photo_links": [ "photo_link" ], "size_sqft": 16174, "address": { "number": "8531", "direction": "SW", "unit_identifier": null, "name": "18th Pl", "city": "Davie", "state": "Florida", "stateabrv": "FL", "zip": "33324" }, "featured": true, "discounted_price": "$25,000.0" } ] } ``` application/json Copy Parsing error ``` { "message": "Something went wrong while parsing data." } ``` ##### Parameters 15 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `ids_only` | `boolean` query | `true` | Return only listing IDs. | | `listing_id` | `string[]` query | — | MLS Listing IDs to filter by. | | `page` required | `integer` query | `1` | Page number. | | `limit` required | `integer` query | `10` | Number of listings per page. | | `address` | `string` query | `8531 SW 18th Pl` | Filter by address. | | `place_id` | `string` query | `ChIJwUv6v3vX2YgR5Z9Zk1YF1ZQ` | Filter by Google place ID. | | `city_name` | `string` query | `Boca Raton` | Filter by city name. | | `postal_code` | `string` query | `33431` | Filter by postal code. | | `location` | `string` query | `PalmBeach` | Filter by location. | | `sort_by` | `string` query | `listing_price` | Sort by field. | | `sort_order` | `string` query | `asc` | Sort order. | | `latitude` | `string` query | `26.6755617` | The latitude of the location. | | `longitude` | `string` query | `-80.2620304` | The longitude of the location. | | `radius` | `string` query | `2` | Radius used in radius search in Miles. | | `number_of_listings` | `string` query | `100` | Number of listings required while performing radius search. | ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `total_listings` | `integer` | Number of propertiesExample `500` | | `listings` | `object[]` | Listings | | `page` | `integer` | Page of searchExample `1` | | `limit` | `integer` | Count of returned listingsExample `5` | ##### Other responses `400` `GET` `/api/google-reviews` #### Get Google Reviews `getGoogleReviews` This endpoint returns a list of Google reviews for Staircase business place from Google Maps. ##### Response application/json Copy Success ``` { "total_reviews": 6, "average_rating": 4.8, "reviews": [ { "name": "places/abc/reviews/abc", "author": "John Doe", "author_uri": "https://www.google.com/maps", "author_photo": "https://lh3.googleusercontent.com", "rating": 5, "publish_time": "2018-12-22T11:41:04Z", "relative_publish_time": "5 years ago", "text": "Some review text" } ] } ``` ##### Response `200``application/json` 3 fields Success | Field | Type | Description | | --- | --- | --- | | `total_reviews` | `integer` | Number of reviewsExample `6` | | `average_rating` | `number` | Average ratingExample `4.8` | | `reviews` | `object[]` | Reviews | | `name` | `string` | Review identifierExample `places/abc/reviews/abc` | | `author` | `string` | Review authorExample `John Doe` | | `author_uri` | `string` | Review author URIExample `https://www.google.com/maps` | | `author_photo` | `string` | Review author photoExample `https://lh3.googleusercontent.com` | | `rating` | `number` | Review ratingExample `5` | | `publish_time` | `string` | Review publish timeExample `2018-12-22T11:41:04Z` | | `relative_publish_time` | `string` | Relative publish timeExample `5 years ago` | | `text` | `string` | Review textExample `Some review text` | `GET` `/api/inst-posts` #### Get Instagram Posts `getInstagramPosts` This endpoint returns a list of posts from the Instagram Staircase page. ##### Response application/json Copy Success ``` { "instagram_posts": [ { "ig_link": "https://www.instagram.com/p/C3jbJXKNdgO", "post_url": "download_url" } ] } ``` ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `instagram_posts` | `object[]` | List of Instagram posts | | `ig_link` | `string` | URL of the Instagram post on the Instagram websiteExample `https://www.instagram.com/p/C3jbJXKNdgO` | | `post_url` | `string` | URL of the downloadable Instagram post contentExample `download_url` | ### Listings-Save-Customer-Data `POST` `/mortgage-rate` #### Save Mortgage Rate `saveMortgageRate` ##### Request application/json Copy ``` { "transaction_id": "12345", "monthly_payment": 1000, "usage_type": "Primary", "fico": 720, "email_frequency": "Monthly" } ``` ##### Response application/json Copy Success ``` { "message": "Data saved successfully" } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Unique identifier for the transaction. | | `monthly_payment`required | `integer` | Monthly payment amount for the mortgage. | | `usage_type`required | `string` | Type of property usage, such as Primary, Secondary, or Investment. | | `fico`required | `integer` | FICO credit score of the borrower. | | `email_frequency`required | `string` | Frequency of email notifications, e.g., Monthly or Weekly. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message indicating data was saved.Example `Data saved successfully` | `POST` `/buy-search` #### Save Buy Search `saveBuySearch` ##### Request application/json Copy ``` { "transaction_id": "12345", "email_frequency": "Monthly", "search_name": "My Search" } ``` ##### Response application/json Copy Success ``` { "message": "Data saved successfully" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Unique identifier for the transaction. | | `email_frequency`required | `string` | Frequency of email notifications, e.g., Monthly or Weekly. | | `search_name`required | `string` | Name of the search. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message indicating data was saved.Example `Data saved successfully` | `POST` `/sell-tracking` #### Save Sell Tracking `saveSellTracking` ##### Request application/json Copy ``` { "transaction_id": "12345", "email_frequency": "Monthly", "address": "123 Main St." } ``` ##### Response application/json Copy Success ``` { "message": "Data saved successfully" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Unique identifier for the transaction. | | `email_frequency`required | `string` | Frequency of email notifications, e.g., Monthly or Weekly. | | `address`required | `string` | Address of the property. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Success message indicating data was saved.Example `Data saved successfully` | ### Verified-Properties-Search `GET` `/properties/{address}` #### Get Property `getProperty` ##### Response 200404 application/json Copy Success ``` { "property": { "street": "8346 NW 118 Way", "city": "Coral Springs", "state": "Florida", "zipcode": "33076", "status": "Active", "price": "800000", "bathroom_count": "2", "bedroom_count": "3", "lease_price": null, "sale_price": null, "square_footage": "1904", "sold_date": null, "description": "Turn key*Quick closing ok* immaculate Single Family Home with serene wide water views located in a Guard Gated Golf course Cmnty* Impact Glass* potential to convert to a 4 Bedroom* Tile in living areas* wood in one room* Tankless gas Wtr Htr* Gas Range for gourmet cooking* Snack Bar Island w/sink* SS Appliances* Granite counters & 42 inch Cabinets* high volume ceilings, recessed lighting* knockdown texture* crown molding*some coffered ceilings* Master has a Huge walk in closet * amenities galore* close to shopping, places of worship, schools, parks, Equestrian center and much more*", "primary_features": { "county": "Broward County", "partial_bathrooms": null, "property_sub_type": "Single Family Residence", "property_type": "Residential", "subdivision": "Somerset", "year_built": "2013" }, "interior": { "appliances": "Some Gas Appliances, Dryer, Dishwasher, Disposal, Gas Range, Gas Water Heater, Microwave, Refrigerator, Washer", "building_area_total": "2574", "cooling": "Central Air, Ceiling Fan(s), Electric", "fireplace_features": null, "flooring": "Carpet, Ceramic Tile, Tile, Wood", "heating": "Central, Electric", "interior_features": "Breakfast Bar, Dual Sinks, High Ceilings, Living/Dining Room, Main Level Primary, Pantry, Split Bedrooms, Separate Shower, Walk-In Closet(s), Attic", "spa_features": null, "stories_total": null }, "external": { "construction_materials": "Block, Other", "covered_spaces": "2", "door_features": null, "exterior_features": "Enclosed Porch, Security/High Impact Doors", "garage_spaces": "2", "lot_features": "Other, Sprinklers Automatic, < 1/4 Acre", "lot_size_area": "6841", "lot_size_square_feet": "6841", "parking_features": "Attached, Driveway, Garage", "patio_and_porch_features": "Porch, Screened", "pool_features": "None, Community", "roof": "Spanish Tile", "sewer": "Public Sewer", "utilities": "Cable Available", "water_source": "Public", "window_features": "Blinds, Drapes, Impact Glass" }, "location": { "association_amenities": null, "community_features": "Clubhouse, Gated, Home Owners Association, Pool", "complex_name": null, "elementary_school": "Heron Heights", "mls_area_major": "3614", "mls_area_minor": "North Broward 441 To Everglades (3611-3642)", "postal_city": "Coral Springs", "view": "Canal, Water", "waterfront_features": "Canal Front", "zoning_description": "RS-6" }, "additional": { "builder_model": "Azalea", "housing_older_persons_act": "No HOPA", "mls_status": "Active", "pets_allowed": "Size Limit, Yes", "property_condition": "Resale", "property_sub_type_additional": "Single Family Residence", "security_features": "Smoke Detector(s)", "year_built_details": "Resale" }, "financial": { "association_fee": "838", "association_fee_frequency": "Quarterly", "association_fee_includes": "Common Area Maintenance, Recreation Facilities, Security", "disclosures": null, "listing_terms": "Conventional", "possession": "Closing & Funding", "special_listing_conditions": "Listed As-Is", "tax_annual_amount": "9611", "tax_year": "2023" } } } ``` application/json Copy Not Found ``` { "error": "Not Found" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `address` required | `string` path | `5730-royal-club-drive-boynton-beach-fl-33437-4265-usa` | full address slug | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `property` | `object` | Property object | ##### Other responses `404` ### Sitemap-Listings-Update-Service `POST` `/run-update` #### Run Update `runUpdate` ##### Response application/json Copy Ok. ``` { "status": "Ok" } ``` ##### Response `200``application/json` 1 fields Ok. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status of the transaction | ## Canonical model - `address` - `property` - `address` - `property` ## Property data it reads - address - property ## Errors `400``404` ## More in Assessment - Previous product: Appraisal - Next product: Property --- # Property # Property The canonical property record at parcel level: address, structure, lot and land use, read by every other collateral product. One parcel, one record. Address, the structure on it, the lot beneath it, and the recorded land use — assembled from the assessor's own record rather than from a listing. Every other collateral product reads from it. Valuation, appraisal intake and tax all address the same parcel identity, so a correction made once is a correction everywhere. ## How it works Assessor records are the source because listing fields are entered by agents, are inconsistent between markets, and do not exist at all for a property that has never been listed. A model trained on self-reported characteristics inherits every one of those errors. The property model documented under Data is the later and larger expression of the same idea, built for jurisdiction-scale extraction rather than for a single loan file. ## Operations ### Workflow `POST` `/transactions` #### Create Transaction `createTransaction` 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 | | ##### Request application/json Copy ``` { "label": "first_transaction", "callback_url": "https://webhook.site/0c1c4e00-79d9-490b-a0f3-bab8b12a61d5" } ``` ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` 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" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string (url)` | URL for receiving events about changes inside transaction | | `label` | `string` | Transaction label | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /get-collection ##### Request application/json Copy ``` { "addresses": [ { "@id": "", "@type": "residential_address", "has_address_line_1_text": { "has_value": "123 Main St" }, "has_city_name": { "has_value": "New York" }, "has_postal_code": { "has_value": "94132" }, "has_state_code": { "has_value": "CA" } } ] } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "avms": [ { "@type": "avm", "@id": "01GC7ZR8FFANRJS8AJACQK1SP3", "has_avm_high_value_range_amount": { "has_value": 265035 }, "has_avm_low_value_range_amount": { "has_value": 213887 }, "has_avm_value_amount": { "has_value": 239461 }, "has_forecast_standard_deviation_score_value": { "has_value": "0.1067982" } } ] } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collection data" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction ID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `201``405` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 200 StaircaseGraphRequestExample0200 StaircaseGraphResponseExample0403404 GetCollectionError404 GetCollectionsError500 application/json Copy Successfully Retrieved Collection ``` { "addresses": [ { "@id": "", "@type": "residential_address", "has_address_line_1_text": { "has_value": "123 Main St" }, "has_city_name": { "has_value": "New York" }, "has_postal_code": { "has_value": "94132" }, "has_state_code": { "has_value": "CA" } } ] } ``` application/json Copy Successfully Retrieved Collection ``` { "avms": [ { "@type": "avm", "@id": "01GC7ZR8FFANRJS8AJACQK1SP3", "has_avm_high_value_range_amount": { "has_value": 265035 }, "has_avm_low_value_range_amount": { "has_value": 213887 }, "has_avm_value_amount": { "has_value": 239461 }, "has_forecast_standard_deviation_score_value": { "has_value": "0.1067982" } } ] } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `200``400` `POST` `/value` #### Valuate Collateral `invokeProductFlow` Invoke Product Valuate Collateral invokes a partner to provide automated valuation modeling for a property. To invoke Valuate Collateral, you will need: - a transaction_id/createTransaction), and - a collection_id/createCollection). Once you have a transaction_id and collection_id, you can send them, along with your Authorization Key (api_key), to as many partners as you want. Simply invoke Valuate Collateral with the same transaction_id and collection_id, but with different partner names. The partner_name parameter is optional. You can retrieve partner_name information by querying the /partners endpoint. Doing so enables you to get automated valuation modeling results from multiple partners, and to see which one provides the optimal response. Valuate Collateral returns, as a synchronous acknowledgement, a new collection_id. The new collection_id represents an empty container which will hold the partner's response once processing has completed. ##### Request InvokeByFlowNameInvokeByTagsInvokeWithRequestDataInvokeWithFlowOptionsCollectionsInvokeWithFlowOptionsRequestDataInvokeByFlowNameOptionsInvokeByVendorNameOptionsInvokeWaterfall application/json Copy ``` { "product_flow_name": "housecanary", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "request_data": {} } ``` application/json Copy ``` { "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "tags": [ "manual_verification" ] } ``` application/json Copy ``` { "product_flow_name": "get-document-from-byte", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "request_data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "Thomas", "last": "Alex" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "12345" } ] }, "roles": { "role": [ { "borrower": { "residences": { "residence": [ { "address": { "line_text": "street 101", "city": "example city", "state": "state", "postal_code": "1234", "street_name": "street 23" } } ] } } } ] } } ] } } ] } } ] } } } ``` application/json Copy ``` { "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "tags": [ "manual_verification" ], "options": { "option1": "test_option" } } ``` application/json Copy ``` { "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "request_data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "Thomas", "last": "Alex" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "12345" } ] }, "roles": { "role": [ { "borrower": { "residences": { "residence": [ { "address": { "line_text": "street 101", "city": "example city", "state": "state", "postal_code": "1234", "street_name": "street 23" } } ] } } } ] } } ] } } ] } } ] } }, "tags": [ "manual_verification" ], "options": { "option1": "test_option" } } ``` application/json Copy ``` { "product_flow_name": "get-document-from-byte", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "options": { "option1": "test_option" } } ``` application/json Copy ``` { "vendor_name": "Vendor_name_example", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "options": { "option1": "test_option" } } ``` application/json Copy ``` { "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "invocation_mode": "waterfall" } ``` ##### Response 201400403404422500 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" ] } ``` application/json Copy Request data failed validation ``` { "message": "{\"data\": [\"Missing data for required field.\"]}" } ``` 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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unprocessable entity 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" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 10 fields | Field | Type | Description | | --- | --- | --- | | `product_flow_name` | `string` | 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. | | `vendor_name` | `string` | Vendor name. Cannot be specified together with product_flow_name. | | `transaction_id` | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `response_collection_id` | `string` | Response Collection ID. | | `callback_url` | `string (uri)` | Callback URL. | | `request_data` | `object` | Request JSON body. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | | `invocation_mode` | `string` | The invocation mode of a product flow single_flow or waterfall, default value single_flow | ##### Response `201``application/json` 12 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `request_collection_id`required | `string` | Request collection ID. | | `response_collection_id`required | `string` | Response collection ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | | `widget_url` | `object` | Product widget_url listening on the connector widget_url | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 1 fields Unprocessable entity error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Platform `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` 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 ##### Response 200 StaircaseGraphResponseExample0200 StaircaseGraphRequestExample0400403404500 application/json Copy Transaction collection retrieved successfully ``` { "avms": [ { "@type": "avm", "@id": "01GC7ZR8FFANRJS8AJACQK1SP3", "has_avm_high_value_range_amount": { "has_value": 265035 }, "has_avm_low_value_range_amount": { "has_value": 213887 }, "has_avm_value_amount": { "has_value": 239461 }, "has_forecast_standard_deviation_score_value": { "has_value": "0.1067982" } } ] } ``` application/json Copy Transaction collection retrieved successfully ``` { "addresses": [ { "@id": "", "@type": "residential_address", "has_address_line_1_text": { "has_value": "123 Main St" }, "has_city_name": { "has_value": "New York" }, "has_postal_code": { "has_value": "94132" }, "has_state_code": { "has_value": "CA" } } ] } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `200` `GET` `/partners` #### Retrieve Partners `getVendors` Retrieve Product Partners Retrieve Partners retrieves: -All the Partners (vendors) configured in the Product Flows configurations. -The Order of the partner in the Product Waterfall Settings or default order in Product Flows if Product Waterfall was not configured. -The status of the partners as active/upcoming according to the configurations of the product flows of these partners (partner will be active if at least one flow is active). ##### Response 200 Example1200 Example2400403404 GetProduct404 text/html500 application/json Copy Successfully retrieved product partners. ``` [ { "Partner": "partner_name", "order": 1, "active": true, "status": "active", "verification_type": "borrower", "byoc": true } ] ``` application/json Copy Successfully retrieved product partners. ``` [ { "Partner": "partner_name", "order": 1, "active": false, "status": "upcoming", "verification_type": "borrower", "byoc": true } ] ``` application/json Copy Validation Error ``` { "message": "3 is not of type ```string```. Failed validating ```type``` in schema[\"properties\"][\"deal_sets\"][\"items\"][0][\"properties\"][\"parties\"][\"items\"][0][\"properties\"][\"customer_transaction_ID\"]:" } ``` 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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `active` | `boolean` query | `false` | Include vendors with active product flows | ##### Response `200``application/json` 6 fields Successfully retrieved product partners. | Field | Type | Description | | --- | --- | --- | | `partner` | `string` | Partner name | | `order` | `number` | Order of the product flows associated with this partner | | `active` | `boolean` | Partner has active flows | | `status` | `string` | Status of the partner | | `verification_type` | `string` | Type of verification | | `byoc` | `boolean` | Specify whether customer should add its own partner credentials or not | ##### Response `400``application/json` 1 fields Validation Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/schema/{data_object}` #### Retrieve Example Schema `retrieveProductSchema` Retrieve Product Schema Retrieve Product Schema retrieves a JSON that provides schema and examples of the configured product. With Product Schema it is possible to have multiple examples and request, response and merged. ##### Response 200 StaircaseGraphResponseExample0200 StaircaseGraphRequestExample0400 DataObjectNotProvided400 text/html403404 GetProduct404 text/html500 application/json Copy Successfully returned the object requested ``` { "avms": [ { "@type": "avm", "@id": "01GC7ZR8FFANRJS8AJACQK1SP3", "has_avm_high_value_range_amount": { "has_value": 265035 }, "has_avm_low_value_range_amount": { "has_value": 213887 }, "has_avm_value_amount": { "has_value": 239461 }, "has_forecast_standard_deviation_score_value": { "has_value": "0.1067982" } } ] } ``` application/json Copy Successfully returned the object requested ``` { "addresses": [ { "@id": "", "@type": "residential_address", "has_address_line_1_text": { "has_value": "123 Main St" }, "has_city_name": { "has_value": "New York" }, "has_postal_code": { "has_value": "94132" }, "has_state_code": { "has_value": "CA" } } ] } ``` application/json Copy Error ``` { "message": "data_object should be any of the following strings: request, response or merged." } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `data_object` required | `string` path | `request` | Data Object | | `version` | `string` query | `v2` | If included restrict retrieval to the version specified | | `return_examples` | `boolean` query | `false` | If included and set to `true`, returns one or more examples. Default to `false` | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `200` ### Setup `POST` `/housecanary/credentials` #### Set Housecanary Credentials `setHousecanaryCredentials` This endpoint is used to set Housecanary Credentials. The payload passed is the username/password keys and values. It is also possible to use Housecanary API Key as the username and API Secret as the password. See the request body examples. ##### Request SetUsernamePasswordExampleSetApiKeyAndSecretExample application/json Copy ``` { "username": "username", "password": "" } ``` application/json Copy ``` { "username": "api_key_value", "password": "" } ``` ##### Response 200400403422500 application/json Copy Setup API Triggered Successfully ``` { "message": "Credentials are saved and verified" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "Invalid request body", "error": "object has missing required properties" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `username`required | `string` | Housecanary username | | `password`required | `string` | Housecanary password | ##### Response `200``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | | `error` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` ## Errors `400``403``404``405``422``500` ## More in Assessment - Previous product: Listing - Next product: Tax --- # Tax # Tax Property tax at parcel level: assessed values, millage, exemptions, and the tax-roll history behind them. A caller sends a parcel and receives its tax position — assessed, exempt and taxable values, the authority levying them, and the roll history year on year. Two consumers with different needs. Escrow calculation needs the current annual obligation; collateral analysis needs the history, because a long gap between assessed and market value is itself a signal. ## How it works The dual listing is real: this is the property side, and Tax under Verification is the borrower side — transcripts and returns. They share a name in the source catalogue and nothing else. The class carrying this data is `tax` in the property model, together with the authority, jurisdiction and exemption classes it points at. ## Dual listing Tax is filed under two categories. The other listing is Tax under Verification , and the recorded specifications resolve there — its 3 operations render on that page. ## Operations ### Workflow `POST` `/products/property-taxes/invocations` #### Invoke Product Flow `InvokeSpecificProductFlow` This endpoint retrieves the Property Taxes for the given property using different partners. #### Usage You can send a request in two different ways: - Using `request_data`: If you provide this parameter, flow invocation would use the data here as input. If you also provide a `transaction_id` in the request body, Response Collection would be created in the related Transaction object. If you don't provide a `transaction_id` we will automatically create a Transaction for you and Response Collection would be created in this new Transaction as well. - Using `transaction_id` and `request_collection_id`: If you already have a request collection, you can provide its details using these two parameters. Note that in this case Response Collection would be created in the provided Transaction. Note: You cannot provide `product_flow_name` and `vendor_name` parameters together. When provided together, simply `product_flow_name` is used. Show the rest #### Retrieving the Invocation Result After invocation, endpoint returns an `invocation_id` which you can poll for its status using /products/property-taxes/invocations/{invocation_id} endpoint. Once the invocation is completed, the Response Collection is populated with these search results. If you would rather receive a callback once the invocation is completed instead of polling it, you can set `callback_url` parameter in the request body. ##### Request Flow Invocation with Collection IDRequest Example application/json Copy ``` { "vendor_name": "ernst", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN" } ``` application/json Copy ``` { "vendor_name": "ernst", "request_data": { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } } ``` ##### Response 201400403404500 application/json Copy Successfully started flow invocation. ``` { "product_flow_name": "ErnstPropertyTaxes", "metadata": {}, "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "STARTED", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `vendor_name`required | `string` | Vendor name. If not specified default vendor will be used.`ernst` | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `request_collection_id`required | `string` | Request Collection ID. | | `response_collection_id` | `string` | Response Collection ID. The response will be saved into this collection if response_collection_id is provided. If not provided, a new collection will be created for response. | | `callback_url` | `string (uri)` | Callback URL. | | `request_data` | `object` | Request Data. If request_collection_id is not provided and request_data is provided, request data will be saved into a new collection and that collection will be used for invocation. | | `addresses`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `has_county_name`required | `object` | — | | `has_value`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code` | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `properties`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `with_value`required | `string[]` | — | | `with_address`required | `string[]` | — | | `property_valuations`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | ##### Response `201``application/json` 7 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID. | | `invocation_status` | `string` | The status of the invocation.`STARTED` | | `transaction_id` | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name.`ErnstPropertyTaxes` | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/property-taxes/invocations/{invocation_id}` #### Retrieve Invocation Status `RetrieveProductFlowInvocationStatus` Retrieve status of a Product Flow Invocation Retrieves the status of running Product flow invocation. ##### Response 200400403404500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "response_collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "metadata": {}, "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "RUNNING", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "product_flow_name": "ErnstPropertyTaxes", "request_collection": { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } }, "response_collection": { "metadata": { "created_at": "2021-09-14T03:36:45.193268-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "data": { "taxes": [ { "@id": "TX1010000", "@type": "property_tax", "with_payment": [ "01FN8GGQ44MPFQPRKX2QW3JZJ7" ], "has_tax_authority_name": { "has_value": "HARRIS COUNTY" }, "has_tax_authority_account_identifier": { "has_value": "TX1010000" }, "has_tax_description": { "has_value": "Tax Bill Installment 1" } }, { "@id": "TX1010339", "@type": "property_tax", "with_payment": [ "01FN8GGQ44W42284VRXP5G53RE" ], "has_tax_authority_name": { "has_value": "HEATHERLOCH MUD (ASMT OF SW)" }, "has_tax_authority_account_identifier": { "has_value": "TX1010339" }, "has_tax_description": { "has_value": "Tax Bill Installment 1" } } ], "payments": [ { "@id": "01FN8GGQ44MPFQPRKX2QW3JZJ7", "@type": "tax_payment", "has_next_payment_due_date": { "has_value": "2022-01-31" }, "has_payment_amount": { "has_value": "3880.99" } }, { "@id": "01FN8GGQ44W42284VRXP5G53RE", "@type": "tax_payment", "has_next_payment_due_date": { "has_value": "2021-01-31" }, "has_payment_amount": { "has_value": "1063.92" } } ] } } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Product flow invocation identifier | ##### Response `200``application/json` 9 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_status`required | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `request_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `response_collection_id` | `string` | Response Collection ID. | | `response_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | — | | `taxes` | `object[]` | — | | `@type` | `string` | — | | `@id` | `string` | — | | `with_payment` | `string[]` | — | | `has_tax_authority_name` | `object` | — | | `has_tax_authority_account_identifier` | `object` | — | | `has_tax_description` | `object` | — | | `payments` | `object[]` | — | | `@type` | `string` | — | | `@id` | `string` | — | | `has_next_payment_due_date` | `object` | — | | `has_payment_amount` | `object` | — | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `callback_url` | `string` | URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished. | | `widget_url` | `string (uri)` | URL of the widget. | | `metadata` | `object` | Response Collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/property-taxes/request-schema` #### Retrieve Request Schema `retrieveRequestSchema` 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. ##### Response 200 Schema200 Schema with Examples400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "properties": { "addresses": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_county_name", "has_state_code", "has_city_name" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "properties": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "with_value", "with_address" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "with_value": { "type": "array", "items": { "type": "string" } }, "with_address": { "type": "array", "items": { "type": "string" } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_property_valuation_amount" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_property_valuation_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } } }, "required": [ "addresses", "properties", "property_valuations" ], "description": "Request Data. If request_collection_id is not provided and request_data is provided, request data will be saved into a new collection and that collection will be used for invocation." } } ``` application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "properties": { "addresses": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_county_name", "has_state_code", "has_city_name" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "properties": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "with_value", "with_address" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "with_value": { "type": "array", "items": { "type": "string" } }, "with_address": { "type": "array", "items": { "type": "string" } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_property_valuation_amount" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_property_valuation_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } } }, "required": [ "addresses", "properties", "property_valuations" ], "description": "Request Data. If request_collection_id is not provided and request_data is provided, request data will be saved into a new collection and that collection will be used for invocation." }, "examples": [ { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Request schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | Schema for the Request Collection | | `examples` | `object` | Each item in the dictionary corresponds to the name of the example and dictionary content is the sample response. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/property-taxes/response-schema` #### Retrieve Response Schema `retrieveResponseSchema` Retrieve Response Schema returns the JSON schema for the response collection, created by an invocation. If you would like to retrieve examples along with the schema, you can provide `return_examples=True` query parameter. ##### Response 200 Schema200 Schema with Examples Response400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "properties": { "taxes": { "type": "array", "items": { "type": "object", "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "with_payment": { "type": "array", "items": { "type": "string" } }, "has_tax_authority_name": { "type": "object", "properties": { "has_value": { "type": "string" } } }, "has_tax_authority_account_identifier": { "type": "object", "properties": { "has_value": { "type": "string" } } }, "has_tax_description": { "type": "object", "properties": { "has_value": { "type": "string" } } } } } }, "payments": { "type": "array", "items": { "type": "object", "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_next_payment_due_date": { "type": "object", "properties": { "has_value": { "type": "string" } } }, "has_payment_amount": { "type": "object", "properties": { "has_value": { "type": "string" } } } } } } } } } ``` application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "properties": { "taxes": { "type": "array", "items": { "type": "object", "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "with_payment": { "type": "array", "items": { "type": "string" } }, "has_tax_authority_name": { "type": "object", "properties": { "has_value": { "type": "string" } } }, "has_tax_authority_account_identifier": { "type": "object", "properties": { "has_value": { "type": "string" } } }, "has_tax_description": { "type": "object", "properties": { "has_value": { "type": "string" } } } } } }, "payments": { "type": "array", "items": { "type": "object", "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_next_payment_due_date": { "type": "object", "properties": { "has_value": { "type": "string" } } }, "has_payment_amount": { "type": "object", "properties": { "has_value": { "type": "string" } } } } } } } }, "examples": [ { "taxes": [ { "@id": "TX1010000", "@type": "property_tax", "with_payment": [ "01FN8GGQ44MPFQPRKX2QW3JZJ7" ], "has_tax_authority_name": { "has_value": "HARRIS COUNTY" }, "has_tax_authority_account_identifier": { "has_value": "TX1010000" }, "has_tax_description": { "has_value": "Tax Bill Installment 1" } }, { "@id": "TX1010339", "@type": "property_tax", "with_payment": [ "01FN8GGQ44W42284VRXP5G53RE" ], "has_tax_authority_name": { "has_value": "HEATHERLOCH MUD (ASMT OF SW)" }, "has_tax_authority_account_identifier": { "has_value": "TX1010339" }, "has_tax_description": { "has_value": "Tax Bill Installment 1" } } ], "payments": [ { "@id": "01FN8GGQ44MPFQPRKX2QW3JZJ7", "@type": "tax_payment", "has_next_payment_due_date": { "has_value": "2022-01-31" }, "has_payment_amount": { "has_value": "3880.99" } }, { "@id": "01FN8GGQ44W42284VRXP5G53RE", "@type": "tax_payment", "has_next_payment_due_date": { "has_value": "2021-01-31" }, "has_payment_amount": { "has_value": "1063.92" } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Response schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | JSON-Schema as a single object | | `examples` | `object` | A key-value pair for the examples. Keys are the example names, while values correspond to the example values for the response collections you can retrieve. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Platform `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /products/property-taxes/invocations ##### Request application/json Copy ``` { "data": { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collectionchr\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction\nID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Request Data. If request_collection_id is not provided and request_data is provided, request data will be saved into a new collection and that collection will be used for invocation. | | `addresses`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `has_county_name`required | `object` | — | | `has_value`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code` | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `properties`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `with_value`required | `string[]` | — | | `with_address`required | `string[]` | — | | `property_valuations`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 403404 GetCollectionError404 GetCollectionsError500 application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 4 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | — | | `collection_id`required | `string` | — | | `metadata`required | `object` | — | | `created_at`required | `string` | — | | `validation`required | `boolean` | — | | `data`required | `object` | — | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` Retrieve Transaction Collections returns the content of a given `collection_id` associated with a specific `transaction_id`. ##### Response 200400403404500 application/json Copy Transaction collection retrieved successfully ``` { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": {} } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Transaction collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given `collection_id` associated with a `transaction_id`. ##### Request application/json Copy ``` { "data": { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } } ``` ##### Response 200400 UpdateCollectionError400 text/html403404 UpdateCollectionError404 text/html500 application/json Copy Collection updated successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Kent" }, "has_state_code": { "has_value": "TX" }, "has_city_name": { "has_value": "Houston" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "property", "with_value": [ "01FMM41S2RM5X2RWJJG2NFH91Z" ], "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ] } ], "property_valuations": [ { "@id": "01FMM41S2RM5X2RWJJG2NFH91Z", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 374900 } } ] } } ``` application/json Copy Error ``` { "description": "Error details.", "message": "Unable to update collection. Please check the collection\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Request Data. If request_collection_id is not provided and request_data is provided, request data will be saved into a new collection and that collection will be used for invocation. | | `addresses`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `has_county_name`required | `object` | — | | `has_value`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code` | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `properties`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `with_value`required | `string[]` | — | | `with_address`required | `string[]` | — | | `property_valuations`required | `object[]` | — | | `@type`required | `string` | — | | `@id`required | `string` | — | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | ##### Response `200``application/json` 4 fields Collection updated successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` ### Operations `POST` `/property-taxes` #### Create Property taxes `post-property-taxes` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Property taxes request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Property taxes request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `GET` `/property-taxes/elements` #### Retrieve Elements `get-property-taxes-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request. | Field | Type | Description | | --- | --- | --- | | `elements` | `object` | List of elements | `POST` `/property-taxes/elements/complete` #### Validate Collection `post-property-taxes-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `collection`required | `object` | — | ##### Response `400``application/json` 2 fields Collection is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/property-taxes/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-property-taxes-status` Retrieve Status checks status of your request. Possible statuses: - REQUEST_MADE - REQUEST_ACCEPTED - WAITING_FOR_RESPONSE - COMPLETED ##### Response 200400 application/json Copy Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Current execution status | ##### Response `400``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | `POST` `/property-taxes/transactions` #### Create Transaction `post-property-taxes-transaction` Create Transaction creates a transaction in Staircase. A transaction in Staircase is an acknowledgement that you want to call a Staircase product. It's a container for everything associated with that product invocation, and is correlated with a collection related to the product (e.g. a document). You need to create a new transaction every time you want to connect with a Staircase product. Staircase then associates everything, from a data and API execution standpoint, to that transaction. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | `POST` `/property-taxes/transactions/{transaction_id}/collections` #### Create Collection `post-property-taxes-collection` Create Collection creates a collection of elements . The elements within the collection are required. ##### Request application/json Copy ``` { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully created. ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `PUT` `/property-taxes/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-property-taxes-collection` Update Collection updates a collection of elements by new elements. ##### Request application/json Copy ``` { "sets": { "set": [ { "properties": { "property": [ { "propety_entry": { "propety_entries": { "datetime": "2020-05-05", "description": "Test Description", "event_type": "TestType" } }, "propety_class": { "propety_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully updated ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "properties": { "property": [ { "property_data": { "property_class": { "datetime": "2020-05-05", "description": "Info", "event_type": "TestEvent" } }, "document_classification": { "document_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `POST` `/tax` #### Create Tax `post-tax` Create Tax creates views of a borrower's tax returns, including IRS documents 4506T, W-2, 1040, 1065, 1098, 1099, 1120, and 5498. ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Tax report request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Tax report request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ## Errors `400``403``404``405``500` ## More in Assessment - Previous product: Property - Next product: Valuation --- # Valuation # Valuation A blended value opinion combining automated valuation, appraisal and listing signal into one number surfaced to pricing. Three signals with different failure modes. An automated model is fast and uniform but blind to condition; an appraisal is condition-aware and slow; a listing shows what the market was asked to pay rather than what it paid. The product returns a blended opinion together with the components behind it. The components are returned, not just the blend. A caller weighing collateral risk needs to know whether the number rests on a recent appraisal or on a model extrapolating from comparables. ## Operations ### Platform `GET` `/partners` #### Retrieve Partners `retrievePartners` Retrieve Partners retrieves an object containing all Partners active for the product and information about them. You can use the `invoke_name` variable to invoke the partner directly in the product invocation. ##### Response 200403 application/json Copy Successfully returned the partner list ``` [ { "company_name": "Partner 1", "invoke_name": "partner_1", "status": "active", "description": "Partner 1 does ...." }, { "company_name": "Partner 2", "invoke_name": "partner_2", "status": "upcoming", "description": "Use Partner 2 if ...." } ] ``` 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" } ``` ##### Response `200``application/json` 4 fields Successfully returned the partner list | Field | Type | Description | | --- | --- | --- | | `company_name` | `string` | Name of the partner | | `invoke_name` | `string` | This string type object can be passed directly into the product invocation | | `status` | `string` | Describes whether the partner is available to use`active``deprecated``upcoming` | | `description` | `string` | Further information on the partner | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | `GET` `/response-elements` #### Retrieve Response Elements `responseElements` Retrieve Response Elements provides a list of elements that will be returned by a partner providing an automated valuation model. ##### Response 200403 application/json Copy Example for the Valuation Elements object ``` { "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.property_valuations.property_valuation[0].avms.avm[0].date": "null,", "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.property_valuations.property_valuation[0].avms.avm[0].high_value_range": "null,", "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.property_valuations.property_valuation[0].avms.avm[0].low_value_range": "null,", "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.property_valuations.property_valuation[0].avms.avm[0].value": null } ``` 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" } ``` ##### Response `200``application/json` 2 fields Elements retrieved successfully | Field | Type | Description | | --- | --- | --- | | `path` | `string` | Contains the path in Staircase language | | `value` | `string` | Enter your own values here | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `400``404``500` `GET` `/schema/{data_object}` #### Retrieve Schema `retrieveSchema` Retrieve Schema retrieves a JSON schema for the request and the response returned by the product. ##### Response 200400 InvalidDataObject400 InvalidVersionValue400 MissingVersionParameter400 InvalidReturnExamplesValue403 application/json Copy Successfully returned the list of elements needed for AUS. ``` { "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "deal_sets": { "type": "object", "properties": { "deal_set": { "type": "array", "items": [ { "type": "object", "properties": { "deals": { "type": "object", "properties": { "deal": { "type": "array", "items": [ { "type": "object", "properties": { "collaterals": { "type": "object", "properties": { "collateral": { "type": "array", "items": [ { "type": "object", "properties": { "subject_property": { "type": "object", "properties": { "address": { "type": "object", "properties": { "line_text": { "type": "string" }, "city": { "type": "string" }, "state_code": { "type": "string" }, "postal_code": { "type": "string" } }, "required": [ "line_text", "postal_code" ] } }, "required": [ "address" ] } }, "required": [ "subject_property" ] } ] } }, "required": [ "collateral" ] } }, "required": [ "collaterals" ] } ] } }, "required": [ "deal" ] } }, "required": [ "deals" ] } ] } }, "required": [ "deal_set" ] } }, "required": [ "deal_sets" ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid data object values: request, response" } ``` application/json Copy Error ``` { "message": "Please provide one of valid version values: v0" } ``` application/json Copy Error ``` { "message": "Please make sure your query parameters contains version parameter." } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values: true, false" } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Description | | --- | --- | --- | | `data_object` required | `string` path | Describes the particular data object you are getting a schema for. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | | `version` required | `string` query | Defines the version of the Staircase language you want the JSON to return in. | ##### Response `200``application/json` 1 fields Successfully returned the list of elements needed for AUS. | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | — | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `retrieveCollections` Retrieve Transaction Collections returns all collections that associated with a transaction_id. ##### Response 200403404 application/json Copy Successfully Retrieved Collection ``` [ { "metadata": { "created_at": "03/02/2021, 3:19:37 AM EST", "last_updated_at": "03/02/2021, 6:06:56 AM EST", "validation": false }, "collection_id": "01EZZEJ3W6MHW9W75CYHEC9PAZ", "transaction_id": "01EZZEHJY0J6Y2C6R2C26C1V2F", "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "city": "Lafayette", "line_text": 1, "postal_code": "705061", "state_code": "LA" } } } ] } } ] } } ] } } }, { "metadata": { "created_at": "03/02/2021, 5:19:37 AM EST", "last_updated_at": "03/02/2021, 7:06:56 AM EST", "validation": false }, "collection_id": "01EZZEJ3W6MHW9W75CYHEC9PAZ", "transaction_id": "01EZZEHJY0J6Y2C6R2C26C1V2F", "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "city": "Lafayette", "line_text": 1, "postal_code": "70506", "state_code": "LA" } } } ] } } ] } } ] } } } ] ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01EZZEHJY0J6Y2C6R2C26C1V2F` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Customer Input Data | | `metadata` | `object` | Staircase metadata | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01EZZEHJY0J6Y2C6R2C26C1V2F` | | `collection_id` | `string (ulid)` | Staircase Collection IdentifierExample `01EZZEJ3W6MHW9W75CYHEC9PAZ` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `400` `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given collection_id associated with a transaction_id. ##### Response 400 UpdateCollectionError400 MissingTransactionID400 MissingCollectionID403404 application/json Copy Error ``` { "message": "Unable to update collection. Please check the collection data" } ``` application/json Copy Error ``` { "message": "transaction_id value is missing" } ``` application/json Copy Error ``` { "message": "collection_id value is missing" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01EZZEHJY0J6Y2C6R2C26C1V2F` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01EZZEJ3W6MHW9W75CYHEC9PAZ` | Staircase collection_id | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `200` `POST` `/request-elements/complete` #### Validate Collection `validateCollection` Validate Collection allows you to validate an input collection prior to submitting to our partners. This service will return messages with all the corrections you need to make to your collection in order for it to be accepted by our partner call. ##### Request application/json Copy ``` { "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "line_text": "110 Ocean Park Blvd Unit 205", "city": "Santa Monica", "postal_code": "90405", "state_code": "CA" } } } ] } } ] } } ] } }, "metadata": {} } ``` ##### Response 200400403 application/json Copy Collection is valid ``` { "message": "Collection is valid." } ``` application/json Copy Validation Error ``` { "message": "1 is not of type 'string'. Failed validating 'type' in schema['properties']['deal_sets']['properties']['deal_set']['items']['properties']['deals']['properties']['deal']['items']['properties']['collaterals']['properties']['collateral']['items']['properties']['subject_property']['properties']['address']['properties']['line_text']:" } ``` 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" } ``` ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Customer Input Data | | `metadata` | `object` | Staircase metadata | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01EZZEHJY0J6Y2C6R2C26C1V2F` | | `collection_id` | `string (ulid)` | Staircase Collection IdentifierExample `01EZZEJ3W6MHW9W75CYHEC9PAZ` | ##### Response `200``application/json` 1 fields Collection is valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Validation Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `500` ### Workflow `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called transaction_id. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. ##### Response 201400403 application/json Copy Transaction created successfully ``` { "transaction_id": { "$ref": "#/components/schemas/TransactionId/example" } } ``` application/json Copy Transaction creation unsuccessfully ``` { "error": "Response status not OK while creating a new transaction, status_code: [01EZZEHJY0J6Y2C6R2C26C1V2F]", "error_code": 4050 } ``` 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" } ``` ##### Response `201``application/json` 1 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01EZZEHJY0J6Y2C6R2C26C1V2F` | ##### Response `400``application/json` 2 fields Transaction creation unsuccessfully | Field | Type | Description | | --- | --- | --- | | `error` | `string` | — | | `error_code` | `integer` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | `GET` `/request-elements` #### Retrieve Request Elements `requestElements` Retrieve Request Elements retrieves a list of elements needed to invoke a partner for valuation. ##### Response 200403 application/json Copy Example for the Valuation Request Elements object ``` { "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.line_text": null, "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.city": null, "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.postal_code": null, "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.state_code": null } ``` 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" } ``` ##### Response `200``application/json` 2 fields Elements retrieved successfully | Field | Type | Description | | --- | --- | --- | | `path` | `string` | Contains the path in Staircase language | | `value` | `string` | Enter your own values here | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `400``500` `POST` `/build-payload` #### Build JSON Payload `retrieveExampleJSON` Build JSON Payload helps you build a JSON payload using the JSON paths from Retrieve Request Elements/requestElements) or Retrieve Response Elements/responseElements). You can use this payload to either: - submit a request to valuate collateral. - simulate a response containing collateral valuation details. Simply add key/value pairs of path/desired output and POST to /build-payload. It will then build a nested JSON. You can find examples below. ##### Request application/json Copy ``` { "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.line_text": "112 Southfield Pkwy", "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.city": "Lafayette", "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.postal_code": "LA", "$.deal_sets.deal_set[0].deals.deal[0].collaterals.collateral[0].subject_property.address.state_code": "70506" } ``` ##### Response 200403 application/json Copy Valuation Payload. ``` { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "line_text": "110 Ocean Park Blvd Unit 205", "city": "Santa Monica", "postal_code": "90405", "state_code": "CA" } } } ] } } ] } } ] } } ``` 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" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `path` | `string` | Contains the path in Staircase language | | `value` | `string` | Enter your own values here | ##### Response `200``application/json` 1 fields Valuation Payload. | Field | Type | Description | | --- | --- | --- | | `deal_sets` | `object` | — | | `deal_set` | `object[]` | — | | `deals` | `object` | — | | `deal` | `object[]` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `400``404``500` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of elements required for valuation. A collection contains a digital representation of the borrower and is identified by collection_id. A collection_id is passed to the partner when requesting valuation. ##### Request EstatedExampleHouseCanaryExample application/json Copy ``` { "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "line_text": "110 Ocean Park Blvd Unit 205", "city": "Santa Monica", "postal_code": "90405", "state_code": "CA" } } } ] } } ] } } ] } }, "metadata": {} } ``` application/json Copy ``` { "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "line_text": "902 S 10th St", "city": "Lake City", "postal_code": "55041", "state_code": "MN" } } } ] } } ] } } ] } }, "metadata": {} } ``` ##### Response 201400403404 application/json Copy Collection created successfully ``` { "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "address": { "line_text": "110 Ocean Park Blvd Unit 205", "city": "Santa Monica", "postal_code": "90405", "state_code": "CA" } } } ] } } ] } } ] } }, "metadata": {}, "collection_id": "01EZZEJ3W6MHW9W75CYHEC9PAZ", "transaction_id": "01EZZEHJY0J6Y2C6R2C26C1V2F" } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collection data" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction Id" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01EZZEHJY0J6Y2C6R2C26C1V2F` | Staircase Transaction Identifier | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `deal_sets` | `object` | — | | `deal_set` | `object[]` | — | | `deals` | `object` | — | | `metadata` | `object` | Staircase metadata | ##### Response `201``application/json` 1 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string (ulid)` | Staircase Collection IdentifierExample `01EZZEJ3W6MHW9W75CYHEC9PAZ` | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/valuation` #### Valuate Collateral `valuation` Valuate Collateral invokes a partner to provide automated valuation modeling for a property. To invoke Valuate Collateral, you will need: - a transaction_id/createTransaction), and - a collection_id/createCollection). Once you have a transaction_id and collection_id, you can send them, along with your Authorization Key (api_key), to as many partners as you want. Simply invoke Valuate Collateral with the same transaction_id and collection_id, but with different partner names. The partner_name parameter is optional. You can retrieve partner_name information by querying the /partners endpoint. Doing so enables you to get automated valuation modeling results from multiple partners, and to see which one provides the optimal response. Valuate Collateral returns, as a synchronous acknowledgement, a new collection_id. The new collection_id represents an empty container which will hold the partner's response once processing has completed. ##### Response 201400 MissingTransactionID400 MissingCollectionID400 InvalidPartnerName400 InvalidJSONBody403404 GetCollectionError404 PostalCodeNotFoundError application/json Copy Request for valuation successfully. ``` { "transaction_id": "01EZZEHJY0J6Y2C6R2C26C1V2F", "collection_id": "01EZZEJ3W6MHW9W75CYHEC9PAZ" } ``` application/json Copy General error ``` { "message": "transaction_id value is missing" } ``` application/json Copy General error ``` { "message": "collection_id value is missing" } ``` application/json Copy General error ``` { "message": "Please provide a valid partner name. To get available partners, you can use /partners endpoint." } ``` application/json Copy General error ``` { "message": "Request body had invalid format. Please provide a valid JSON" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check input collection id" } ``` application/json Copy Resource not found ``` { "message": "Unable to find city and state for given postal code. Please check the postal code or try by giving city and state code" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string (ulid)` | Staircase Transaction IdentifierExample `01EZZEHJY0J6Y2C6R2C26C1V2F` | | `collection_id`required | `string (ulid)` | Staircase Collection IdentifierExample `01EZZEJ3W6MHW9W75CYHEC9PAZ` | | `partner_name` | `string` | To get available partners, you can use /partners endpoint | ##### Response `201``application/json` 2 fields Request for valuation successfully. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01EZZEHJY0J6Y2C6R2C26C1V2F` | | `collection_id` | `string (ulid)` | Staircase Collection IdentifierExample `01EZZEJ3W6MHW9W75CYHEC9PAZ` | ##### Response `400``application/json` 1 fields General error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 1 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/status/{transaction_id}/{collection_id}` #### Retrieve Status `retrieveStatus` Retrieve Status determines if a partner has completed valuation. ##### Response 400 MissingTransactionID400 MissingCollectionID403404 application/json Copy Error ``` { "message": "transaction_id value is missing" } ``` application/json Copy Error ``` { "message": "collection_id value is missing" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get status. Please check the given ids" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01EZZEHJY0J6Y2C6R2C26C1V2F` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01EZZEJ3W6MHW9W75CYHEC9PAZ` | Staircase collection_id | ##### Response `200``application/json` 1 fields Request for getting AVM request status. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Potential status responses: 'IN_PROGRESS', 'WAITING_FOR_RESPONSE', 'COMPLETED', 'ERROR' | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `500` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given collection_id associated with a transaction_id. ##### Response 200400 MissingTransactionID400 MissingCollectionID403404 application/json Copy Successfully Retrieved Collection ``` { "metadata": { "created_at": "03/02/2021, 6:20:55 AM EST", "last_updated_at": "03/02/2021, 6:21:12 AM EST", "partner_name": "estated", "validation": false }, "collection_id": "01EZZEJ3W6MHW9W75CYHEC9PAZ", "transaction_id": "01EZZEHJY0J6Y2C6R2C26C1V2F", "data": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "collaterals": { "collateral": [ { "subject_property": { "property_valuations": { "property_valuation": [ { "avms": { "avm": [ { "date": "2020-01-30", "high_value_range": 118650, "low_value_range": 91350, "value": 105000 } ] } } ] } } } ] } } ] } } ] } } } ``` application/json Copy Error ``` { "message": "transaction_id value is missing" } ``` application/json Copy Error ``` { "message": "collection_id value is missing" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01EZZEHJY0J6Y2C6R2C26C1V2F` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01EZZEJ3W6MHW9W75CYHEC9PAZ` | Staircase collection_id | ##### Response `200``application/json` 4 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `data` | `object` | Customer Input Data | | `metadata` | `object` | Staircase metadata | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01EZZEHJY0J6Y2C6R2C26C1V2F` | | `collection_id` | `string (ulid)` | Staircase Collection IdentifierExample `01EZZEJ3W6MHW9W75CYHEC9PAZ` | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Operations `POST` `/avm` #### Create AVM `post-avm` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy AVM request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields AVM request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `GET` `/avm/elements` #### Retrieve Elements `get-avm-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request. | Field | Type | Description | | --- | --- | --- | | `elements` | `object` | List of elements | `POST` `/avm/elements/complete` #### Validate Collection `post-avm-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `collection`required | `object` | — | ##### Response `400``application/json` 2 fields Collection is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/avm/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-avm-status` Retrieve Status checks status of your request. Possible statuses: - REQUEST_MADE - REQUEST_ACCEPTED - WAITING_FOR_RESPONSE - COMPLETED ##### Response 200400 application/json Copy Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Current execution status | ##### Response `400``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | `POST` `/avm/transactions` #### Create Transaction `post-avm-transaction` Create Transaction creates a transaction in Staircase. A transaction in Staircase is an acknowledgement that you want to call a Staircase product. It's a container for everything associated with that product invocation, and is correlated with a collection related to the product (e.g. a document). You need to create a new transaction every time you want to connect with a Staircase product. Staircase then associates everything, from a data and API execution standpoint, to that transaction. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | `POST` `/avm/transactions/{transaction_id}/collections` #### Create Collection `post-avm-collection` Create Collection creates a collection of elements . The elements within the collection are required. ##### Request application/json Copy ``` { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully created. ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `PUT` `/avm/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-avm-collection` Update Collection updates a collection of elements by new elements. ##### Request application/json Copy ``` { "sets": { "set": [ { "properties": { "property": [ { "propety_entry": { "propety_entries": { "datetime": "2020-05-05", "description": "Test Description", "event_type": "TestType" } }, "propety_class": { "propety_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully updated ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "properties": { "property": [ { "property_data": { "property_class": { "datetime": "2020-05-05", "description": "Info", "event_type": "TestEvent" } }, "document_classification": { "document_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `GET` `/info` #### Info endpoint Placeholder endpoint. As this is a language repo, it must be used in conjunction with the Translator Service. ##### Other responses `200` `POST` `/inspection` #### Create Inspection `post-inspection` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Inspection request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Inspection request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `GET` `/inspection/elements` #### Retrieve Elements `get-inspection-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request. | Field | Type | Description | | --- | --- | --- | | `elements` | `object` | List of elements | `POST` `/inspection/elements/complete` #### Validate Collection `post-inspection-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `collection`required | `object` | — | ##### Response `400``application/json` 2 fields Collection is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/inspection/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-inspection-status` Retrieve Status checks status of your request. Possible statuses: - REQUEST_MADE - REQUEST_ACCEPTED - WAITING_FOR_RESPONSE - COMPLETED ##### Response 200400 application/json Copy Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Current execution status | ##### Response `400``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | `POST` `/inspection/transactions` #### Create Transaction `post-inspection-transaction` Create Transaction creates a transaction in Staircase. A transaction in Staircase is an acknowledgement that you want to call a Staircase product. It's a container for everything associated with that product invocation, and is correlated with a collection related to the product (e.g. a document). You need to create a new transaction every time you want to connect with a Staircase product. Staircase then associates everything, from a data and API execution standpoint, to that transaction. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | `POST` `/inspection/transactions/{transaction_id}/collections` #### Create Collection `post-inspection-collection` Create Collection creates a collection of elements . The elements within the collection are required. ##### Request application/json Copy ``` { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully created. ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `PUT` `/inspection/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-inspection-collection` Update Collection updates a collection of elements by new elements. ##### Request application/json Copy ``` { "sets": { "set": [ { "properties": { "property": [ { "propety_entry": { "propety_entries": { "datetime": "2020-05-05", "description": "Test Description", "event_type": "TestType" } }, "propety_class": { "propety_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully updated ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "properties": { "property": [ { "property_data": { "property_class": { "datetime": "2020-05-05", "description": "Info", "event_type": "TestEvent" } }, "document_classification": { "document_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | ## Errors `400``403``404``422``500` ## More in Assessment - Previous product: Tax --- # Automation # Automation Automated pre-approval, income qualification, post-close boarding and reporting. Move the loan without a human. Automation acts on verified inputs rather than gathering them. Each product here sits downstream of the verification and contract products and produces a decision, a calculation or a transfer that would otherwise be a person's task. The decision is only as good as its inputs, which is why the pre-approval product refuses self-reported figures: every input it consumes carries which vendor produced it and when. ## Products In the order the value chain runs. 1. Approval has a recorded specification 1. Boarding has a recorded specification 1. Income --- # Approval # Approval An automated pre-approval issued from verified inputs, without an underwriter in the loop. Given verified identity, credit, income, assets and a priced product, the product issues a conditional approval and generates the letter. The conditions it carries are the checks that have not yet been satisfied, stated explicitly. The borrower-facing flow is configurable through the API rather than by deployment: branding, the opening screen, and what happens after issuance — including pushing the resulting file into the lender's origination system. ## How it works The decision is only as good as its inputs, so the product does not accept self-reported figures. Every input it consumes carries which vendor produced it and when, and an input without that provenance is treated as unverified. The conversational flow that gathers those inputs is documented under the consumer application. ## Operations ### After Actions `GET` `/after-actions` #### Retrieve All After Actions `getAfterAllActions` Retrieve After Actions Retrieve all existing after actions in the pre-approval application. ##### Response 403500 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` `DELETE` `/after-actions/{type}` #### Delete After Action `deleteAfterAction` ##### Response 200403500 application/json Copy Create After Action API Triggered Successfully ``` { "type": "success-page", "value": "SIMPLE_SUCCESS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` required | `string` path | `success-page` | After Action type | ##### Response `200``application/json` 2 fields Create After Action API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`success-page` | | `value` | `string` | Value`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `POST` `/after-actions/{type}` #### Create After Action `createAfterAction` ##### Request CreateSuccessPageAfterActionCreateLosVendorAfterAction application/json Copy ``` { "type": "SIMPLE_SUCCESS" } ``` application/json Copy ``` { "los_vendor": "Encompass" } ``` ##### Response 201403500 application/json Copy Create After Action API Triggered Successfully ``` { "type": "success-page", "value": "SIMPLE_SUCCESS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` required | `string` path | `success-page` | After Action type | ##### Response `201``application/json` 2 fields Create After Action API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`success-page` | | `value` | `string` | Value`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `GET` `/after-actions/{type}` #### Retrieve Settings `getAfterAction` Retrieve After Action Retrieve after action that describe a pre-approval application. ##### Response 200403500 application/json Copy Retrieve Flows ``` { "type": "success-page", "value": "SIMPLE_SUCCESS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` required | `string` path | `success-page` | After Action type | ##### Response `200``application/json` 2 fields Retrieve Flows | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`success-page` | | `value` | `string` | Value`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/after-actions/success-page` #### Success Page Create `createSuccessPageAfterAction` Create Success Page After Action Create Success Page After Action. You can define one of 2 types: `SIMPLE_SUCCESS` or `WITH_AUS_PDFs`. `SIMPLE_SUCCESS` will display simple success page, while `WITH_AUS_PDFs` - will also display links to all the documents AUS product provide. ##### Request application/json Copy ``` { "type": "SIMPLE_SUCCESS" } ``` ##### Response 201403500 application/json Copy Create Success Page Triggered Successfully ``` { "type": "SIMPLE_SUCCESS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `type`required | `string` | Type`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `201``application/json` 1 fields Create Success Page Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `GET` `/after-actions/success-page` #### Success Page Retrieve `getSuccessPage` Retrieve Success Page ##### Response 200403500 application/json Copy Retrieve Success Page ``` { "type": "SIMPLE_SUCCESS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Success Page | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `PUT` `/after-actions/{type}` #### Update After Action `updateAfterAction` Update After Action that describe a pre-approval application. ##### Response 200403 application/json Copy Retrieve Flows ``` { "type": "success-page", "value": "SIMPLE_SUCCESS" } ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` required | `string` path | `success-page` | After Action type | ##### Response `200``application/json` 2 fields Retrieve Flows | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`success-page` | | `value` | `string` | Value`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `404` `PUT` `/after-actions/success-page` #### Success Page Update `UpdateSuccessPageAfterAction` Update Success Page After Action Update Success Page After Action. You can define one of 2 types: `SIMPLE_SUCCESS` or `WITH_AUS_PDFs`. `SIMPLE_SUCCESS` will display simple success page, while `WITH_AUS_PDFs` - will also display links to all the documents AUS product provide. ##### Request application/json Copy ``` { "type": "SIMPLE_SUCCESS" } ``` ##### Response 201403500 application/json Copy Create Success Page Triggered Successfully ``` { "type": "SIMPLE_SUCCESS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `type`required | `string` | Type`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `201``application/json` 1 fields Create Success Page Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`SIMPLE_SUCCESS``WITH_AUS_PDFs` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `POST` `/after-actions/los-push` #### LOS Push Create `createLosPushAfterAction` Create LOS Push After Action Create LOS Push After Action. This action will use result collection and will send it to an appropriate LOS Adapters. Right now we support only Encompass Output Adapter ##### Request application/json Copy ``` { "los_vendor": "Encompass" } ``` ##### Response 201403500 application/json Copy Create LOS Push Triggered Successfully ``` { "los_vendor": "Encompass" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `los_vendor`required | `string` | LOS Vendor name`Byte``Encompass` | ##### Response `201``application/json` 2 fields Create LOS Push Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`los-push` | | `vendor` | `string` | Vendor`Byte``Encompass` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `GET` `/after-actions/los-push` #### LOS Push Retrieve `getLosPush` Retrieve LOS Push After Action Retrieve LOS Push ##### Response 200403500 application/json Copy Retrieve LOS Push ``` { "los_vendor": "Encompass" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 2 fields Retrieve LOS Push | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`los-push` | | `vendor` | `string` | Vendor`Byte``Encompass` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `PUT` `/after-actions/los-push` #### LOS Push Update `updateLosPushAfterAction` Update LOS Push After Action Update LOS Push After Action. This action will use result collection and will send it to an appropriate LOS Adapters. Right now we support only Encompass Output Adapter ##### Request application/json Copy ``` { "los_vendor": "Encompass" } ``` ##### Response 201403500 application/json Copy Create LOS Push Triggered Successfully ``` { "los_vendor": "Encompass" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `los_vendor`required | `string` | LOS Vendor name`Byte``Encompass` | ##### Response `201``application/json` 2 fields Create LOS Push Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Type`los-push` | | `vendor` | `string` | Vendor`Byte``Encompass` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `POST` `/after-actions/email-notification` #### Email Send Create `createSendEmailAfterAction` Create Email Send After Action Create Email Send After Action. ##### Request application/json Copy ``` { "notify_emails": [ "email1@email.com", "email2@email.com" ] } ``` ##### Response 201403500 application/json Copy Create Send Email Request Triggered Successfully ``` { "notify_emails": [ "email1@email.com", "email2@email.com" ] } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `email_send`required | `boolean` | After action | ##### Response `201``application/json` 1 fields Create Send Email Request Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `email_send`required | `boolean` | After action | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/after-actions/email-notification` #### Email Send Retrieve `getEmailSend` Retrieve Email Send After Action Retrieve Email Send ##### Response 200403500 application/json Copy Retrieve Email Send ``` { "notify_emails": [ "email1@email.com", "email2@email.com" ] } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Email Send | Field | Type | Description | | --- | --- | --- | | `email_send`required | `boolean` | After action | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `PUT` `/after-actions/email-notification` #### Email Send Update `updateEmailSendAfterAction` Update Email Send After Action Update Email Send After Action. ##### Request application/json Copy ``` { "notify_emails": [ "email1@email.com", "email2@email.com" ] } ``` ##### Response 201403500 application/json Copy Update Email Send Request Triggered Successfully ``` { "notify_emails": [ "email1@email.com", "email2@email.com" ] } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `email_send`required | `boolean` | After action | ##### Response `201``application/json` 1 fields Update Email Send Request Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `email_send`required | `boolean` | After action | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` ### Console `PUT` `/archive-document/{transaction_id}` #### Get doc `get-docs-archtra` Put doc ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `transaction_id` required | `string` path | `example` | transaction_id | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `DELETE` `/documents/{transaction_id}` #### Get doc `del-doc` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | | `transaction_id` required | `string` path | `example` | transaction_id | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/get-documents` #### Get doc `get-docs` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/get-documents/archived` #### Get doc `get-docs-arch` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `PUT` `/password` #### Get doc `password` Put doc ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/save-document` #### Sign In `ssave` Sign in Sign In ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/sign-in` #### Sign In `sign-in` Sign in Sign In ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/sign-up` #### Sign Up `sign-up` Sign up Sign Up ##### Request application/json Copy An example of a payload. ``` { "email": "john.doe@company.com", "password": "XXXXX" } ``` ##### Response application/json Copy OK. ``` { "message": "success" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `` | Key used to identify the API usage plan | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `email`required | `string` | Email of accountExample `john.doe@company.com` | | `password`required | `string` | Password of accountExample `XXXXX` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Data Bank `GET` `/data-bank` #### Retrieve Data-Bank `getDataBank` Retrieve Pre-Approval Data-Bank Retrieve Pre-Approval Data-Bank. Data bank will be returned in form of Persistence Collection defined by Staircase Lexicon ##### Response 200403500 application/json Copy Retrieve Flows ``` { "people": [ { "@id": "7fd03afb-6b64-4943-86bd-d24d9aa47c0b", "@type": "borrower", "has_marital_status_type": { "has_value": "unmarried" } } ] } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `200` `PUT` `/data-bank` #### Update Data-Bank `updateDataBank` Update Pre-Approval Data-Bank Update Pre-Approval Data-Bank. To be able to update Data bank it is required to use valid data in form Staircase Language. ##### Request application/json Copy ``` { "people": [ { "@id": "7fd03afb-6b64-4943-86bd-d24d9aa47c0b", "@type": "borrower", "has_marital_status_type": { "has_value": "unmarried" } } ] } ``` ##### Response 201403500 application/json Copy Retrieve Flows ``` { "@id": "7fd03afb-6b64-4943-86bd-d24d9aa47c0b", "@type": "borrower", "has_marital_status_type": "unmarried" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `201` ### Executions `GET` `/executions` #### Retrieve Borrowers Executions `getExecutions` Retrieve a list of borrower-executed workflows. ##### Response 200403500 application/json Copy Retrieve Flows ``` { "message": "The product has encountered an internal server error" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Flows | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Flows `POST` `/flows` #### Create Flow `createFlow` Create a workflow for a pre-approval application. Flow types can be SMART, STATED or VERIFIED. A `SMART` flow collects data through technology partner only when it is required. A `STATED` flow collects data directly from the borrower. For a `VERIFIED` flow, data is collected and/or verified through a technology partner. ##### Request application/json Copy ``` { "type": "STATED" } ``` ##### Response 201403500 application/json Copy Create Flow API Triggered Successfully ``` { "type": "SMART", "brand_color": "#AAAAAA", "@id": "9c39b029-409e-4f78-b72e-8f1d05b17940" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `type`required | `string` | Flow type`SMART``STATED``VERIFIED` | ##### Response `201``application/json` 1 fields Create Flow API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Flow Type`SMART``STATED``VERIFIED` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `GET` `/flows/{id}` #### Retrieve Flow `getFlow` Retrieve a specific workflow that has been created for a pre-approval application. ##### Response 200403404 application/json Copy Retrieve Job ``` { "value": { "brand_color": "#AAAAAA", "@id": "9c39b029-409e-4f78-b72e-8f1d05b17940", "@type": "SMART" } } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Flow not found" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `example` | Flow id | ##### Response `200``application/json` 3 fields Retrieve Job | Field | Type | Description | | --- | --- | --- | | `brand_color` | `string` | Brand color | | `@id` | `string` | — | | `@type` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `GET` `/flows` #### Retrieve All Flows `listFlows` Retrieve all existing workflows that have been created for a pre-approval application. ##### Response 200403500 application/json Copy Retrieve Flows ``` { "message": "The product has encountered an internal server error" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Flows | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `DELETE` `/flows/{id}` #### Delete Flow `deleteFlow` Update Flow ##### Response 200403404 application/json Copy Update an existing flow that has been created for a pre-approval application. ``` { "value": { "message": "Success!" } } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Job not found" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `Id` | Flow id | ##### Response `200``application/json` 1 fields Update an existing flow that has been created for a pre-approval application. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Delete Result | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | `PUT` `/flows/{id}` #### Update Flow `updateFlow` ##### Request application/json Copy ``` { "type": "STATED" } ``` ##### Response 200403404 application/json Copy Update an existing flow that has been created for a pre-approval application. ``` { "value": { "brand_color": "#AAAAAA", "@id": "9c39b029-409e-4f78-b72e-8f1d05b17940", "@type": "CLASSIFY" } } ``` 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" } ``` application/json Copy Not Found ``` { "value": { "message": "Flow not found" } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `id` required | `string` path | `Id` | Flow id | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `type`required | `string` | Flow type`CLASSIFY``STATED``VERIFIED` | ##### Response `200``application/json` 3 fields Update an existing flow that has been created for a pre-approval application. | Field | Type | Description | | --- | --- | --- | | `brand_color` | `string` | Brand color | | `@id` | `string` | — | | `@type` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Not Found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ### Links `GET` `/links` #### Retrieve Link `getLink` Retrieves a custom web link for a pre-approval application. Lenders can use the web link on their own websites and send it to prospective borrowers. ##### Response 200403500 application/json Copy Retrieve Flows ``` { "type": "SMART", "brand_color": "#AAAAAA", "@id": "9c39b029-409e-4f78-b72e-8f1d05b17940" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` required | `string` query | `borrower_link` | Link type | ##### Response `200``application/json` 1 fields Retrieve Flows | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Flow Type`SMART``STATED``VERIFIED` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Self Checks `GET` `/self-checks` #### Retrieve Self Checks `getSelfChecks` Retrieves all existing self-checks ##### Response 200 GetJobResp200 application/json403500 application/json Copy Retrieve Self Checks ``` [ { "job_name": "job_name", "description": "description", "trigger_name": "trigger_name", "status": "FAILED", "updated_at": "2020-07-21 15:35:36.109000+00:00" } ] ``` application/json Copy Retrieve Self Checks ``` success-page ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 5 fields Retrieve Self Checks | Field | Type | Description | | --- | --- | --- | | `job_name` | `string` | — | | `trigger_name` | `string` | — | | `description` | `string` | — | | `updated_at` | `string` | — | | `status` | `string` | `FAILED``SUCCEEDED` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Settings `POST` `/settings` #### Create Settings `createSettings` Create settings that describe a pre-approval application. ##### Request application/json Copy ``` { "type": "brand_color" } ``` ##### Response 201403500 application/json Copy Create Setting API Triggered Successfully ``` { "type": "SMART", "brand_color": "#AAAAAA", "@id": "9c39b029-409e-4f78-b72e-8f1d05b17940" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `type`required | `string` | Setting type`brand_color` | ##### Response `201``application/json` 1 fields Create Setting API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Flow Type`SMART``STATED``VERIFIED` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `GET` `/settings` #### Retrieve Settings `getSettings` Retrieve settings that describe a pre-approval application. ##### Response 200403500 application/json Copy Retrieve Flows ``` { "type": "SMART", "brand_color": "#AAAAAA", "@id": "9c39b029-409e-4f78-b72e-8f1d05b17940" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `type` | `string` query | `borrower_link` | Flow type | ##### Response `200``application/json` 1 fields Retrieve Flows | Field | Type | Description | | --- | --- | --- | | `type` | `string` | Flow Type`SMART``STATED``VERIFIED` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/settings/brand_color` #### Brand Color Create `createBrandColorSetting` Create Brand Color Create Brand Color Setting. You can define only HEX string. ##### Request application/json Copy ``` { "brand_color": "#FFFFFF" } ``` ##### Response 201403500 application/json Copy Create Brand Color Triggered Successfully ``` { "brand_color": "#FFFFFF" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `brand_color`required | `string` | Brand Color | ##### Response `201``application/json` 1 fields Create Brand Color Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `brand_color`required | `string` | Brand Color | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `POST` `/settings/company_name` #### Company Name Create `createCompanyNameSetting` Create Company Name Create Company Name Setting. You can define only string. ##### Request application/json Copy ``` { "company_name": "Staircase" } ``` ##### Response 201403500 application/json Copy Create Company Name Triggered Successfully ``` { "company_name": "Staircase" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `company_name`required | `string` | Company Name | ##### Response `201``application/json` 1 fields Create Company Name Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `company_name`required | `string` | Company Name | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `PUT` `/settings` #### Update Setting `updateSetting` Update settings that describe a pre-approval application. ##### Response 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" } ``` ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `204``404` `GET` `/settings/brand_color` #### Brand Color Retrieve `getBrandColorSetting` Retrieve Brand Color Setting Retrieve Brand Color ##### Response 200403500 application/json Copy Retrieve Brand Color ``` { "brand_color": "#FFFFFF" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Brand Color | Field | Type | Description | | --- | --- | --- | | `brand_color`required | `string` | Brand Color | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `GET` `/settings/company_name` #### Company Name Retrieve `getCompanyNameSetting` Retrieve Company Name Setting Retrieve Company Name ##### Response 200403500 application/json Copy Retrieve Company Name ``` { "company_name": "Staircase" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Company Name | Field | Type | Description | | --- | --- | --- | | `company_name`required | `string` | Company Name | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `PUT` `/settings/brand_color` #### Brand Color Update `updateSettingBrandColor` Update Brand Color Setting Update Brand Color ##### Request application/json Copy ``` { "brand_color": "#FFFFFF" } ``` ##### Response application/json Copy Update Brand Color ``` { "brand_color": "#FFFFFF" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `brand_color`required | `string` | Brand Color | ##### Response `200``application/json` 1 fields Update Brand Color | Field | Type | Description | | --- | --- | --- | | `brand_color`required | `string` | Brand Color | `PUT` `/settings/company_name` #### Company Name Update `updateSettingCompanyName` Update Company Name Setting Update Company Name ##### Request application/json Copy ``` { "company_name": "Staircase" } ``` ##### Response application/json Copy Update Company Name ``` { "company_name": "Staircase" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `company_name`required | `string` | Company Name | ##### Response `200``application/json` 1 fields Update Company Name | Field | Type | Description | | --- | --- | --- | | `company_name`required | `string` | Company Name | `POST` `/settings/welcome_screen` #### Welcome Screen Create `createWelcomeScreenSetting` Create Welcome Screen Create Welcome Screen Setting. You can define only BOOLEAN values. ##### Request application/json Copy ``` { "welcome_screen": true } ``` ##### Response 201403500 application/json Copy Create Welcome Screen Triggered Successfully ``` { "welcome_screen": true } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `welcome_screen`required | `boolean` | Welcome Screen | ##### Response `201``application/json` 1 fields Create Welcome Screen Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `welcome_screen`required | `boolean` | Welcome Screen | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` `GET` `/settings/welcome_screen` #### Welcome Screen Retrieve `getWelcomeScreenSetting` Retrieve Welcome Screen Setting Retrieve Welcome Screen ##### Response 200403500 application/json Copy Retrieve Welcome Screen ``` { "welcome_screen": true } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Retrieve Welcome Screen | Field | Type | Description | | --- | --- | --- | | `welcome_screen`required | `boolean` | Welcome Screen | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `PUT` `/settings/welcome_screen` #### Welcome Screen Update `updateWelcomeScreenColor` Update Welcome Screen Setting Update Welcome Screen ##### Request application/json Copy ``` { "welcome_screen": true } ``` ##### Response application/json Copy Update Welcome Screen ``` { "welcome_screen": true } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `welcome_screen`required | `boolean` | Welcome Screen | ##### Response `200``application/json` 1 fields Update Welcome Screen | Field | Type | Description | | --- | --- | --- | | `welcome_screen`required | `boolean` | Welcome Screen | `PUT` `/settings/logo` #### Upload logo `UploadLogo` Upload Logo Upload logo: Uploads company logo for Nav Bar ##### Request multipart/form-data Copy Upload new logo ``` { "image": { "externalValue": "https://staircase.co/images/yellow-stairs.png" } } ``` ##### Response 201403500 application/json Copy Upload New Logo Triggered Successfully ``` { "status": "SUCCEEDED", "blob_id": "01G3H1DQMK3BC24V1PP15PNHC3" } ``` 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" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Request body`multipart/form-data` 1 fields | Field | Type | Description | | --- | --- | --- | | `image` | `string (binary)` | Image to upload | ##### Response `201``application/json` 2 fields Upload New Logo Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Status process | | `blob_id` | `string` | Image Blob ID | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `409` ## Errors `403``404``409``500` ## More in Automation - Next product: Boarding --- # Boarding # Boarding Moving a closed loan into a servicer's system of record. Boarding is a translation problem with a deadline. A servicer expects the loan in its own format, with its own required fields, within a defined window after closing — and a rejected board is manual work at the least convenient moment. The product maps the canonical loan record into the servicer's expected shape, submits it, and returns the acknowledgment or the rejection with the field-level reasons. ## How it works The mapping is a language configuration like any vendor mapping, which means a new servicer is a configuration rather than a code change. The general mechanism is documented under Translation. ## Operations ### Workflow `POST` `/import` #### Import `importLoans` Import loans from client's environment Boarding supports the import of loan documents from Google Cloud storage and SFTP. Boarding expects your loans to be organized in a certain way. All documents in a loan should be in the same folder, a loan folder. The loan folder's name will be used as a loan identifier. All the loan folders should be in the same parent folder. If you are going to import unclassified loans, set "import_classified_documents" to false. Then, the only required field is "loan_file_path" which maps the path for the loans. Show the rest If you are going to import classified loans, set "import_classified_documents" to true. Then, the import request body must specify the mapping for loan documents. All mapping files should be in the same folder, a mapping folder. The mapping folder and loan folder should be in the same parent folder. The mapping folder should contain CSV files that describe the document types and document paths (with respect to loan folder mentioned above). Also, as part of the import request body, it provides the document type mapping language for converting given document types to Staircase document types. User can create own language from here: Language Product This language should contain 1-1 mapping between user document type and Staircase document type. In Google Cloud platform type; there is an additional field called loan_ids. With this field; user can specify the loan ids that needs to imported in loan file path. This API supports using batch configuration. Instead of inputting all required information; you can input "batch_id" and it will use the import configuration that given batch contains. Note that batch configuration will override the other input. Batch configuration can be created from here: Create Batch The API will return an execution id for successful requests. To see the results use Get Operation Result ##### Request GoogleCloudGoogleCloudWithLoanIdsGoogleDriveSFTPSFTPClientBatch application/json Copy ``` { "platform": "google_cloud", "batch_info": { "import_classified_documents": true, "bucket_name": "test_bucket_staircase", "loan_file_path": "f2022-04-12/initial_onboarding_docs", "document_type_file_path": "f2022-04-12/output_docs/onboarding_input_document_tag_files", "document_type_mapping_language": "doctype_to_staircase" } } ``` application/json Copy ``` { "platform": "google_cloud", "batch_info": { "import_classified_documents": true, "bucket_name": "test_bucket_staircase", "loan_file_path": "f2022-04-12/initial_onboarding_docs", "document_type_file_path": "f2022-04-12/output_docs/onboarding_input_document_tag_files", "document_type_mapping_language": "doctype_to_staircase", "loan_ids": [ 1001, 1002, 1003 ] } } ``` application/json Copy ``` { "platform": "google_drive", "batch_info": { "import_classified_documents": true, "folder_name": "test_folder", "loan_file_path": "loans", "document_type_file_path": "mappings", "document_type_mapping_language": "doctype_to_staircase" } } ``` application/json Copy ``` { "platform": "sftp", "batch_info": { "import_classified_documents": true, "user_name": "user", "loan_file_path": "example_batch_folder/loan_folder", "document_type_file_path": "example_batch_folder/mapping_folder", "document_type_mapping_language": "doctype_to_staircase" } } ``` application/json Copy ``` { "platform": "sftp_client", "batch_info": { "import_classified_documents": false, "loan_file_path": "example_batch_folder/loan_folder", "sftp_url": "sftp_server_url", "sftp_user_name": "sftp_user_name", "sftp_password": "sftp_password", "folder_name": "folder_name" } } ``` application/json Copy ``` { "batch_id": "01G3BC9MPZH4M0XQ45X6D1EA2V" } ``` ##### Response 200400422 application/json Copy Successfully returned status of import request ``` { "code": 200, "message": { "execution_id": "01G3BC9MPZH4M0XQ45X6D1EA2V" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `platform` | `string` | The platform where the loan documents exist`google_cloud``google_drive``sftp``sftp_client` | | `batch_info` | `object` | Information needed to import batch | | `bucket_name` | `string` | Google Cloud storage bucket name | | `loan_file_path` | `string` | The path of the folder that contains loan folders | | `doc_type_file_path` | `string` | The path of the folder that contains mapping files in CSV format | | `loan_ids` | `string[]` | If you only want to import specific loan ids, you can filter out rest of them with using this field | ##### Response `200``application/json` 2 fields Successfully returned status of import request | Field | Type | Description | | --- | --- | --- | | `code` | `string` | Status code | | `message` | `object` | message | | `execution_id` | `string` | Execution id of the operation | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/onboard` #### Onboard `onboardLoan` Process a loan Onboard invokes an automated process that turns raw loan documents into onboarded loan data for mortgage servicing systems. To invoke Onboard, you will need: - For each loan, a transaction_id. The transaction_id needs to imported from a data source and must contain loan identifier information along with loan documents. - If you want to use ml, the "ml_enabled" field should be true; otherwise set it to false. - If you want to use labeling, "labeling_enabled" field should be true; otherwise set it to false. - If you want to use Staircase Classification, "classify_enabled" field should be true; otherwise set it to false. - For the "operation_type" field, select "extraction" and "classification_and_extraction" - "delay_between_transactions" is an optional field and default delay time is 10 seconds. If you provide input for this field, Boarding will use this time value to create a delay between transactions. - "fast_ml_option_enabled" is an optional field for ML product and default value is false. If it's true, it will use dedicated endpoints for ML - "fields_to_label" is optional field for Labeling product to filter what should be on Labeling UI to label for given document type. For reviewing all available fields for labeling, you can check product overview: Overview Once you have a transaction_id (or multiple transaction ids) which contains loan data, you can send them as part of the transaction_ids request body object. Show the rest This API supports using batch configuration. Instead of inputting all required information; you can input "batch_id" and it will use the onboard configuration that given batch contains. Note that batch configuration will override the other input. Batch configuration can be created from here: Create Batch Example input with extraction operation type: ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "ml_enabled": true, "labeling_enabled": true, "operation_type": "extraction" } } ``` Example input with classification and extraction operation type, the user needs to select classification partner; available partners are ephesoft and documentai: ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "selected_classification_partners": [ "documentai", "ephesoft" ] "ml_enabled": true, "labeling_enabled": true, "classify_enabled": true, "operation_type": "classification_and_extraction" } } ``` Example input with batch_id: ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "batch_id": "batch_id" } ``` Example input with extraction operation type with fields_to_label: ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "ml_enabled": true, "labeling_enabled": true, "operation_type": "extraction", "fields_to_label": { "bank_statement": [ "Checking_Account_Checks_Paid", "Savings_Account_No", "Savings_Account_Name", "Savings_Account_Deposits_And_Additions", "Checking_Account_Fees" ] } } } ``` View the status of the onboarded transactions using Status. ##### Request ExtractionExampleClassificationExtractionExampleBatchIdExampleExtractionExampleWithFieldsToLabel application/json Copy ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "ml_enabled": true, "labeling_enabled": false, "operation_type": "extraction" } } ``` application/json Copy ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "ml_enabled": true, "labeling_enabled": false, "classify_enabled": false, "operation_type": "classification_and_extraction", "selected_classification_partners": [ "ephesoft" ] } } ``` application/json Copy ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "batch_id": "batch_id" } ``` application/json Copy ``` { "transaction_ids": [ "01GGCT4ZZRSSDXD5SS8F0522CB" ], "request_payload": { "delay_between_transactions": 15, "ml_enabled": false, "labeling_enabled": true, "operation_type": "extraction", "fields_to_label": { "bank_statement": [ "Checking_Account_Checks_Paid", "Savings_Account_No", "Savings_Account_Name", "Savings_Account_Deposits_And_Additions", "Checking_Account_Fees" ] } } } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | Transaction IDs for the loans that you imported and want to onboard | | `request_payload` | `object` | Request payload for onboard | | `delay_between_transactions` | `integer` | Delay information | | `ml_enabled` | `boolean` | ML information | | `labeling_enabled` | `boolean` | Labeling information | | `classify_enabled` | `boolean` | Staircase classification information | | `automatic_training_enabled` | `boolean` | Automatic training information | | `operation_type` | `string` | Operation type selection`classification_and_extraction``extraction` | | `selected_classification_partners` | `string[]` | Selected classification partners | ##### Response `200``application/json` 1 fields Response collection | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Onboard result message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/export` #### Export `exportLoan` Export a loan Export requires one or more onboarded loan transaction_id's as input, and converts them from Staircase data to customer data, for subsequent delivery to a customer environment. To invoke Export, you will need a transaction_id for each loan. Before exporting a loan transaction, make sure that it has been onboarded and has an onboarding result. A transaction should be processed by /onboard before it is exported. Show the rest Once you have a transaction_id (or multiple transaction_id's) which contains onboard data, add them to the request body to export them. In export operation: - "ruleset_name" is an optional field for applying rules to boarding result. User can create own rules from here: Rule Product Or user can apply default rules that has been provided with "default_rules" ruleset name. You can download detailed information in Overview page. - "language_name" is an optional field for translating from Staircase v2 language to given user language. User can create own language from here: Language Product This API supports using batch configuration. Instead of inputting all information; you can input "batch_id" and it will use the export configuration that given batch contains. Note that batch configuration will override the other input. Batch configuration can be created from here: Create Batch Examples: ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ] } ``` ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "ruleset_name": "default_rules" "language_name": "language_name" } } ``` ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "batch_id": "batch_id" } ``` The endpoint will return an execution id for successful requests. To see the results use Get Operation Result ##### Request ExampleWithRulesetAndLanguageExampleWithBatchId application/json Copy ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "request_payload": { "ruleset_name": "default_rules", "language_name": "language_name" } } ``` application/json Copy ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ], "batch_id": "01G3BC9MPZH4M0XQ45X6D1EA2V" } ``` ##### Response 200400422 application/json Copy Successfully returned export request ``` { "code": 200, "message": { "execution_id": "01G23BGPVAP4YEH0KY2K8M9GR7" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | Transaction_ids for loans which are going to be resumed | ##### Response `200``application/json` 2 fields Successfully returned export request | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/status` #### Status `status` Get status of the loans in onboard process Check the onboarding status of a loan at any point in the process, by using the loan transaction id which was returned after performing the onboard operation. This API supports using batch configuration. Instead of inputting transaction ids; you can input "batch_id" and it will use the registered transactions in the batch. Note that batch configuration will override the other input. Transactions can be registered to the batch from here: Register Transactions to Batch The API will return an execution_id for successful requests. To see the results, use Get Operation Result until it's `message.status` is SUCCEEDED. ##### Request application/json Copy ``` { "transaction_ids": [ "01G394T6AP0F0XY7ER5TAY1YH4", "01G23BF87W7W5HKFYEMQAETNZG", "01G23BGR0K6S5XESPHPZXWB1ZJ", "01G23BGPVAP4YEH0KY2K8M9GR7" ] } ``` ##### Response 200400422 application/json Copy Successfully returned status request ``` { "code": 200, "message": { "execution_id": "01G23BGPVAP4YEH0KY2K8M9GR7" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | Loan transaction_id list whose statuses are going to be provided | ##### Response `200``application/json` 2 fields Successfully returned status request | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/deliver` #### Deliver `deliver` Deliver processed loans to a customer environment After a loan is exported, it is ready to be delivered to a customer environment. With this API, user can deliver exported result to given destination. Boarding currently supports delivery to Google Cloud storage, Staircase SFTP and SFTP Client. You can see the status of the transactions that you delivered using Status. This API supports using batch configuration. Instead of inputting all required information; you can input "batch_id" and it will use the delivery configuration that given batch contains. Note that batch configuration will override the other input. Batch configuration can be created from here: Create Batch ##### Request GoogleCloudExampleBatchExample application/json Copy ``` { "transaction_ids": [ "01G394T6AP0F0XY7ER5TAY1YH4" ], "request_payload": { "bucket_name": "test_bucket_staircase", "result_file_path": "batch_folder/result", "mime_type": "application_json" } } ``` application/json Copy ``` { "transaction_ids": [ "01G394T6AP0F0XY7ER5TAY1YH4" ], "batch_id": "01G3BC9MPZH4M0XQ45X6D1EA2V" } ``` ##### Response 200400422 application/json Copy Successfully returned status of import request ``` { "code": 200, "message": "Deliver operation has started for the loan outputs" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | id of transactions for the loans that you are going to deliver | | `request_payload` | `object` | Information needed to deliver boarding result | | `bucket_name` | `string` | The Google Cloud storage bucket to which the results are going to be delivered | | `user_name` | `string` | Username for SFTP server, this field should be provided if platform is SFTP | | `loan_file_path` | `string` | The path of the folder where the results are going to be delivered | | `mime_type` | `string` | The type of result files that are going to be delivered`application_json``application_ld_json``application_xml` | | `platform` | `string` | The platform that the results are going to be delivered`google_cloud``google_drive``sftp``sftp_client` | ##### Response `200``application/json` 2 fields Successfully returned status of import request | Field | Type | Description | | --- | --- | --- | | `code` | `string` | Status code | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/query` #### Query `query` Get loan id of the loans Query provides loan id information and document count for one or more loans. The API will return an execution_id for successful requests. To see the results, use Get Operation Result. Example result: ``` { "code": 202, "message": { "start_date": "2022-05-27 13:07:06", "stop_date": "2022-05-27 13:07:10", "status": "SUCCEEDED", "data": { "loans": [ { "transaction_id": "01G406KR4KR5K8DVWJW59XYQYC", "loan_id": "100001" "document_count": 10 }, { "transaction_id": "01G406KJFV21RGN69X4H1C8TBM", "loan_id": "100002" "document_count": 20 }, { "transaction_id": "01G406KKHNE52KCVZN9WKMSPZ2", "loan_id": "100003" "document_count": 30 } ] } } } ``` ##### Request application/json Copy ``` { "transaction_ids": [ "01G394T6AP0F0XY7ER5TAY1YH4", "01G23BF87W7W5HKFYEMQAETNZG", "01G23BGR0K6S5XESPHPZXWB1ZJ", "01G23BGPVAP4YEH0KY2K8M9GR7" ] } ``` ##### Response 200400422 application/json Copy Successfully returned status of query request ``` { "code": 200, "message": { "response_collection_id": "01G23BGPVAP4YEH0KY2K8M9GR7" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | Transaction id list of loans to be queried | ##### Response `200``application/json` 2 fields Successfully returned status of query request | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/{transaction_id}/status` #### Transaction Status `transactionStatus` Checking transaction status with document details Transaction Status provides the status for each document in a transaction. Statuses include GTL_EXTRACTION_COMPLETED, TRAIN_EXTRACTION_COMPLETED, COULD NOT FIND TRAIN OR GTL RESULT FOR THIS DOCUMENT. This API requires a transaction_id in the request and returns an execution_id for successful requests. To see the results, use Get Operation Result. Example transaction status result: Show the rest ``` "message": { "start_date": "2022-06-10 07:43:15", "stop_date": "2022-06-10 07:43:23", "status": "SUCCEEDED", "data": [ { "document_name": "test_note.pdf", "created_at": "2022-05-31T19:50:10.161363-04:00", "status": "GTL_EXTRACTION_COMPLETED", "last_updated_at": "2022-06-03T04:47:53.041720-04:00" }, { "document_name": "test_appraisal.pdf", "created_at": "2022-05-31T19:50:05.323109-04:00", "status": "GTL_EXTRACTION_COMPLETED", "last_updated_at": "2022-06-01T07:55:20.965616-04:00" }, { "document_name": "test_w2.pdf", "created_at": "2022-05-31T19:50:13.886317-04:00", "status": "GTL_EXTRACTION_COMPLETED", "last_updated_at": "2022-06-01T00:40:17.638374-04:00" } ] } ``` ##### Response 200400422 application/json Copy Successfully returned status of transaction status request ``` { "code": 200, "message": { "execution_id": "01G3BC9MPZH4M0XQ45X6D1EA2V" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string` path | `01G4CPJSW76SWNW88CN907KNZF` | Transaction id | ##### Response `200``application/json` 2 fields Successfully returned status of transaction status request | Field | Type | Description | | --- | --- | --- | | `code` | `string` | Status code | | `message` | `object` | message | | `execution_id` | `string` | Execution id of the operation | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/operations/{operation_name}/executions/{execution_id}` #### Operation Result `operationResult` Get execution results of boarding operations The following boarding operations return execution id: - /import - /status - /query - /{transaction_id}/status When executing the API with `execution_id` and the `operation_name` you will receive a response that with status RUNNING or SUCCEEDED. If it's still RUNNING please query it till you get a `message.status` = `SUCCEEDED`. ##### Response 200 StatusSucceeded200 QuerySucceeded200 StatusRunning200 StatusInML200 ImportSucceeded400422 application/json Copy Successfully fetched operation result ``` { "code": 200, "message": { "transactions": [ { "transaction_id": "01GAR1889DFA56FCQVBWT8DTPM", "transaction_created_at": "2022-08-18T04:31:25.537694-04:00", "onboarding_status": "ONBOARDING_COMPLETED", "status_updated_at": "2022-08-18T06:13:25.219153-04:00" } ] } } ``` application/json Copy Successfully fetched operation result ``` { "code": 202, "message": { "start_date": "2022-05-27 13:07:06", "stop_date": "2022-05-27 13:07:10", "status": "SUCCEEDED", "data": { "loans": [ { "transaction_id": "01G406KR4KR5K8DVWJW59XYQTS", "loan_id": "101101" } ] } } } ``` application/json Copy Successfully fetched operation result ``` { "code": 200, "message": { "start_date": "2022-08-31 23:44:15", "status": "RUNNING" } } ``` application/json Copy Successfully fetched operation result ``` { "code": 200, "message": { "start_date": "2022-08-31T20:15:46.588000-04:00", "stop_date": "2022-08-31T20:16:08.246000-04:00", "status": "SUCCEEDED", "data": { "transactions": [ { "transaction_id": { "transaction_id": "01GBTQX9PPY7XET65RMXAANGMT", "transaction_created_at": "2022-08-31T16:01:35.336279-04:00", "onboarding_status": "IN_ML", "status_updated_at": "2022-08-31T16:19:16.638650-04:00" } } ] } } } ``` application/json Copy Successfully fetched operation result ``` { "code": 202, "message": { "start_date": "2022-05-27 11:57:51", "stop_date": "2022-05-27 11:58:37", "status": "SUCCEEDED", "data": { "transaction_ids": [ "01G42P3K5YNKJQVCEBHA14E3XD", "01G42P3JYZYS5EK2WHPA8Y07AG" ], "errors": [ null ] } } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `operation_name` required | `string` path | `import` | Operation name | | `execution_id` required | `string` path | `01G42T1CQ7TKF14MPW6NA840FM` | Execution Id | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 2 fields Successfully fetched operation result | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ### Batch Configuration `POST` `/batches` #### Create Batch `createBatch` With this API user can create a batch object that may contain information for whole boarding process: import, onboard, export, delivery and general batch information. ##### Request application/json Copy ``` { "import_configuration": { "platform": "google_drive", "folder_name": "folder_name", "loan_file_path": "abc/def", "import_classified_documents": true, "document_type_file_path": "abc/def/ghj", "document_type_mapping_language": "test", "bucket_name": "bucket_name", "user_name": "user_name", "sftp_user_name": "sftp_user_name", "sftp_password": "sftp_password", "sftp_url": "sftp_url" }, "onboard_configuration": { "operation_type": "extraction", "ml_enabled": true, "labeling_enabled": false, "classify_enabled": true, "selected_classification_partners": [ "ephesoft" ], "delay_between_transactions": 10, "automatic_training_enabled": false, "fast_ml_option_enabled": true, "fields_to_label": { "bank_statement": [ "Checking_Account_Checks_Paid", "Savings_Account_No", "Savings_Account_Name", "Savings_Account_Deposits_And_Additions", "Checking_Account_Fees" ] } }, "export_configuration": { "ruleset_name": "ruleset_name", "language_name": "language_name" }, "delivery_configuration": { "platform": "google_drive", "mime_type": "mime_type", "result_file_path": "result_file_path", "folder_name": "folder_name", "bucket_name": "bucket_name", "user_name": "user_name", "sftp_user_name": "sftp_user_name", "sftp_password": "sftp_password", "sftp_url": "sftp_url" }, "batch_information": { "loan_count": 1000, "register_date": "22/10/2022", "start_date": "22/10/2022", "completion_date": "22/10/2022", "daily_quota": 20, "daily_labeler_count": 10 } } ``` ##### Response 200400422 application/json Copy Successfully created batch id ``` { "code": 200, "message": { "batch_id": "01G23BGPVAP4YEH0KY2K8M9GR7" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `import_configuration` | `object` | Import configuration object | | `platform` | `string` | The platform where the loan documents exist`google_cloud``google_drive``sftp``sftp_client` | | `folder_name` | `string` | Folder_name for Google Drive | | `loan_file_path` | `string` | Loan location | | `import_classified_documents` | `boolean` | Indicator for classified loan information | | `document_type_file_path` | `string` | Location for document type information | | `document_type_mapping_language` | `string` | Language name for document type mapping | | `bucket_name` | `string` | Bucket name for Google Cloud | | `user_name` | `string` | Username for Staircase SFTP server login | | `sftp_user_name` | `string` | Username for Staircase SFTP client login | | `sftp_password` | `string` | Password for Staircase SFTP client login | | `sftp_url` | `string` | URL for Staircase SFTP client login | | `onboard_configuration` | `object` | Onboard configuration object | | `operation_type` | `string` | Operation type | | `ml_enabled` | `boolean` | Indicator for enabling/disabling ML in onboard operation | | `labeling_enabled` | `boolean` | Indicator for enabling/disabling labeling in onboard operation | | `classify_enabled` | `boolean` | Indicator for enabling/disabling Staircase Classification in onboard operation | | `selected_classification_partners` | `array` | Array for selected partners for classification | | `delay_between_transactions` | `integer` | Delay seconds between loans in onboarding | | `automatic_training_enabled` | `boolean` | Indicator for enabling/disabling auto-training for ML in onboard operation | | `fast_ml_option_enabled` | `boolean` | Indicator for enabling/disabling dedicated endpoints for ML in onboard operation | | `fields_to_label` | `array` | Array for fields to label | | `export_configuration` | `object` | Export configuration object | | `ruleset_name` | `string` | Ruleset name for applying rules | | `language_name` | `string` | Language name for applying rules | | `delivery_configuration` | `object` | Delivery configuration object | | `platform` | `string` | The platform where the loan documents exist`google_cloud``google_drive``sftp``sftp_client` | | `mime_type` | `string` | Mime type for to be delivered document`application_json``application_ld_json``application_xml` | | `result_file_path` | `string` | Location for delivery | | `folder_name` | `string` | Folder name for Google Drive | | `bucket_name` | `string` | Bucket name for Google Cloud | | `user_name` | `string` | Username for Staircase SFTP server login | | `sftp_user_name` | `string` | Username for Staircase SFTP client login | | `sftp_password` | `string` | Password for Staircase SFTP client login | | `sftp_url` | `string` | URL for Staircase SFTP client login | | `batch_information` | `object` | Batch information object | | `loan_count` | `integer` | Loan count in the batch | | `register_date` | `string` | The date that loans are registered | | `start_date` | `string` | The date that boarding operation started | | `completion_date` | `string` | The date that boarding operation completed | | `daily_quota` | `integer` | Daily quota for completed loans | | `daily_labeler_count` | `integer` | Labeler counts that works on the process | ##### Response `200``application/json` 2 fields Successfully created batch id | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/batches/{batch_id}` #### Retrieve Batch `retrieveBatch` Get batch configuration With this API, the batch configuration can be retrieved with given batch id ##### Response 200400422 application/json Copy Successfully retrieved batch ``` { "import_configurations": [ { "has_platform_type": null, "has_value": "google_drive", "has_folder_name": { "has_value": "folder_name" }, "has_file_path": { "has_value": "abc/def" }, "has_import_classified_documents_indicator": { "has_value": true }, "document_type_file_path": { "has_value": "abc/def/ghj" }, "has_document_type_mapping_language": { "has_value": "test" }, "has_bucket_name": { "has_value": "bucket_name" }, "has_user_name": { "has_value": "user_name" }, "has_sftp_user_name": { "has_value": "sftp_user_name" }, "has_sftp_password": { "has_value": "sftp_password" }, "has_sftp_server_url": { "has_value": "sftp_url" }, "@type": "import_configuration", "@id": "01GF87MAY70RA11JT8ZZCRG7DE" } ], "classification_partners": [ { "@type": "classification_partner", "@id": "01GF87MAY7EV6AE4NW9BKQWR9G", "has_classification_partner_type": { "has_value": "ephesoft" } } ], "onboard_configurations": [ { "has_operation_type": { "has_value": "extraction" }, "has_ml_enabled_indicator": { "has_value": true }, "has_labeling_enabled_indicator": { "has_value": false }, "has_delay_between_transactions_seconds": { "has_value": 10 }, "has_automatic_training_enabled_indicator": { "has_value": false }, "has_fast_ml_option_enabled_indicator": { "has_value": true }, "@type": "onboard_configuration", "@id": "01GF87MAY7VQFAAKJVGKAYN648", "with_classification_partner": [ "01GF87MAY7EV6AE4NW9BKQWR9G" ] } ], "export_configurations": [ { "has_ruleset_name": { "has_value": "ruleset_name" }, "has_language_name": { "has_value": "language_name" }, "@type": "export_configuration", "@id": "01GF87MAY7MM8TZWHFZHDN5A9W" } ], "delivery_configurations": [ { "has_platform_type": { "has_value": "google_drive" }, "has_mime_type": { "has_value": "mime_type" }, "has_file_path": { "has_value": "result_file_path" }, "has_folder_name": { "has_value": "folder_name" }, "has_bucket_name": { "has_value": "bucket_name" }, "has_user_name": { "has_value": "user_name" }, "has_sftp_user_name": { "has_value": "sftp_user_name" }, "has_sftp_password": { "has_value": "sftp_password" }, "has_sftp_server_url": { "has_value": "sftp_url" }, "@type": "delivery_configuration", "@id": "01GF87MAY7MVW7Q5K4VX42GD85" } ], "batch_informations": [ { "has_loan_count": { "has_value": 1000 }, "has_register_date": { "has_value": "22/10/2022" }, "has_start_date": { "has_value": "22/10/2022" }, "has_completion_date": { "has_value": "22/10/2022" }, "has_daily_quota_count": { "has_value": 20 }, "has_daily_labeler_count": { "has_value": 10 }, "@type": "batch_information", "@id": "01GF87MAY70MAESV359HRTVCP6" } ], "loan_boarding_batches": [ { "with_import_configuration": [ "01GF87MAY70RA11JT8ZZCRG7DE" ], "with_onboard_configuration": [ "01GF87MAY7VQFAAKJVGKAYN648" ], "with_export_configuration": [ "01GF87MAY7MM8TZWHFZHDN5A9W" ], "with_delivery_configuration": [ "01GF87MAY7MVW7Q5K4VX42GD85" ], "with_batch_information": [ "01GF87MAY70MAESV359HRTVCP6" ], "@type": "loan_boarding_batch", "@id": "01GF87MAY7JMNN9Y60BD5C14ND" } ] } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `batch_id` required | `string` path | `01G42T1CQ7TKF14MPW6NA840FM` | Batch Id | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 2 fields Successfully retrieved batch | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `PUT` `/batches/{batch_id}` #### Update Batch `updateBatch` With this API user can update the batch object that may contain information for whole boarding process: import, onboard, export, delivery and general batch information. ##### Request application/json Copy ``` { "import_configuration": { "platform": "google_drive", "folder_name": "folder_name", "loan_file_path": "abc/def", "import_classified_documents": true, "document_type_file_path": "abc/def/ghj", "document_type_mapping_language": "test", "bucket_name": "bucket_name", "user_name": "user_name", "sftp_user_name": "sftp_user_name", "sftp_password": "sftp_password", "sftp_url": "sftp_url" }, "onboard_configuration": { "operation_type": "extraction", "ml_enabled": true, "labeling_enabled": false, "selected_classification_partners": [ "ephesoft" ], "delay_between_transactions": 10, "automatic_training_enabled": false, "fast_ml_option_enabled": true }, "export_configuration": { "ruleset_name": "ruleset_name", "language_name": "language_name" }, "delivery_configuration": { "platform": "google_drive", "mime_type": "mime_type", "result_file_path": "result_file_path", "folder_name": "folder_name", "bucket_name": "bucket_name", "user_name": "user_name", "sftp_user_name": "sftp_user_name", "sftp_password": "sftp_password", "sftp_url": "sftp_url" }, "batch_information": { "loan_count": 1000, "register_date": "22/10/2022", "start_date": "22/10/2022", "completion_date": "22/10/2022", "daily_quota": 20, "daily_labeler_count": 10 } } ``` ##### Response 200400422 application/json Copy Successfully updated batch id ``` { "code": 200, "message": { "batch_id": "01G23BGPVAP4YEH0KY2K8M9GR7" } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `batch_id` required | `string` path | `01G42T1CQ7TKF14MPW6NA840FM` | Batch Id | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `import_configuration` | `object` | Import configuration object | | `platform` | `string` | The platform where the loan documents exist`google_cloud``google_drive``sftp``sftp_client` | | `folder_name` | `string` | Folder_name for Google Drive | | `loan_file_path` | `string` | Loan location | | `import_classified_documents` | `boolean` | Indicator for classified loan information | | `document_type_file_path` | `string` | Location for document type information | | `document_type_mapping_language` | `string` | Language name for document type mapping | | `bucket_name` | `string` | Bucket name for Google Cloud | | `user_name` | `string` | Username for Staircase SFTP server login | | `sftp_user_name` | `string` | Username for Staircase SFTP client login | | `sftp_password` | `string` | Password for Staircase SFTP client login | | `sftp_url` | `string` | URL for Staircase SFTP client login | | `onboard_configuration` | `object` | Onboard configuration object | | `operation_type` | `string` | Operation type | | `ml_enabled` | `boolean` | Indicator for enabling/disabling ML in onboard operation | | `labeling_enabled` | `boolean` | Indicator for enabling/disabling labeling in onboard operation | | `selected_classification_partners` | `array` | Array for selected partners for classification | | `delay_between_transactions` | `integer` | Delay seconds between loans in onboarding | | `automatic_training_enabled` | `boolean` | Indicator for enabling/disabling auto-training for ML in onboard operation | | `fast_ml_option_enabled` | `boolean` | Indicator for enabling/disabling dedicated endpoints for ML in onboard operation | | `export_configuration` | `object` | Export configuration object | | `ruleset_name` | `string` | Ruleset name for applying rules | | `language_name` | `string` | Language name for applying rules | | `delivery_configuration` | `object` | Delivery configuration object | | `platform` | `string` | The platform where the loan documents exist`google_cloud``google_drive``sftp``sftp_client` | | `mime_type` | `string` | Mime type for to be delivered document`application_json``application_ld_json``application_xml` | | `result_file_path` | `string` | Location for delivery | | `folder_name` | `string` | Folder name for Google Drive | | `bucket_name` | `string` | Bucket name for Google Cloud | | `user_name` | `string` | Username for Staircase SFTP server login | | `sftp_user_name` | `string` | Username for Staircase SFTP client login | | `sftp_password` | `string` | Password for Staircase SFTP client login | | `sftp_url` | `string` | URL for Staircase SFTP client login | | `batch_information` | `object` | Batch information object | | `loan_count` | `integer` | Loan count in the batch | | `register_date` | `string` | The date that loans are registered | | `start_date` | `string` | The date that boarding operation started | | `completion_date` | `string` | The date that boarding operation completed | | `daily_quota` | `integer` | Daily quota for completed loans | | `daily_labeler_count` | `integer` | Labeler counts that works on the process | ##### Response `200``application/json` 2 fields Successfully updated batch id | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/batches/{batch_id}/register` #### Register Transactions to Batch `registerTransactionsToBatch` With this API, given transactions can be registered to the given batch. After this operation, you can use batch id for tracking status of the loans that has registered via status API: Status ##### Request application/json Copy ``` { "transaction_ids": [ "01FYXZWD3JE1ZX9J0MR35RC8XM" ] } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `batch_id` required | `string` path | `01G42T1CQ7TKF14MPW6NA840FM` | Batch Id | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `transaction_ids` | `string[]` | Transaction IDs for the loans that you imported and want to register | ##### Response `200``application/json` 1 fields Successfully retrieved batch | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Onboard result message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/batches/{batch_id}/execute` #### Execute Registered Transactions in Batch `executeRegisteredTransactionsInBatch` With this API, user can execute the all registered transactions to the end of boarding process. Executed transactions are going to onboard, export and delivered with batch configuration. To complete all steps, batch configuration must contain onboard configuration and delivery configuration. Otherwise, batch execution cannot be started. Export configuration is optional; but if user wants to apply rules or translate result to customer language, export configuration is also required in the batch configuration. The status of the batch can be tracked with status API with batch id: Status ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `batch_id` required | `string` path | `01G42T1CQ7TKF14MPW6NA840FM` | Batch Id | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 1 fields Successfully retrieved batch | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Batch Execution result message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ## Providers - Valon ## Errors `400``422` ## More in Automation - Previous product: Approval - Next product: Income --- # Income # Income Income calculation and qualification logic layered over raw verification data. Verification returns what a borrower was paid. Qualification needs what a borrower can be counted on to be paid, and the two are not the same number: bonus, overtime and commission are averaged over a stated period, variable income is discounted or excluded, and self-employment is computed from returns rather than from deposits. This product carries those rules, over the records Income produced. ## How it works The calculation and the data collection are separate products because the rules change independently of the vendors. An agency guideline revision changes how a figure is computed and nothing about where it came from. ## Dual listing Income is filed under two categories. The other listing is Income under Verification , and the recorded specifications resolve there — its 39 operations render on that page. ## More in Automation - Previous product: Boarding --- # Contract # Contract The canonical model, pricing, fees, documents, signatures, notarisation and title. What are the documents and the numbers? The largest category, and the one carrying the model everything else is expressed in. Lexicon is the ontology as a served product; the rest of the category produces the documents and the figures a closing requires. Documents are generated from the canonical record rather than entered separately, which is what keeps the package and the loan from disagreeing. ## Products In the order the value chain runs. 1. Document has a recorded specification 1. Electronic 1. Fee has a recorded specification 1. Insurance 1. Lexicon has a recorded specification 1. Notary has a recorded specification 1. Price has a recorded specification 1. Signature has a recorded specification 1. Title has a recorded specification --- # Document # Document Document generation, classification and closing-package assembly, plus the ingestion half of the document pipeline. Two directions. Outbound, it generates documents from the canonical model — disclosures, letters and the closing package — so the document and the loan record cannot disagree. Inbound, it classifies an uploaded document, extracts its fields, and writes them back into the model. Extraction quality is measured rather than assumed. The scorecard is a separate product, Document under Validation, which carries per-vendor accuracy and cost. ## How it works Classification comes before extraction and is treated as its own step. A document routed to the wrong extractor produces confident wrong fields, which is worse than an unprocessed upload, so the classifier's output is a first-class result with its own confidence rather than an internal detail. Field mappings are declared per document type against the canonical model. The recorded mappings cover the standard loan application and its coborrower variant, tax returns and their schedules, wage statements, the loan estimate, closing data, housing expenses and the preapproval letter. ## Dual listing Document is filed under two categories. The other listing is Document under Validation , and the recorded specifications resolve there — its 17 operations render on that page. ## Operations ### Platform `POST` `/combine-results` #### Combine Collections Data `post-data-extraction-combine` Combines data from multiple collections ##### Request application/jsonapplication/json application/json Copy ``` { "transaction_id": "01EZY81SYVQ98YYG0KMM462NKZ", "collection_ids": [ "01EZY9J8SEFM2JKDJ1Q3YX65HS", "01EZY9J8SEFM2JKDJ1Q3YX65HS" ] } ``` application/json Copy ``` { "transaction_id": "", "collection_ids": [] } ``` ##### Response application/json Copy Successfully created collection with combined results. ``` { "collection_id": "01EZY9J8SEFM2JKDJ1Q3YX65HS" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_ids`required | `string[]` | List of collection IDs | ##### Response `201``application/json` 4 fields Successfully created collection with combined results. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | | `collection_id` | `string` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | ##### Other responses `400``404` `POST` `/coverage` #### Find Path in IDE Languages `post-data-extraction-coverage` Find Path in IDE Languages finds flatten V2 path in product languages. ##### Request application/jsonapplication/json application/json Copy ``` { "path": "$.people[1].has_first_name.has_value" } ``` application/json Copy ``` { "path": "" } ``` ##### Response application/json Copy Success ``` [ { "Document Type": "appraisal_report", "IDE Schema Path": "$.document.extracted_data.Property_Address_Zip.value", "Partner Paths": [ { "partner": "ocrolus", "path": "$.extractedData[0].fieldList[?(@.name == 'Property_Address_Zip')].data" } ] } ] ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `path`required | `string` | Flatten V2 path | ##### Other responses `200``400``404` `GET` `/stats` #### Retrieve Statistics `get-adr-stats` Retrieve Statistics retrieves partner stats for document classification. ##### Response application/json Copy Success ``` { "stats": [ { "document_type": "uniform_residential_loan_application", "partners": [ { "partner": "documentai", "historical_precision": 91.8 }, { "partner": "ocrolus", "historical_precision": null }, { "partner": "ephesoft", "historical_precision": null } ] } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `stats` | `object[]` | Partner stats | | `document_type` | `string` | Type of document | | `partners` | `object[]` | List of partners | | `partner` | `string` | Name of the partner | | `historical_precision` | `number` | Precision from historical data | `GET` `/document-types` #### Retrieve Document Types `get-ide-doctypes` Retrieve Doctypes retrieves the list of available document types for data extraction. Partner documentai supports only bank_statements documents that contain data just for one period. ##### Response application/json Copy Success ``` [ { "document_type": "irs_w2", "supported_partners": [ "documentai", "ocrolus" ] }, { "document_type": "irs_1040", "supported_partners": [ "ocrolus" ] } ] ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `document_type`required | `string` | — | | `supported_partners`required | `string[]` | — | ##### Other responses `400``403` `GET` `/extracted-fields/{document_type}` #### Retrieve Extracted Fields `get-ide-extracted-fields` Retrieve Extracted Fields retrieves the list of extracted fields for given document type ##### Response application/json Copy Success ``` { "document_type": "irs_w2", "field_names": [ "year", "wages_tips_other_compensation", "verification_code", "third_party_sick_pay", "statutory_employee", "state_wages_tips_other_comp_secondary", "state_wages_tips_other_comp_primary", "state_income_tax_secondary", "state_income_tax_primary", "social_security_wages", "social_security_tips", "social_security_tax_withheld", "social_security_number", "retirement_plan", "nonqualified_plans", "medicare_wages_and_tips", "medicare_tax_withheld", "locality_name_primary", "locality_name_secondary", "local_wages_tips_other_comp_secondary", "local_wages_tips_other_comp_primary", "local_income_tax_secondary", "local_income_tax_primary", "federal_income_tax_withheld", "employer_name", "employer_id", "employer_full_address", "employer_address_zip", "employer_address_state", "employer_address_line2", "employer_address_line1", "employer_address_city", "employee_last_name", "employee_full_name", "employee_full_address", "employee_first_name_and_initial", "employee_address_zip", "employee_address_state", "employee_address_line2", "employee_address_line1", "employee_address_city", "dependent_care_benefits", "control_number", "box_15_state_secondary", "box_15_state_primary", "box_15_employer_state_id_secondary", "box_15_employer_state_id_primary", "box_14_other", "box_12d_code", "box_12d_amount", "box_12c_code", "box_12c_amount", "box_12b_code", "box_12b_amount", "box_12a_code", "box_12a_amount", "allocated_tips" ] } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `document_type` required | `string` path | `irs_w2` | Document Type | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `document_type` | `string` | Document type | | `field_names` | `string[]` | List of field names | ##### Other responses `400``403` `GET` `/partners` #### Retrieve Partners `get-ide-partners` Retrieve Partners retrieves the list of available data partners for data extraction. ##### Response application/json Copy Success ``` { "partners": [ { "company_name": "Ocrolus", "invoke_name": "ocrolus", "status": "preview", "description": "https://www.ocrolus.com/" }, { "company_name": "Google", "invoke_name": "documentai", "status": "preview", "description": "https://cloud.google.com/document-ai" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `partners` | `object[]` | Partner details | ##### Other responses `400``403` `GET` `/partners/costs` #### Retrieve Partners costs `get-ide-partners-costs` Retrieve Partners costs retrieves the list of data partners costs for data extraction. ##### Response application/json Copy Success ``` { "costs": [ { "partner_name": "ocrolus", "costs_details": [ { "cost_type": "per_execution", "document_type": null, "priority": 1, "description": null, "conditional": { "hypotesis": "number_of_pages > 25", "conclusion": "2500 + ((number_of_pages // 50) * 1000)" }, "cost_in_cents": null }, { "cost_type": "per_document", "document_type": null, "priority": null, "description": null, "conditional": null, "cost_in_cents": 200 } ] } ] } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `document_type` | `string` query | `irs_w2` | Filters data by document_type | | `partner_name` | `string` query | `ocrolus` | Filters data by partner | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `costs` | `object[]` | Partner costs details | | `partner_name` | `string` | Name of the partner | | `costs_details` | `object[]` | List of partner costs | | `cost_type` | `string` | Type of the cost | | `document_type` | `string` | Document type | | `priority` | `number` | Priority | | `description` | `string` | Description of the cost | | `conditional` | `object` | Conditional for cost calculation | | `cost_in_cents` | `number` | Partner costs in cents | ##### Other responses `400``403` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `get-adr-transactions-collections` Retrieve Transaction Collections retrieves a list of all collections associated with a transaction. ##### Response 400404 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Parameters 6 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `filter` | `string` query | `collection_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51` | Filter expression in format {field_name}+{operation}+{value} | | `sort` | `string` query | `asc` | Order of sorting | | `limit` | `number` query | `5` | Amount of items to show | | `after_id` | `string` query | `01EZQ32PJQGKRA6HR8D72Q9FFF` | id of last evaluated transaction | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/response-elements` #### Retrieve Response Elements `get-ide-response-elements` Retrieve Response Elements retrieves the list of elements that will be returned by a partner performing data extraction. ##### Response 200 Example v0200 Example v2 application/json Copy Success ``` { "$.document.document_type": null, "$.document.extracted_data.employee_address": null, "$.document.extracted_data.employee_name": null, "$.document.extracted_data.employer_address": null, "$.document.extracted_data.employer_name": null, "$.document.extracted_data.federal_income_tax_witheld": null, "$.document.extracted_data.medicare_tax_witheld": null, "$.document.extracted_data.medicare_wages_and_tips": null, "$.document.extracted_data.social_security_tax_witheld": null, "$.document.extracted_data.social_security_wages": null, "$.document.extracted_data.tax_year": null, "$.document.extracted_data.wages_tips_and_other_compensation": null } ``` application/json Copy Success ``` { "$.documents.@type": null, "$.documents.extracted_data.employee_address": null, "$.people[0].has_first_name.has_value": null, "$.people[0].has_last_name.has_value": null, "$.addresses[0].has_address_line_1_text.has_value": null, "$.addresses[0].has_city_name.has_value": null, "$.addresses[0].has_state_code.has_value": null } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Other responses `200``400``403` `POST` `/separate_document_blobs/{transaction_id}/{collection_id}` #### Separate documents blob `get-adr-blob-splitter` Creates a new collection which will contain new blob_id for each document in collection Separate document blobs creates new collection that contains new blob_id for each document in collection. Completion of the request must be check in the response collection `metadata.status`. Possible values are: WAITING_FOR_RESPONSE, COMPLETED or ERROR. Newly created blobs will contain respective pages as defined by the classification result. ##### Request application/json Copy ``` { "callback_url": "https://webhook.site/b3506b5c-8ed2-4d58-a386-04a402aba1d6" } ``` ##### Response 200 Example - v0200 Example - v2 application/json Copy Success ``` { "collection_id": "01EZY95SC1K85WTA3J66R81WCV", "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "document_classification": null, "document_classes": { "document_class": [ { "type": "irs_w2" } ] }, "content": { "foreign_object": { "reference": { "location_label_value": "01FNBCR3YWX4A203A6R4NXN0J9" } } } }, { "document_classification": null, "document_classes": { "document_class": [ { "type": "irs_closing_disclosure" } ] }, "content": { "foreign_object": { "reference": { "location_label_value": "01FNBCQCCAPBR8RPGRP5M5E0YA" } } } } ] } } ] } }, "metadata": {}, "transaction_id": "01EZY81SYVQ98YYG0KMM462NKZ" } ``` application/json Copy Success ``` { "collection_id": "01EZY95SC1K85WTA3J66R81WCV", "data": { "documents": [ { "@id": "01FNBDWKSRSK23E3ZMQN5NJECT", "@type": "irs_w2", "has_staircase_blob_identifier": { "has_value": "01FNBCR3YWX4A203A6R4NXN0J9" }, "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 1 } }, { "@id": "01FNBCREQW52H4R0QHBB1FKERP", "@type": "closing_disclosure", "has_staircase_blob_identifier": { "has_value": "01FNBCQCCAPBR8RPGRP5M5E0YA" }, "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 1 } } ] }, "metadata": {}, "transaction_id": "01EZY81SYVQ98YYG0KMM462NKZ" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `01EZY81SYVQ98YYG0KMM462NKZ` | Transaction ID | | `collection_id` required | `string` path | `01EZY94X63AXWZ14TT8R1MAS3S` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string` | Callback url | ##### Response `200``application/json` 4 fields Success | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | | `collection_id` | `string` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | | `status` | `string` | Status description, either COMPLETED or WAITING_FOR_RESPONSE | ##### Other responses `400``403` `POST` `/request-elements/complete` #### Validate Collection `post-data-extraction-complete` Validate Collection verifies that a collection contains all the elements needed to invoke a partner for data extraction. ##### Request Example v0Example v2 application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "document_classification": { "document_classes": { "document_class": [ { "type": "bank_statement" } ] } }, "content": { "foreign_object": { "reference": { "location_label_value": "01EZY94X63AXWZ14TT8R1MAS3S" } } } } ] } } ] } } } ``` application/json Copy ``` { "data": { "documents": [ { "@type": "document_type", "has_staircase_blob_identifier": { "has_value": "blob_id" } } ] } } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | Validate collection request body | ##### Response `200``application/json` 1 fields Collection is valid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 2 fields Missing elements | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `403` `GET` `/costs/list` #### Get costs list `get-ide-costs-list` Gets list of costs Gets list of costs retrieves the list of costs for every successful product invocation ##### Response application/json Copy Success ``` { "costs": [ { "transaction_id": "01FKETNWHN67T9ZS2PD4QT4MW9", "request_collection_id": "01FKETPHVKGZF7JSZB73MJZ424", "response_collection_id": "01FKETPT6G09ERSG7WTQYVVRTA", "partner_name": "documentai", "finished_at": "2021-11-01 19:20:29.312", "document_type": "irs_w2", "pages": "1", "cost_in_cents": "25" } ] } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `start_date` | `string` query | `2021-12-30` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD, if not provided then period parameter must be set | | `end_date` | `string` query | `2021-12-30` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format: YYYY-MM-DD | | `period` | `string` query | `1m` | If used must be sent using d for days, w for weeks and m for months, the number always goes first e.g. 3w | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `costs`required | `object[]` | Cost details | | `transaction_id`required | `string` | Transaction id | | `request_collection_id`required | `string` | Request collection id | | `response_collection_id`required | `string` | Response collection id | | `partner_name`required | `string` | Name of the partner | | `finished_at`required | `string` | Finish date of the execution | | `document_type`required | `string` | Document type used for data extraction | | `pages`required | `string` | Number of pages for provided PDF | | `cost_in_cents`required | `string` | Cost in cents for data extraction invocation | ##### Other responses `400``403` `GET` `/costs/partner-cost` #### Get parner costs `get-ide-partner-costs` Gets partner costs Gets partner costs retrieves list of partner costs for every product invocation ##### Response application/json Copy Success ``` { "costs": [ { "partner_name": "ocrolus", "total_cost_in_cents": 225, "number_of_invocations": 9 } ] } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `start_date` | `string` query | `2021-12-30` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD, if not provided then period parameter must be set | | `end_date` | `string` query | `2021-12-30` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format: YYYY-MM-DD | | `period` | `string` query | `1m` | If used must be sent using d for days, w for weeks and m for months, the number always goes first e.g. 3w | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `costs`required | `object[]` | Cost details | | `partner_name`required | `string` | Partner name | | `total_cost_in_cents`required | `number` | Costs in cents | | `number_of_invocations`required | `number` | Number of invocations | ##### Other responses `400``403` `GET` `/extraction-statistics/{transaction_id}/{collection_id}` #### Get extractions statistics by collection `get-extraction-statistics-transaction-collection` Gets extraction statistics for provided response collection Gets extraction statistics by collection retrieves extraction statistics for provided response collection ##### Response application/json Copy Success ``` { "statistics": [ { "transaction_id": "01FYPECS78YBA6BEAFZKB7SA3C", "request_collection_id": "01FYPECSR1XCG7HXYKDH3E0S1S", "response_collection_id": "01FYPWX9XJJKZ8WA0VQQ90J363", "document_type": "irs_w2", "partner": "ocrolus", "expected_fields_count": 2, "translated_fields_count": 3, "translated_fields": [ "$.income[0].has_wages_salaries_tips_and_other_compensation_amount.has_value", "$.income[0].has_state_1_income_amount.has_value", "$.income[0].has_state_1_tax_withheld_amount.has_value" ] } ] } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string` path | `01EZY95SC1K85WTA3J66R81WCV` | Transaction ID | | `collection_id` required | `string` path | `01FYPWX9XJJKZ8WA0VQQ90J363` | Response collection ID | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `total_number_of_extractions` | `number` | Total number of extractions | | `statistics` | `object[]` | Statistics details | | `transaction_id`required | `string` | Transaction id | | `request_collection_id`required | `string` | Request collection id | | `response_collection_id`required | `string` | Response collection id | | `document_type`required | `string` | Extracted document type | | `partner`required | `string` | Name of partner used for extraction | | `expected_fields_count`required | `number` | Number of expected fields | | `translated_fields_count`required | `number` | Number of translated fields | | `translated_fields`required | `array` | List of translated fields | ##### Other responses `400``403` `GET` `/extraction-statistics/document-type` #### Get extraction statistics for all document types `get-extraction-statistics-document-types` Gets extraction statistics for all document types Gets extraction statistics for all document types ##### Response application/json Copy Success ``` { "statistics": [ { "document_type": "irs_w2", "average_expected_fields": 2, "average_translated_fields": 3, "executions_count": 5 } ] } ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `document_type` | `string` query | `irs_w2` | Filters results by document type | | `start_date` | `string` query | `2021-12-30` | If provided, filters by start_date it must be used together with the end_date. Date must be in ISO8601 format: YYYY-MM-DD, if not provided and period parameter is also not provided it will retrieve data for past 30 days. | | `end_date` | `string` query | `2021-12-30` | If provided, filters by end_date it must be used together with the start_date. Date must be in ISO8601 format: YYYY-MM-DD | | `period` | `string` query | `1m` | If used must be sent using d for days, w for weeks and m for months, the number always goes first e.g. 3w. If not provided and start_date is also not provided it will retrieve data for past 30 days. | ##### Response `200``application/json` 1 fields Success | Field | Type | Description | | --- | --- | --- | | `statistics`required | `object[]` | Statistics details | | `document_type`required | `string` | Document type | | `average_expected_fields`required | `number` | Request collection id | | `average_translated_fields`required | `number` | Response collection id | | `executions_count`required | `number` | Number of extraction executions | ##### Other responses `400``403` `GET` `/extraction-statistics/document-type/{transaction_id}` #### Get extractions statistics by transaction `get-extraction-statistics-transaction` Gets extraction statistics by transaction_id Gets extraction statistics retrieves extraction statistics for provided transaction ##### Response application/json Copy Success ``` { "statistics": [ { "transaction_id": "01FYPECS78YBA6BEAFZKB7SA3C", "request_collection_id": "01FYPECSR1XCG7HXYKDH3E0S1S", "response_collection_id": "01FYPWX9XJJKZ8WA0VQQ90J363", "document_type": "irs_w2", "partner": "ocrolus", "expected_fields_count": 2, "translated_fields_count": 3, "translated_fields": [ "$.income[0].has_wages_salaries_tips_and_other_compensation_amount.has_value", "$.income[0].has_state_1_income_amount.has_value", "$.income[0].has_state_1_tax_withheld_amount.has_value" ] } ] } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string` path | `01EZY95SC1K85WTA3J66R81WCV` | Transaction ID | ##### Response `200``application/json` 2 fields Success | Field | Type | Description | | --- | --- | --- | | `total_number_of_extractions` | `number` | Total number of extractions | | `statistics` | `object[]` | Statistics details | | `transaction_id`required | `string` | Transaction id | | `request_collection_id`required | `string` | Request collection id | | `response_collection_id`required | `string` | Response collection id | | `document_type`required | `string` | Extracted document type | | `partner`required | `string` | Name of partner used for extraction | | `expected_fields_count`required | `number` | Number of expected fields | | `translated_fields_count`required | `number` | Number of translated fields | | `translated_fields`required | `array` | List of translated fields | ##### Other responses `400``403` ### QR code `POST` `/generate` #### Generate QR Code `generateQrCode` ##### Request application/json Copy ``` { "url": "https://staircaseapi.com", "presign_url_ttl": 3600 } ``` ##### Response 200400404 application/json Copy Successfully generated the QR code. ``` { "presigned_url": "https://presigned-url" } ``` application/json Copy Request data invalid ``` { "message": "Request body is invalid." } ``` application/json Copy Requested resource not found ``` { "message": "Container not found" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `url`required | `string` | URL to generate QR codeExample `https://staircaseapi.com` | | `presign_url_ttl` | `integer` | TTL of presigned url in seconds, default is 86400Example `3600` | ##### Response `200``application/json` 1 fields Successfully generated the QR code. | Field | Type | Description | | --- | --- | --- | | `presigned_url`required | `string` | presigned_url | ##### Response `400``application/json` 1 fields Request data invalid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Workflow `POST` `/products/document/invocations` #### Invoke Document Creation `invokeDocumentCreation` **Invoke Document Creation ** invokes an automated process that will create documents in the loan with the partner. To invoke Invoke Document Creation, you will need: - transaction_id, a unique identifier for Staircase operations. - collection_id, a unique identifier that contains Staircase V2 data with loan_identifier. - vendor_name, a supported vendor name for this operation - product_flow_name, a Staircase Connector flow name that is going to be executed in the process. - callback_url, URL for getting result of this asynchronous operation. To create documents in the loan, there are some mandatory Staircase containers you should store in the collection that you provide in the input: Show the rest - loan_identifiers container for storing loan identifier information. Example Staircase Collection data: ``` { "loan_identifiers": [ { "@type": "loan_identifier", "has_loan_identifier_value": { "has_value": "test" }, "@id": "01GKF93BSG0S0F86EYREY87FZH" } ] } ``` In the response, you will get a staircase collection that contains loan related information and a linkage for each document in the package. Example document creation result: ``` { "addresses": [ { "@type": "subject_property_address", "has_address_line_1_text": { "has_value": "1000 N WICKHAM RD R" }, "has_city_name": { "has_value": "HELENA" }, "has_postal_code": { "has_value": "35020" }, "has_state_code": { "has_value": "AL" }, "@id": "01GM367RV66WKA98JK8N2R55CV" } ], "closing_information": [ { "@type": "closing_information", "has_closing_date": { "has_value": "2022-08-16" }, "@id": "01GM367RV6A54XX62YX1QXTER4" } ], "contact_point_emails": [ { "@id": "01GM367RV6JWCQCG54NM6JMBD0", "@type": "contact_point_email", "has_contact_point_email_value": { "has_value": "jlindseth@firstam.com" } } ], "contact_points": [ { "@id": "01GM367RV6QZCJHRJ5768AEKJD", "@type": "contact_point", "with_contact_point_email": [ "01GM367RV6JWCQCG54NM6JMBD0" ] } ], "loan_identifiers": [ { "@type": "loan_identifier", "has_loan_identifier_type": { "has_value": "lender_loan" }, "has_loan_identifier_value": { "has_value": "JL_ECLOSE_NOSF_TEST_6" }, "@id": "01GM367RV6K5CZCYT4NT6YZXVC" }, { "@type": "loan_identifier", "has_loan_identifier_type": { "has_value": "mers_min" }, "has_loan_identifier_value": { "has_value": "999933857913323869" }, "@id": "01GM367RV65RW5FFEM82F62XNY" } ], "people": [ { "@type": "person", "has_full_name": { "has_value": "JOHN TEST" }, "with_contact_point": [ "01GM367RV6QZCJHRJ5768AEKJD" ], "@id": "01GM367RV6P47NE7N9PR9YNA1T" } ], "sales_contracts": [ { "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": "260000.00" }, "@id": "01GM367RV6W4FNYBTJW80AVZCB" } ], "staircase_collection_references": [ { "@type": "staircase_collection_reference", "has_collection_identifier": { "has_value": "01GM367DQ9TRGFMZC52518SD72" }, "has_transaction_identifier": { "has_value": "01GKWCZQK53F7FRJBQC49NNADJ" }, "@id": "01GM367RV6HBDPH57BCC4QWFQH" }, { "@type": "staircase_collection_reference", "has_collection_identifier": { "has_value": "01GM367EWCW7QT6K8R5W1VJE1T" }, "has_transaction_identifier": { "has_value": "01GKWCZQK53F7FRJBQC49NNADJ" }, "@id": "01GM367RV6WWH2K8H9AR8A3EZ0" }, { "@type": "staircase_collection_reference", "has_collection_identifier": { "has_value": "01GM367EZJW3870B3H806AD3AK" }, "has_transaction_identifier": { "has_value": "01GKWCZQK53F7FRJBQC49NNADJ" }, "@id": "01GM367RV662JC4XTSCVSJ6131" }, { "@type": "staircase_collection_reference", "has_collection_identifier": { "has_value": "01GM367EW5HWWNND3D3MFR5VMB" }, "has_transaction_identifier": { "has_value": "01GKWCZQK53F7FRJBQC49NNADJ" }, "@id": "01GM367RV7TE94KBR8B5B99TCZ" }, { "@type": "staircase_collection_reference", "has_collection_identifier": { "has_value": "01GM367EH3JJWKA111Z7P0H6QW" }, "has_transaction_identifier": { "has_value": "01GKWCZQK53F7FRJBQC49NNADJ" }, "@id": "01GM367RV74Y6072K2EAAZ5DK4" } ], "terms_of_loans": [ { "@type": "terms_of_loan", "has_note_amount": { "has_value": "195000.00" }, "has_purpose_type": { "has_value": "Purchase" }, "@id": "01GM367RV7Z50YSMAEAN631KXT" } ] } ``` In staircase_collection_references container, each object represents a distinct document in the package itself. Example generated document data: ``` { "document_form_fields": [ { "@id": "SignerSignature1", "@type": "form_field_signature", "with_field_reference": [ "01GM367BBE013SMYRZGD81JNX0" ], "with_signer": [ "BOR1" ] }, { "@id": "SignatureDate1", "@type": "form_field_text", "with_field_reference": [ "01GM367BBEKPJ4YYRA0A53PF9W" ], "with_signer": [ "BOR1" ] } ], "document_forms": [ { "@id": "01GM367BBEM7XXERGRHWSA6F2T", "@type": "document_form", "with_document_form_field": [ "01GM367BBEC0D4CWJZPFTQ81Y0", "01GM367BBEBRWQX1CMSC54BT0Z" ] } ], "documents": [ { "@id": "12", "@type": "document", "has_document_name": { "has_value": "Amortization Schedule" }, "has_staircase_blob_identifier": { "has_value": "01GM366N4AQ53GJ44S3EVM36G1" }, "with_document_form": [ "01GM367BBEM7XXERGRHWSA6F2T" ] } ], "field_references": [ { "@id": "01GM367BBE013SMYRZGD81JNX0", "@type": "field_reference", "has_field_height_number": { "has_value": "10" }, "has_field_width_number": { "has_value": "162" }, "has_offset_from_left_number": { "has_value": "36" }, "has_offset_from_top_number": { "has_value": "368.65" }, "has_page_number_value": { "has_value": "6" } }, { "@id": "01GM367BBEKPJ4YYRA0A53PF9W", "@type": "field_reference", "has_field_height_number": { "has_value": "10" }, "has_field_width_number": { "has_value": "66" }, "has_offset_from_left_number": { "has_value": "198" }, "has_offset_from_top_number": { "has_value": "368.65" }, "has_page_number_value": { "has_value": "6" } } ] } ``` ##### Request application/json Copy ``` { "transaction_id": "example_transaction_id", "collection_id": "example_collection_id", "vendor_name": "docutech", "callback_url": "example_url", "product_flow_name": "document-creation" } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Unique identifier for Staircase operations | | `collection_id` | `string` | Identifier for stored Staircase data | | `vendor_name` | `string` | Document creation partner`docutech` | | `callback_url` | `string` | URL for getting operation result | | `product_flow_name` | `string` | Staircase connector flow that operates this process | ##### Response `200``application/json` 1 fields Response collection | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Asynchronous operation start message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/blobs` #### Create Blob `post-data-extraction-blob-create` Create Blob creates a blob in Staircase. A Binary Large Object (blob) is a collection of binary data stored as a single entity. Typically, it represents a document, image or other multimedia object. To invoke a partner for Data Extraction, you must first create a blob for your document. The presigned URL, which is returned as a response, represents a container in Staircase for your document. A presigned URL expires one hour after creation. ##### Request application/json Copy ``` { "extension": ".pdf" } ``` ##### Response application/json Copy Blob has been created ``` { "blob_id": "01EZY9ENJGRMTW4S9CS4V1Y6XH", "extension": ".pdf", "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket-us-east-1-867210375911.s3.amazonaws.com/01EZY9ENJGRMTW4S9CS4V1Y6XH" } }, "message": "Blob has been created." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `extension`required | `string` | Document extension that blob is persistingExample `.pdf` | ##### Response `201``application/json` 3 fields Blob has been created | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string` | Blob ID | | `extension` | `string` | File extension | | `presigned_urls` | `object` | Presigned URL | ##### Other responses `400``403` `GET` `/products/document/invocations/{invocation_id}` #### Retrieve Document Creation Status `RetrieveProductFlowInvocationStatus` Retrieves the status of running Product flow invocation. ##### Response 200400403500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "invocation_id": "01GKGM9FEKBGH5NY1DVS01GK0R", "transaction_id": "01GKGHPJDN46RW12WENHQF9YCD", "product_flow_name": "document-creation", "response_collection_id": "01GKGM9FEKBGH5NY1DVS01GK0R", "invocation_status": "COMPLETED", "callback_url": "https://webhook.site/d42faea3-6a42-440d-9226-d8fbcdfb5838", "widget_url": "", "metadata": {}, "options": {}, "service_invocation": { "CallConnector": { "started_on": "2022-12-05T07:51:30.687304", "finished_on": "2022-12-05T07:51:47.925999", "status": "COMPLETED" }, "CallJob": { "started_on": "2022-12-05T07:51:50.091899", "finished_on": "2022-12-05T07:51:59.032819", "status": "COMPLETED" }, "ConvertXmlToJson": { "started_on": "2022-12-05T07:51:48.561624", "finished_on": "2022-12-05T07:51:49.395832", "status": "COMPLETED" }, "CreateBlob": { "started_on": "2022-12-05T07:51:48.138654", "finished_on": "2022-12-05T07:51:48.390732", "status": "COMPLETED" }, "GeneratePresignedURL": { "started_on": "2022-12-05T07:51:49.561906", "finished_on": "2022-12-05T07:51:49.863825", "status": "COMPLETED" }, "GetCollection": { "started_on": "2022-12-05T07:51:30.089996", "finished_on": "2022-12-05T07:51:30.478678", "status": "COMPLETED" }, "GetJobResultCollection": { "started_on": "2022-12-05T07:51:59.343658", "finished_on": "2022-12-05T07:51:59.671978", "status": "COMPLETED" }, "UpdateResponseCollection": { "started_on": "2022-12-05T07:51:59.858050", "finished_on": "2022-12-05T07:52:00.162106", "status": "COMPLETED" } }, "response_collection": { "collection_id": "01GKGM9FEKBGH5NY1DVS01GK0R", "transaction_id": "01GKGHPJDN46RW12WENHQF9YCD" }, "flows_responses": {}, "_links": { "finance_metrics": "https://test.staircaseapi.com/finance/metrics/query/", "health_metrics": "https://test.staircaseapi.com/code-health-checker/metric/01GKGHPJDN46RW12WENHQF9YCD?product_name=document" } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | Product flow invocation identifier | ##### Response `200``application/json` 13 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation id | | `transaction_id` | `string` | Transaction id | | `product_flow_name` | `string` | Product flow name | | `response_collection_id` | `string` | Response collection id | | `invocation_status` | `string` | Invocation status | | `callback_url` | `string` | Callback URL | | `widget_url` | `string` | Widget URL | | `metadata` | `object` | Metadata | | `options` | `object` | Options | | `service_invocation` | `object` | Service invocation | | `CallConnector` | `object` | Connector process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `CallJob` | `object` | Job process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `ConvertXmlToJson` | `object` | Conversion process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `CreateBlob` | `object` | Creating blob process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `GeneratePresignedURL` | `object` | Generating URL process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `GetCollection` | `object` | Getting collection data process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `GetJobResultCollection` | `object` | Getting job data process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `UpdateResponseCollection` | `object` | Updating response collection process | | `started_on` | `string` | Date information | | `finished_on` | `string` | Date information | | `status` | `string` | Status information | | `response_collection` | `object` | Response collection | | `collection_id` | `string` | Collection id | | `transaction_id` | `string` | Transaction id | | `flows_responses` | `object` | Flows responses | | `_links` | `object` | Links | | `finance_metrics` | `string` | Finance metrics | | `health_metrics` | `string` | Health metrics | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/request-elements` #### Retrieve Request Elements `get-data-extraction-request-elements` Retrieve Request Elements retrieves a list of elements needed to invoke a partner for data extraction. ##### Response 200 Example v0200 Example v2404 application/json Copy Elements retrieved successfully. ``` { "$.document_sets.document_set[0].documents.document[0].document_classification.document_classes.document_class[0].type": null, "$.document_sets.document_set[0].documents.document[0].content.foreign_object.reference.location_label_value": null } ``` application/json Copy Elements retrieved successfully. ``` { "$.documents[0].@type": null, "$.documents[0].has_staircase_blob_identifier.has_value": null } ``` application/json Copy Elements not found. ``` { "message": "Elements not found." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `404``application/json` 1 fields Elements not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Elements not found. | ##### Other responses `200``400` `POST` `/classify` #### Classify Document `post-adr` Classify Document invokes a partner to classify the pages within a document according to document type(s). To invoke Classify Document, you will need: - a transaction_id, and - a collection_id. Once you have a transaction_id and collection_id, you can send them, along with your api key (authorization key) to as many partners as you want. Simply invoke Classify Document with the same transaction_id and collection_id, but with different partner names. Doing so enables you to get classification results from multiple partners, and to see which one provides the optimal response. Show the rest Classify Document returns, as a synchronous acknowledgement, a new collection_id. The new collection_id represents an empty container which will hold the partner's response once processing has completed. In case `partner_name` was provided as default, classify will be run through Ephesoft & DocumentAI partners. The `response_collection_id` will be a combined one, and we will provide the confidence score of Staircase which will be equal or higher than the one of a singular partner. ##### Request example-1example-2application/json application/json Copy ``` { "transaction_id": "01FM04Q4WKNGG0AWRKPBC8KBC3", "collection_id": "01FM04QXEVT3V2SXBV2KM74RV2", "partner_name": "ocrolus" } ``` application/json Copy ``` { "transaction_id": "01FM04Q4WKNGG0AWRKPBC8KBC3", "collection_id": "01FM04QXEVT3V2SXBV2KM74RV2", "partner_name": "ocrolus", "options": { "separate_document_blobs": true } } ``` application/json Copy ``` { "transaction_id": "", "collection_id": "", "partner_name": "ocrolus" } ``` ##### Response 200422 InvalidTransactionIDFormat422 InvalidCollectionIDFormat500 application/json Copy Document classification request created successfully. ``` { "collection_id": "01EZY95SC1K85WTA3J66R81WCV", "message": "When ready, data will be available in the collection specified by this collection_id. Use this new collection_id to get the execution status." } ``` application/json Copy Unprocessable Entity ``` { "message": "transaction_id value had non-alphanumeric characters. Please check transaction id" } ``` application/json Copy Unprocessable Entity ``` { "message": "collection_id value had non-alphanumeric characters. Please check collection id" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string (ulid)` | Transaction IDExample `01FM04Q4WKNGG0AWRKPBC8KBCP` | | `collection_id`required | `string (ulid)` | Collection IDExample `01FM04QXEVT3V2SXBV2KM74RV1` | | `partner_name`required | `string` | Partner name such as DocumentAI`default``documentai``ephesoft``ocrolus` | | `callback_url` | `string` | Callback url | | `options` | `object` | Additional options for document classification | | `separate_document_blobs` | `boolean` | In case blob contains multiple documents response collection will contain unique blob_id for each document classified | ##### Response `200``application/json` 2 fields Document classification request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `400``403``404``422` `POST` `/extract` #### Extract Data `post-data-extraction-extract` Extract Data invokes a partner to extract the data within a document according to document type. To invoke Extract Data, you will need: - a transaction_id, and - a collection_id. Once you have a transaction_id and collection_id, you can send them, along with your api_key (authorization key) to as many partners as you want. Simply invoke Extract Data with the same transaction_id and collection_id, but with different partner names. Doing so enables you to extract data using multiple partners, and to see which one provides the optimal response. Extract Data returns, as a synchronous acknowledgement, a new collection_id. The new collection_id represents an empty container which will hold the partner's response once processing has completed. ##### Request Example 1Example 2Example 3application/json application/json Copy ``` { "transaction_id": "01EZY81SYVQ98YYG0KMM462NKZ", "collection_id": "01EZY9J8SEFM2JKDJ1Q3YX65HS", "partner_name": "ocrolus" } ``` application/json Copy ``` { "transaction_id": "01EZY81SYVQ98YYG0KMM462NKZ", "collection_id": "01EZY9J8SEFM2JKDJ1Q3YX65HS", "partner_name": "ocrolus", "options": { "include_simplified_response": false } } ``` application/json Copy ``` { "transaction_id": "01EZY81SYVQ98YYG0KMM462NKZ", "collection_id": "01EZY9J8SEFM2JKDJ1Q3YX65HS", "partners": [ "ocrolus" ] } ``` application/json Copy ``` { "transaction_id": "", "collection_id": "", "partner_name": "ocrolus", "data_elements": [ "element1", "element2" ] } ``` ##### Response 200 Example 1200 Example 2 application/json Copy Data Extraction request created successfully. ``` { "collection_id": "01EZY94X63AXWZ14TT8R1MAS3S" } ``` application/json Copy Data Extraction request created successfully. ``` { "response_collections": [ { "collection_id": "01EZY94X63AXWZ14TT8R1MAS3S" }, { "collection_id": "01EZY9J8SEFM2JKDJ1Q3YX65HS" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 7 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name` | `string` | Name of partner providing data extraction. If you wish to invoke multiple partners with one request you can use partners parameter instead. If this parameter is not set then it is required to set partners parameter`documentai``ocrolus` | | `partners` | `string[]` | List of partners you want to use for extraction. If this parameter is not set then you have to set partner_name parameter | | `callback_url` | `string` | Callback url | | `data_elements` | `string[]` | All elements that need to be selected in the response | | `options` | `object` | Additional settings for extraction. | | `include_simplified_response` | `boolean` | Simplified response has simple structure and better field coverage. In case request collections is v0 this value is set to true by default. For v2 request collections this value is set to false by default. | ##### Response `200``application/json` 3 fields Data Extraction request created successfully. | Field | Type | Description | | --- | --- | --- | | `response_collections` | `object[]` | In case partners parameter is set in request payload response will contain this object. | | `collection_id`required | `string` | Collection ID | | `message`required | `string` | Message with additional information about execution | | `collection_id` | `string` | Response will contain this parameter only if partner_name parameter is set in request collection | | `message` | `string` | Response will contain this parameter only if partner_name parameter is set in request collection | ##### Other responses `400` `GET` `/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-data-extraction-status` Retrieve Status determines if a partner has completed data extraction for a document. ##### Response application/json Copy Request received. Potential status responses: 'REQUEST_MADE', 'WAITING_FOR_RESPONSE', 'COMPLETED', 'ERROR'" ``` { "status": "COMPLETED" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `transaction_id` required | `string` path | `01EZY95SC1K85WTA3J66R81WCV` | Transaction ID | | `collection_id` required | `string` path | `01EZY9J8SEFM2JKDJ1Q3YX65HS` | Collection ID | ##### Response `200``application/json` 1 fields Request received. Potential status responses: 'REQUEST_MADE', 'WAITING_FOR_RESPONSE', 'COMPLETED', 'ERROR'" | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Request received. | ##### Other responses `400``403``404` ### PDFs `POST` `/fill` #### Fill PDF template with data `fill_pdf` Fill PDF This endpoint takes a document's content in JSON format, translates it into the specified target language, and then fills a PDF template using the translated content. It requires a blob ID for the PDF template, the target language for translation, and the data to be translated. The process involves translating the input data, mapping it according to a predefined schema, and dynamically filling the PDF with the translated content, returning a new blob ID for the filled document. For now endpoint works only with `loan-application-doc-language-v2` language. Source blob_id should be 1003 borrower information PDF from this link: ##### Request application/json Copy ``` { "blob_id": "01G92FSH5FYKQE6X22FECB95V2", "to_language_name": "loan-application-doc-language", "data": { "properties": { "@id": "01HB6AQNA7M9ZR9SB4KH8D4ECS", "@type": "property", "property_acquired_date": "2022-12-19", "property_type": "SingleFamily", "community_property_state_indicator": false, "existing_clean_energy_lien_indicator": false, "property_existing_lien_amount": 10000, "property_estate_type": "FeeSimple", "lease_expiration_date": "2024-12-12", "property_in_project_indicator": true, "construction_improvement_cost_amount": 15000, "lot_original_cost_amount": 20000, "native_american_lands_type": "IndividualTrustLand" } } } ``` ##### Response 200400404 application/json Copy OK. ``` { "to_language_name": "loan-application-doc-language", "data": { "properties": { "@id": "01HB6AQNA7M9ZR9SB4KH8D4ECS", "@type": "property", "property_acquired_date": "2022-12-19", "property_type": "SingleFamily", "community_property_state_indicator": false, "existing_clean_energy_lien_indicator": false, "property_existing_lien_amount": 10000, "property_estate_type": "FeeSimple", "lease_expiration_date": "2024-12-12", "property_in_project_indicator": true, "construction_improvement_cost_amount": 15000, "lot_original_cost_amount": 20000, "native_american_lands_type": "IndividualTrustLand" } }, "generated_blob_id": "01G92FSH5FYKQE6X22FECB95V2" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `blob_id`required | `string` | Blob ID | | `to_language_name` | `string` | Language name to translate data | | `data` | `object` | Data to fill in PDF template | ##### Response `200``application/json` 4 fields OK. | Field | Type | Description | | --- | --- | --- | | `to_language_name` | `string` | language data | | `data` | `object` | language data | | `generated_blob_id` | `string` | Generated blob ID | | `warnings` | `object` | Warning message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/generate-language-pdf` #### Generate language from PDF template `generate_language_pdf` Generate mapping from PDF template Generates the language definition of PDF template from blob. Generation type is language by default. Generation type `language` generates Language product definition from PDF template. Generation type `form` generates form to fill PDF template. Generation type `info` generates information data about PDF template fields. ##### Request application/json Copy ``` { "blob_id": "01G92FSH5FYKQE6X22FECB95V2" } ``` ##### Response 200400404 application/json Copy OK. ``` { "format": "json", "type": "class", "company_name": "Staircase", "product_name": "PDFGenerator", "data": { "Amount": { "type": "string" } } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `blob_id`required | `string` | Blob ID | | `generation_type` | `string` | Generation type`language``form``info` | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `data` | `object` | language data | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/fill-pre-approval` #### Fill Pre approval PDF template with data `fill_pdf_pre_approval` Fill PDF Pre approval This endpoint takes a document's content in JSON format, translates it into the specified target language, and then fills a PDF template using the translated content. It requires a the target language for translation, and the data to be translated. The process involves translating the input data, mapping it according to a predefined schema, and dynamically filling the PDF with the translated content, returning a new blob ID for the filled document. For now endpoint works only with `pre-approval-letter` language. ##### Request application/json Copy ``` { "data": { "people": [ { "@id": "_borrower", "@type": "person", "first_name": "Vladyslav", "middle_name": "J", "last_name": "Kartavets" }, { "@id": "_borrower2", "@type": "person", "first_name": "Mariia", "last_name": "Kartavets" }, { "@id": "_borrower3", "@type": "person", "first_name": "MMM", "last_name": "Kartavets" } ], "relationships": [ { "@type": "finance_relation", "role": "Borrower", "has_loan": "_loan", "has_person": "_borrower" }, { "@type": "finance_relation", "role": "CoBorrower", "has_loan": "_loan", "has_person": "_borrower2" }, { "@type": "finance_relation", "role": "CoBorrower", "has_loan": "_loan", "has_person": "_borrower3" } ], "loans": [ { "@id": "_loan", "@type": "loan", "has_property": "_property", "base_loan_amount": 425000, "note_rate_percent": 5.948, "loan_amortization_period_count": 30, "loan_amortization_period_type": "Year", "amortization_type": "Fixed", "rebate_percent": 1.1 } ], "properties": [ { "@id": "_property", "@type": "property", "has_address": "_address" } ], "addresses": [ { "@id": "_address", "@type": "address", "address_line_1": "1452 N. Mustang Rd", "city_name": "Mustang", "state_code": "OK", "postal_code": "73604" } ] } } ``` ##### Response 200400404 application/json Copy OK. ``` { "data": { "people": [ { "@id": "_borrower", "@type": "person", "first_name": "Vladyslav", "middle_name": "J", "last_name": "Kartavets" }, { "@id": "_borrower2", "@type": "person", "first_name": "Mariia", "last_name": "Kartavets" }, { "@id": "_borrower3", "@type": "person", "first_name": "MMM", "last_name": "Kartavets" } ], "relationships": [ { "@type": "finance_relation", "role": "Borrower", "has_loan": "_loan", "has_person": "_borrower" }, { "@type": "finance_relation", "role": "CoBorrower", "has_loan": "_loan", "has_person": "_borrower2" }, { "@type": "finance_relation", "role": "CoBorrower", "has_loan": "_loan", "has_person": "_borrower3" } ], "loans": [ { "@id": "_loan", "@type": "loan", "has_property": "_property", "base_loan_amount": 425000, "note_rate_percent": 5.948, "loan_amortization_period_count": 30, "loan_amortization_period_type": "Year", "amortization_type": "Fixed", "rebate_percent": 1.1 } ], "properties": [ { "@id": "_property", "@type": "property", "has_address": "_address" } ], "addresses": [ { "@id": "_address", "@type": "address", "address_line_1": "1452 N. Mustang Rd", "city_name": "Mustang", "state_code": "OK", "postal_code": "73604" } ] }, "generated_blob_id": "01G92FSH5FYKQE6X22FECB95V2" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | Data to fill in PDF template | ##### Response `200``application/json` 3 fields OK. | Field | Type | Description | | --- | --- | --- | | `data` | `object` | language data | | `generated_blob_id` | `string` | Generated blob ID | | `warnings` | `object` | Warning message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` `POST` `/fill-listing-agreement` #### Fill Listing Agreement PDF template with data `fill_pdf_listing_cancellation` Fill PDF Listing Cancellation This endpoint takes a document's content in JSON format and then fills a PDF template using the translated content. It requires the data to be translated. The process involves translating the input data, mapping it according to a predefined schema, and dynamically filling the PDF with the translated content, returning a new blob ID for the filled document. ##### Request application/json Copy ``` { "data": { "lead": { "@id": "01J17WAPBYY5A3C3EB342K1TRT", "@type": "lead", "has_listing": { "@id": "01J17WAPBY69HXZ1C8XP7HMW1X", "@type": "listing", "broker_cancellation_fee_amount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "0" }, "broker_cancellation_fee_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "true" }, "broker_compensation_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "true" }, "conditional_termination_agreement_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "true" }, "current_list_price_amount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "2500000" }, "exclusive_brokerage_listing_agreement_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "false" }, "exclusive_right_of_sale_listing_agreement_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "true" }, "exclusive_right_to_lease_agreement_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "false" }, "has_agent": [ { "@id": "01J17WAPBYCV1NKE2F810G9D82", "@type": "person", "first_name": "Kesa", "last_name": "Longfellow" }, { "@id": "01J17WAPBYSAS7JVKVJP52H9Y6", "@type": "person", "first_name": "Robert", "last_name": "Thomson" } ], "has_agent_company": { "@id": "01J17WAPBYN3R18K0ENCQJVEEM", "@type": "company", "name": "Waterfront Properties & Club C (303140)" }, "has_listing_timeline": [ { "@id": "01J17WAPBY1RJYRCVV5YH3E9HM", "@type": "listing_timeline", "listing_status_type": "Active" }, { "@id": "01J17WAPBYNJYWKAQPR53FR3GA", "@type": "listing_timeline", "price_date": "2023-10-14", "price_type": "InitialListing" }, { "@id": "01J17WAPBYNX103Z4TG7SASWDP", "@type": "listing_timeline", "price_amount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "2500000" }, "price_date": "2023-10-15", "price_type": "MinSold" } ], "has_previous_version": { "@id": "01J17WAPBY69HXZ1C8XP7HMW1X_2" }, "listing_agreement_price_terms": "785,000.00", "listing_agreement_price_terms_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "false" }, "listing_agreement_termination_date": "2024-10-25", "listing_agreement_termination_date_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "true" }, "listing_identifier": "RX-10927244", "listing_property_description": "Crystal Pointe PL 2 Lt 25, Washer and Dryer, Refrigerator, Oven, Microwave, Dish Washer, All Window Coverings, all pool equipment", "listing_status_type": "Active", "special_listing_conditions": "Listing Brokers commission to be paid at time of listing agreement. Cooperating Brokers will be paid at funding.", "special_listing_conditions_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "true" }, "unconditional_termination_agreement_indicator": { "@type": "http://www.w3.org/2001/XMLSchema#boolean", "@value": "false" } }, "has_person": [ { "@id": "01J17WAPBY2K8Z6PS1WY5Y93WW", "@type": "person", "first_name": "WALTER", "has_communication_method": [ { "@id": "01J17WAPBXNHYKESB682SBGN3V", "@type": "communication", "phone_number": "7463044" }, { "@id": "01J17WAPBXVNJMB1TT77XVYWSA", "@type": "communication", "phone_number": "8637634638" }, { "@id": "01J17WAPBX4KR4WS9Y2KXXD08T", "@type": "communication", "phone_number": "5619727157" }, { "@id": "01J17WAPBXHVAST0QWEH80RPX0", "@type": "communication", "phone_number": "5617463044" } ], "last_name": "ARRINGTON", "middle_name": "" }, { "@id": "01J17WAPBY6D6PK74KMT7QKN23", "@type": "person", "first_name": "BETTY", "last_name": "ARRINGTON", "middle_name": "" } ], "has_property": { "@id": "01J17WAPBYYPC0PKEVBZQDN2TZ", "@type": "property", "bedroom_count": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "4" }, "covered_spaces": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "2" }, "full_bathroom_count": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "3" }, "garage_spaces": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "2" }, "gross_living_area_square_feet_number": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "4104" }, "half_bathroom_count": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "0" }, "has_address": { "@id": "01J17WAPBY1W0FCZGYADP20KSN", "@type": "address", "address_line_1": "12274 150th Ln N", "city_name": "Jupiter", "country_code": "US", "country_name": "USA", "county_code": "12099", "county_name": "Palm Beach", "full_address": "12274 150th Ln N, Jupiter, FL 33478-3512, United States", "latitude": { "@type": "http://www.w3.org/2001/XMLSchema#decimal", "@value": "-80.22953" }, "longitude": { "@type": "http://www.w3.org/2001/XMLSchema#decimal", "@value": "26.89854" }, "plus_four_postal_code": "3512", "postal_code": "33478", "sequence_number": "12274", "state_code": "FL", "street_name": "150th Ln N" }, "has_appliance": [ { "@id": "01J17WAPBX70H0YY9WQMKQ0TFF", "@type": "appliance", "appliance_type": "Washer" }, { "@id": "01J17WAPBX0RD6N57C93HEJJPM", "@type": "appliance", "appliance_type": "WaterSoftenerOwned" }, { "@id": "01J17WAPBXK7RQE050QSWCDMPQ", "@type": "appliance", "appliance_type": "Refrigerator" }, { "@id": "01J17WAPBXD3XY93XB4T8VAGM0", "@type": "appliance", "appliance_type": "Microwave" }, { "@id": "01J17WAPBXTEYZHZTHDTRTVF51", "@type": "appliance", "appliance_type": "GasWaterHeater" }, { "@id": "01J17WAPBXYGG2TXE5NNGECY7C", "@type": "appliance", "appliance_type": "GasRange" }, { "@id": "01J17WAPBX4AMFY6K66XFA7PFK", "@type": "appliance", "appliance_type": "Dishwasher" }, { "@id": "01J17WAPBXW7M1PH3K894EMXAA", "@type": "appliance", "appliance_type": "Dryer" }, { "@id": "01J17WAPBXGMFJV2KJHA1HCBG0", "@type": "appliance", "appliance_type": "BuiltInOven" } ], "has_exterior": [ { "@id": "01J17WAPBX7HP9CJ34AM2A3QA0", "@type": "exterior", "parking_type": "GarageDoorOpener" }, { "@id": "01J17WAPBXNZ9EX8E0ZHA35JT5", "@type": "exterior", "parking_type": "TwoOrMoreSpaces" }, { "@id": "01J17WAPBX0ZZZK5DSJEWRB9NW", "@type": "exterior", "parking_type": "Other", "parking_type_other_description": "RV Access/Parking" }, { "@id": "01J17WAPBXGZ1JASW2ZAMMN1B5", "@type": "exterior", "parking_type": "Other", "parking_type_other_description": "Open" }, { "@id": "01J17WAPBX4P828R02XRMBVYJ4", "@type": "exterior", "parking_type": "Other", "parking_type_other_description": "Guest" }, { "@id": "01J17WAPBXTRMMQ944K216C9KF", "@type": "exterior", "parking_type": "Other", "parking_type_other_description": "Golf Cart Garage" }, { "@id": "01J17WAPBX5J7BBA26Q56SMWWE", "@type": "exterior", "parking_type": "Garage" }, { "@id": "01J17WAPBX44Z547DBP8T2PE6N", "@type": "exterior", "parking_type": "Driveway" }, { "@id": "01J17WAPBXY00DKQTSM7MNMQ8A", "@type": "exterior", "parking_type": "Other", "parking_type_other_description": "Covered" }, { "@id": "01J17WAPBXRPE71NEQHQDKSH7P", "@type": "exterior", "parking_type": "CircularDriveway" }, { "@id": "01J17WAPBXCRTKHXQWF1CV2Y6T", "@type": "exterior", "parking_type": "Attached" } ], "has_structure": [ { "@id": "01J17WAPBXRVE16C04VG31EXT2", "@type": "structure", "window_type": "ImpactGlass" }, { "@id": "01J17WAPBX2PQ23SS998W2DRR1", "@type": "structure", "window_type": "Other", "window_type_other_description": "Blinds" }, { "@id": "01J17WAPBXJERD12ST5XXV9P0Y", "@type": "structure", "roof_type": "Other", "roof_type_other_description": "Metal" }, { "@id": "01J17WAPBXE64385CRBCERXA75", "@type": "structure", "construction_material_type": "Block" }, { "@id": "01J17WAPBXNCM0BXDP15G53TJV", "@type": "structure", "flooring_type": "Other", "flooring_type_other_description": "Vinyl" }, { "@id": "01J17WAPBXP1Q2X4QXY79PQ77C", "@type": "structure", "flooring_type": "Other", "flooring_type_other_description": "Carpet" } ], "has_utility": [ { "@id": "01J17WAPBYNF3MVD9RFTFJ2Z96", "@type": "utility", "cooling_system_type": "Electric" }, { "@id": "01J17WAPBYJ8R7208NBEVTA04J", "@type": "utility", "cooling_system_type": "Other", "cooling_system_type_other_description": "Ceiling Fan(s)" }, { "@id": "01J17WAPBY2EVRGT1T7WW0CJQ0", "@type": "utility", "cooling_system_type": "CentralAir" }, { "@id": "01J17WAPBYSB8G88NT0MEQ8VK2", "@type": "utility", "water_source_type": "Well" }, { "@id": "01J17WAPBYD06T872GT0V97VVW", "@type": "utility", "public_utility_type": "Other", "public_utility_type_other_description": "Natural Gas Available" }, { "@id": "01J17WAPBY9D4HSC1WA766C22X", "@type": "utility", "public_utility_type": "ElectricityAvailable" }, { "@id": "01J17WAPBY60D4C50AJQKPK6ZG", "@type": "utility", "public_utility_type": "CableAvailable" }, { "@id": "01J17WAPBYY14KBZBP15AC92D0", "@type": "utility", "sewer_type": "Septic" }, { "@id": "01J17WAPBY6MJDPW9VSWRGXGWE", "@type": "utility", "heating_system_type": "Central" } ], "property_structure_built_year": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "2021" }, "property_type": "SingleFamily", "stories_count": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "subdivision": "Jupiter Farms", "total_room_count": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "7" } }, "lead_identifier": "01J17WAPBYY5A3C3EB342K1TRT", "has_real_estate_agent_notes": [ { "@id": "01J1C80RB815MHH1VH81Y5FGRF", "@type": "chat_message", "message_content": "Real Estate Agent left a chat card on Walter Arrington's gate.", "message_datetime": "2024-06-27T07:02:06.811085" }, { "@id": "01J1CCFY9D7ZHFJZAP7ZGBBX63", "@type": "chat_message", "message_content": "Left ChatMTG card to Walter Arrington", "message_datetime": "2024-06-27T08:20:18.725224" }, { "@id": "01J1FT99PVPP87YDGM9S73J9R3", "@type": "chat_message", "message_content": "Real Estate Agent left a chat card on Walter Arrington's gate on June 27, 2024.", "message_datetime": "2024-06-28T16:19:04.387580" }, { "@id": "01J1FT9CY58CQEAZXNWDAKQXDQ", "@type": "chat_message", "message_content": "Real Estate Agent left a chat card to Walter Arrington on June 27, 2024.", "message_datetime": "2024-06-28T16:19:07.711293" }, { "@id": "01J1PS2PZZM3ZD0CJN78KWMFH0", "@type": "chat_message", "message_content": "Generated icebreaker prompts for Walter Arrington.", "message_datetime": "2024-07-01T09:12:41.075499" }, { "@id": "01J1Q0N1K9J744E80KGB10ENJX", "@type": "chat_message", "message_content": "Client is ready to move the listing.", "message_datetime": "2024-07-01T11:25:01.786014" }, { "@id": "01J1Q0S1XDZ1PDWYWT76WFAD7J", "@type": "chat_message", "message_content": "Broker's name is Alex Taylor.", "message_datetime": "2024-07-01T11:27:13.173127" }, { "@id": "01J1Q6NNHMFFMVNYCCC47AQE0J", "@type": "chat_message", "message_content": "Lead Walter Arrington is ready to move the listing at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T13:10:13.661928" }, { "@id": "01J1Q6SBS0FHG9HE1GNEMAP7SF", "@type": "chat_message", "message_content": "The lead, Walter Arrington, has agreed to move the listing.", "message_datetime": "2024-07-01T13:12:14.625923" }, { "@id": "01J1Q6VCTHREFN9ESZF583XFK6", "@type": "chat_message", "message_content": "The lead agreed to move the listing.", "message_datetime": "2024-07-01T13:13:21.328873" }, { "@id": "01J1Q6YA254NY7TXN8D7ZKGKFD", "@type": "chat_message", "message_content": "Lead Walter Arrington is ready to move the listing", "message_datetime": "2024-07-01T13:14:56.831426" }, { "@id": "01J1Q7339B8VFYKDRWV80RBFK2", "@type": "chat_message", "message_content": "The client, Walter Arrington, is ready to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T13:17:33.721484" }, { "@id": "01J1Q76MAZXZAW4CV0WXZYN8CX", "@type": "chat_message", "message_content": "The client, Walter Arrington, is ready to move the listing at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T13:19:29.481406" }, { "@id": "01J1Q7B2CJTT3KXW75Q2H8VPEJ", "@type": "chat_message", "message_content": "Lead Walter Arrington is ready to move the listing", "message_datetime": "2024-07-01T13:21:54.944470" }, { "@id": "01J1Q7ZRVY0PXKH5RSJZBGFMQQ", "@type": "chat_message", "message_content": "Lead Walter Arrington agreed to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478", "message_datetime": "2024-07-01T13:33:13.339853" }, { "@id": "01J1Q91P0QH4BZZVYV9TV07VB1", "@type": "chat_message", "message_content": "The client is ready to move their listing.", "message_datetime": "2024-07-01T13:51:44.524739" }, { "@id": "01J1Q91VSB3WTVDYR1TKC0SN3A", "@type": "chat_message", "message_content": "Walter Arrington is ready to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T13:51:50.423623" }, { "@id": "01J1Q91WP9DA3KW86B6801B3QA", "@type": "chat_message", "message_content": "The lead, Walter Arrington, is ready to move the listing.", "message_datetime": "2024-07-01T13:51:51.362478" }, { "@id": "01J1Q91Z7XXGNFCH80AEMGCZ6X", "@type": "chat_message", "message_content": "Lead agreed to move the listing.", "message_datetime": "2024-07-01T13:51:53.977552" }, { "@id": "01J1Q9212950NFAZPZDS7RWT2R", "@type": "chat_message", "message_content": "Lead Walter Arrington is ready to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T13:51:55.837267" }, { "@id": "01J1Q9FD2CJ6ME5SDM52BZ9H6G", "@type": "chat_message", "message_content": "Walter Arrington agreed to move the listing.", "message_datetime": "2024-07-01T13:59:14.114412" }, { "@id": "01J1Q9FEJGR0WYGQSWVZ4DC2R6", "@type": "chat_message", "message_content": "Lead agreed to move the listing to us.", "message_datetime": "2024-07-01T13:59:15.639663" }, { "@id": "01J1Q9M9T9HPPP8MTKB74YKV0S", "@type": "chat_message", "message_content": "Lead agreed to move the listing.", "message_datetime": "2024-07-01T14:01:54.618791" }, { "@id": "01J1Q9MF109ARJ3JJJ7PNDM1NA", "@type": "chat_message", "message_content": "Walter Arrington is ready to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T14:01:59.959381" }, { "@id": "01J1Q9RBJWDDJJPQX4BYYAEES1", "@type": "chat_message", "message_content": "Lead Walter Arrington agreed to move the listing.", "message_datetime": "2024-07-01T14:04:07.499670" }, { "@id": "01J1Q9RBM9VWD2F716MP2VAWPH", "@type": "chat_message", "message_content": "The lead expressed readiness to move his listing.", "message_datetime": "2024-07-01T14:04:07.551797" }, { "@id": "01J1QA4VXAXPWXF5WC2JSS9R0B", "@type": "chat_message", "message_content": "Walter Arrington is ready to move his listing.", "message_datetime": "2024-07-01T14:10:57.425425" }, { "@id": "01J1QA4X1MVZA90Z35ZH5GMY9A", "@type": "chat_message", "message_content": "Walter Arrington is ready to move the listing.", "message_datetime": "2024-07-01T14:10:58.601251" }, { "@id": "01J1QAEGZF23F0WPAB0C54FFEY", "@type": "chat_message", "message_content": "Lead agreed to move the listing.", "message_datetime": "2024-07-01T14:16:13.922487" }, { "@id": "01J1QAEMY0R0CMP39JS7B4QZ2J", "@type": "chat_message", "message_content": "Walter Arrington is ready to move the listing.", "message_datetime": "2024-07-01T14:16:17.977624" }, { "@id": "01J1QAMBS15KANVMB4Z7PM8DK9", "@type": "chat_message", "message_content": "Lead Walter Arrington is ready to move the listing.", "message_datetime": "2024-07-01T14:19:25.176210" }, { "@id": "01J1QAMJTPPGC3QG4V9QPKEZ7M", "@type": "chat_message", "message_content": "Walter Arrington is ready to move the listing.", "message_datetime": "2024-07-01T14:19:32.409926" }, { "@id": "01J1QAMPEGC9ZF5B2XMX6XKPNC", "@type": "chat_message", "message_content": "Lead agrees to move the listing.", "message_datetime": "2024-07-01T14:19:36.131188" }, { "@id": "01J1QB4XEG2MVY8TDPEHT6S0A3", "@type": "chat_message", "message_content": "Lead WALTER ARRINGTON has agreed to move the listing at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T14:28:27.600725" }, { "@id": "01J1QB50AZARAZKZ9R96KGBX1C", "@type": "chat_message", "message_content": "The lead is ready to move the listing.", "message_datetime": "2024-07-01T14:28:30.547010" }, { "@id": "01J1QB53YPWRA29RR4Z7YJZ98D", "@type": "chat_message", "message_content": "Lead is ready to move their listing.", "message_datetime": "2024-07-01T14:28:34.246355" }, { "@id": "01J1QB9GP4T8Y2R1Q4V609NCVX", "@type": "chat_message", "message_content": "Client Walter Arrington is ready to move the listing at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T14:30:58.345685" }, { "@id": "01J1QB9JY449NERKQK7RR9RPB6", "@type": "chat_message", "message_content": "The client, Walter Arrington, is ready to move the listing.", "message_datetime": "2024-07-01T14:31:00.662517" }, { "@id": "01J1QB9QYCR3D7AYANQ4ZWBST7", "@type": "chat_message", "message_content": "Lead agreed to move their listing.", "message_datetime": "2024-07-01T14:31:05.785133" }, { "@id": "01J1QC5BD0HXAFJGZJBZ43WY27", "@type": "chat_message", "message_content": "Lead is ready to move the listing.", "message_datetime": "2024-07-01T14:46:10.442077" }, { "@id": "01J1QC5DMCVYQESSTQ8FT0JDNZ", "@type": "chat_message", "message_content": "Lead is ready to move the listing.", "message_datetime": "2024-07-01T14:46:12.735697" }, { "@id": "01J1QDAKJ57R02QY94EXC3WVG4", "@type": "chat_message", "message_content": "Generated tailored icebreaker prompts for Walter Arrington.", "message_datetime": "2024-07-01T15:06:31.223288" }, { "@id": "01J1QEEBS5YEB6XHQPVWAN1C7W", "@type": "chat_message", "message_content": "Walter Arrington is ready to move their listing.", "message_datetime": "2024-07-01T15:26:02.909692" }, { "@id": "01J1QEECDWV89MQ9A1FRG38W1Q", "@type": "chat_message", "message_content": "Walter Arrington is ready to move the listing.", "message_datetime": "2024-07-01T15:26:03.572510" }, { "@id": "01J1QEECKX37Q78GWH67N1GNH1", "@type": "chat_message", "message_content": "The client WALTER ARRINGTON is ready to move the listing.", "message_datetime": "2024-07-01T15:26:03.760093" }, { "@id": "01J1QEFFMF03H76C1AMPDP198A", "@type": "chat_message", "message_content": "Client Walter Arrington has agreed to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T15:26:39.616660" }, { "@id": "01J1QEN6WPK7PFWWAT825243YJ", "@type": "chat_message", "message_content": "Walter Arrington agreed to move the listing for the property at 12274 150th Ln N, Jupiter, FL, 33478.", "message_datetime": "2024-07-01T15:29:47.280712" }, { "@id": "01J1QFD3JBT2NN01H3Q998H4X9", "@type": "chat_message", "message_content": "Borrower is ready to move their listing.", "message_datetime": "2024-07-01T15:42:50.311125" }, { "@id": "01J1SC35PMQP4MB3V2WC9RVPWN", "@type": "chat_message", "message_content": "Lead Walter Arrington agreed to move their listing.", "message_datetime": "2024-07-02T09:23:27.948810" }, { "@id": "01J1SC8BKT3E68CEKQT0J4BVJ2", "@type": "chat_message", "message_content": "The borrower, Walter Arrington, agreed to move their listing.", "message_datetime": "2024-07-02T09:26:17.838358" }, { "@id": "01J1SCWRFKEKSSQ0PCH66VKFJN", "@type": "chat_message", "message_content": "WALTER ARRINGTON is ready to move the listing.", "message_datetime": "2024-07-02T09:37:26.368239" }, { "@id": "01J1SCWS9M6GW0TZET9XYVQP83", "@type": "chat_message", "message_content": "WALTER ARRINGTON is ready to move the listing.", "message_datetime": "2024-07-02T09:37:27.211964" }, { "@id": "01J1SCWSH1SNCXDVMKNFEDDC0W", "@type": "chat_message", "message_content": "Lead expressed readiness to move the listing.", "message_datetime": "2024-07-02T09:37:27.449811" }, { "@id": "01J210ES4JYCMC5TD22CEF8ZCH", "@type": "chat_message", "message_content": "Borrower agreed to move their listing.", "message_datetime": "2024-07-05T08:34:00.841450" } ] } } } ``` ##### Response 200400404 application/json Copy OK. ``` { "generated_blob_id": "01G92FSH5FYKQE6X22FECB95V2" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy Requested resource not found ``` { "message": "Collection not found" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | Data to fill in PDF template | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `generated_blob_id` | `string` | Generated blob ID | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Requested resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `422` ### Operations `GET` `/blobs/{blob_id}` #### Retrieve Blob `retrieveBlob` Retrieve Blob retrieves, for a given blob_id, extension and presigned URLs for uploading and downloading the blob to and from Staircase. ##### Response 200403500 application/json Copy Blob retrieved successfully. ``` { "blob_id": "01EZY9ENJGRMTW4S9CS4V1Y6XH", "extension": ".pdf", "message": "Blob retrieved successfully.", "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket-us-east-1-867210375911.s3.amazonaws.com/01EZY9ENJGRMTW4S9CS4V1Y6XH" } } } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `blob_id` required | `string` path | `01EZY9J8SEFM2JKDJ1Q3YX65HS` | Blob identifier | ##### Response `200``application/json` 4 fields Blob retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string` | Blob ID | | `extension` | `string` | File extension | | `message` | `string` | Blob retrieved successfully. | | `presigned_urls` | `object` | Presigned URL | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `400``404` `POST` `/blobs/{blob_id}` #### Upload blob ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `blob_id` required | `string` path | Blob id | ##### Other responses `200` `GET` `/blobs/{blob_id}/presigned-urls` #### Retrieve Presigned URLs `retrievePresignedUrls` Retrieve Presigned URLs retrieves, for a given blob_id, presigned URLs for uploading and downloading the blob to and from Staircase. ##### Response 200403 application/json Copy Presigned URLs retrieved successfully. ``` { "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/01EZY9J8SEFM2JKDJ1Q3YX65HS" } } ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `blob_id` required | `string` path | `01EZY9J8SEFM2JKDJ1Q3YX65HS` | Blob identifier | ##### Response `200``application/json` 1 fields Presigned URLs retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `presigned_urls` | `object` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `400``404` `GET` `/blobs/{blob_id}/presigned-urls/{action}` #### Retrieve Presigned URL for Action `retrievePresignedUrl` Retrieve Presigned URL for Action retrieves a presigned URL for a specific action. An action can be download or upload. ##### Response 200403500 application/json Copy Presigned URL retrieved successfully. ``` { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/01EZY9J8SEFM2JKDJ1Q3YX65HS" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `blob_id` required | `string` path | `01EZY9J8SEFM2JKDJ1Q3YX65HS` | Blob identifier | | `action` required | `string` path | `upload` | Possible actions: - upload - download | ##### Response `200``application/json` 1 fields Presigned URL retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `url` | `string` | Presigned url | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `400``404` `PUT` `/blobs/{blob_id}/presigned-urls/{action}` #### Create Presigned URL `createPresignedUrl` Create Presigned URL creates a presigned URL in Staircase. The presigned URL is used to upload or download a blob (document). It expires one hour after creation. ##### Response 200403 application/json Copy Presigned URL created successfully. ``` { "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/01EZY9J8SEFM2JKDJ1Q3YX65HS" }, "download": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/01EZY9J8SEFM2JKDJ1Q3YX65HS" } } } ``` 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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `blob_id` required | `string (ulid)` path | `01EZQ32PJQGKRA6HR8D72Q9FFF` | Blob id | | `action` required | `string` path | `upload` | Action, one of one of ['upload', 'donwload'] | ##### Response `200``application/json` 1 fields Presigned URL created successfully. | Field | Type | Description | | --- | --- | --- | | `presigned_urls` | `object` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Other responses `400``404` `POST` `/blobs/upload/{blob_id}` #### Upload Blob `uploadBlob` Upload Blob uploads a document (blob) to a presigned URL via the HTML Request Maker. Try It Out: - Place your api_key in the request header, your blob_id in the path parameter - Set the request body to binary and browse to your document. - Click Send to upload your document. This service should be used in the HTML Request Maker Try it Out only. To upload a document within code, you need to use a PUT request to the presigned URL returned into the Create Blob response body. Show the rest ``` import requests # Create Blob endpoint returns blob_id and upload presigned url # For example, the presigned_url might look like this: presigned_url = "" # Set the path to the file you want to upload filepath = "document.pdf" # Set the headers appropriately headers = { 'Content-Type': 'application/pdf' } # Read the file data and make the PUT request with open(filepath, 'rb') as file: payload = file.read response = requests.put(url=upload_presigned_url, headers=headers, data=payload) ``` ##### Request application/octet-stream Copy ``` Select option 'binary' in order to upload file ``` ##### Response 200403500 application/json Copy Blob uploaded ``` { "message": "Blob uploaded." } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `blob_id` required | `string` path | `01EZY9HV24XQDGMNEPPXDNK0FY` | Blob identifier | ##### Response `200``application/json` 1 fields Blob uploaded | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Blob uploaded | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `400``404``405` `POST` `/build-payload` #### Build JSON Payload `retrieveExampleJSON` Build JSON Payload retrieves a JSON schema for either: - a request for product invocation, or - a response containing response details. To retrieve the employment verification request schema: 1. Invoke Retrieve Request Elements to get an array of product request elements. 1. Place the output from Retrieve Request Elements into the Build JSON Payload request body. 1. Place your api_key into the Build JSON Payload header. 1. Send the request to Build JSON Payload. You will receive a JSON schema in response, with null values that must be replaced with your own. To retrieve the product response schema: 1. Show the rest>Invoke Retrieve Response Elements to get the product response elements. 1. Place the output from Retrieve Response Elements into the Build JSON Payload request body. 1. Place your api_key into the Build JSON Payload header. 1. Send the request to Build JSON Payload. You will receive a JSON schema in response, with null values that will be replaced by the partner upon return of employment verification details. ##### Request application/json Copy ``` { "$.deal_sets.deal_set[0].deals.deal[0].parties.party[0].individual.name.first": "John", "$.deal_sets.deal_set[0].deals.deal[0].parties.party[0].individual.name.last": "Doe", "$.deal_sets.deal_set[0].deals.deal[0].loans.loan[0].loan_identifiers.loan_identifier[0].identifier": 12345, "$.deal_sets.deal_set[0].deals.deal[0].parties.party[0].taxpayer_identifiers.taxpayer_identifier[0].value": 67890 } ``` ##### Response 200400403500 application/json Copy Product Invocation Flow Payload. ``` { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "Thomas", "last": "Alex" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "12345" } ] }, "roles": { "role": [ { "borrower": { "residences": { "residence": [ { "address": { "line_text": "street 101", "city": "example city", "state": "state", "postal_code": "1234", "street_name": "street 23" } } ] } } } ] } } ] } } ] } } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `200` `POST` `/create_blob_from_content` #### Create Blob from Partner content `createBlobFromContent` Create Blob from Partner content will create a blob from the content that a partner has returned. The payload will be the extension path of the blob to be created in the vendor response object, content_path is the path of the content element in the vendor response object. ##### Response 201400 UnableToRetrieveURL400 UnableToExtractValues403422500 application/json Copy Presigned URLs retrieved successfully. ``` { "blob_id": "01F739J4XDSNCZMMJSJCB83PCQ" } ``` application/json Copy Invalid body request. ``` { "message": "Unable to retrieve url" } ``` application/json Copy Invalid body request. ``` { "message": "Unable to extract data from URL" } ``` 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" } ``` application/json Copy The server understands the content type of the request entity, and the syntax of the request entity is correct but was unable to process the contained instructions. ``` { "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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `extension_path` | `string` | JSON path where the extension is in the response object. If it is not specified, extension will be "pdf".Example `$.DocumentExension` | | `content_path`required | `string` | JSON path where the actual content is in the response object.Example `$.DocumentData` | | `decode_from_base64` | `boolean` | Need to decode a content from base64. | | `encode_to_base64` | `boolean` | Need to encode a content to base64. | | `url`required | `string` | URL with the partner response.Example `https://google.com` | ##### Response `201``application/json` 1 fields Presigned URLs retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string` | — | ##### Response `400``application/json` 1 fields Invalid body request. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields The server understands the content type of the request entity, and the syntax of the request entity is correct but was unable to process the contained instructions. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `POST` `/document-creation` #### Create Document Creation `post-document-creation` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Document Creation request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Document Creation request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `GET` `/document-creation/elements` #### Retrieve Elements `get-document-creation-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request. | Field | Type | Description | | --- | --- | --- | | `elements` | `object` | List of elements | `POST` `/document-creation/elements/complete` #### Validate Collection `post-document-creation-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `collection`required | `object` | — | ##### Response `400``application/json` 2 fields Collection is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/document-creation/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-document-creation-status` Retrieve Status checks status of your request. Possible statuses: - REQUEST_MADE - REQUEST_ACCEPTED - WAITING_FOR_RESPONSE - COMPLETED ##### Response 200400 application/json Copy Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Current execution status | ##### Response `400``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | `POST` `/document-creation/transactions` #### Create Transaction `post-document-creation-transaction` Create Transaction creates a transaction in Staircase. A transaction in Staircase is an acknowledgement that you want to call a Staircase product. It's a container for everything associated with that product invocation, and is correlated with a collection related to the product (e.g. a document). You need to create a new transaction every time you want to connect with a Staircase product. Staircase then associates everything, from a data and API execution standpoint, to that transaction. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | `POST` `/document-creation/transactions/{transaction_id}/collections` #### Create Collection `post-document-creation-collection` Create Collection creates a collection of elements . The elements within the collection are required. ##### Request application/json Copy ``` { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully created. ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `PUT` `/document-creation/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-document-creation-collection` Update Collection updates a collection of elements by new elements. ##### Request application/json Copy ``` { "sets": { "set": [ { "properties": { "property": [ { "propety_entry": { "propety_entries": { "datetime": "2020-05-05", "description": "Test Description", "event_type": "TestType" } }, "propety_class": { "propety_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully updated ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "properties": { "property": [ { "property_data": { "property_class": { "datetime": "2020-05-05", "description": "Info", "event_type": "TestEvent" } }, "document_classification": { "document_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `POST` `/products/ide-output-adapter/invocations` #### Invoke Specific Product Flow `InvokeSpecificProductFlow` Invoke Specific Product Flow helps you to invoke specific product flow, this endpoint shall: - Validate the input `transaction_id`, `request_collection_id`, `response_collection_id` if provided. - Create transaction if the `transaction_id` was not provided - Create input collection with the `request_data` provided if the `request_collection_id` was not provided. - Create empty output collection if the `response_collection_id` was not provided. - Validate the provided product name and the product flow name - Retrieve the product flow information associated to the provided Product Flow Name Show the resti>Translate the input collection from Staircase language to Vendor language if `input_translation_language' was configured for the product flow. - Run the connector flow associated to the Product Flow Name - Set the status, connector `invocation_id` and `output_translation_language` that will be used to translate the results from Vendor Language to Staircase language if `output_translation_language` was configured for the product flow. ##### Request application/json Copy ``` { "product_flow_name": "get-document-from-byte", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "callback_url": "https://webhook.site/3706b519-9426-4533-9868-14a7dec4fd97", "request_data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } } } ``` ##### Response 201400403500 application/json Copy Successfully started flow invocation. ``` { "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4", "status": "STARTED", "output_language_name": "staircase", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN" } ``` application/json Copy Request data failed validation ``` { "message": "string" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `product_flow_name` | `string` | — | | `transaction_id` | `string` | — | | `request_collection_id` | `string` | — | | `response_collection_id` | `string` | — | | `callback_url` | `string (uri)` | — | | `request_data` | `object` | — | ##### Response `201``application/json` 5 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | — | | `invocation_status` | `string` | — | | `transaction_id` | `string` | — | | `request_collection_id` | `string` | — | | `response_collection_id` | `string` | — | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/products/ide-output-adapter/invocations/{invocation_id}` #### Retrieve Product Flow Invocation Status `RetrieveProductFlowInvocationStatus` Retrieves the status of running Product flow invocation. ##### Response 200400403500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "status": "SUCCEEDED", "updated_at": "2021-05-27T15:17:59.859954-04:00", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "response_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN" } ``` application/json Copy Request data failed validation ``` { "message": "string" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `invocation_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Product flow invocation identifier | ##### Response `200``application/json` 5 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_status` | `string` | — | | `updated_at` | `string` | — | | `transaction_id` | `string` | — | | `request_collection_id` | `string` | — | | `response_collection_id` | `string` | — | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/products/ide-output-adapter/request-elements` #### Retrieve Request Elements `requestElements` Retrieve Request Elements retrieves a list of elements needed to invoke a data partner for product function invocation. ##### Response 200400403404500 application/json Copy Example for the Product Invocation Request Elements object ``` { "elements": [ "$.file_data_id" ] } ``` application/json Copy Validation Error ``` { "message": "3 is not of type 'string'. Failed validating 'type' in schema['properties']['deal_sets']['items'][0]['properties']['parties']['items'][0]['properties']['customer_transaction_ID']:" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Product with name superproduct is not found." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Response `200``application/json` 1 fields Elements were retrieved successfully | Field | Type | Description | | --- | --- | --- | | `elements`required | `string[]` | — | ##### Response `400``application/json` 1 fields Validation Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `POST` `/products/ide-output-adapter/request-elements/validate` #### Validate Collection `validateCollection` Validate Collection allows you to validate an input collection prior to submitting to our partners for a specific product. This endpoint will give messages with all the corrections you need to make to your collection in order for it to be accepted by our partner call. ##### Request application/json Copy ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` ##### Response 200400403404500 application/json Copy Collection is valid ``` { "message": "Collection is valid." } ``` application/json Copy Validation Error ``` { "message": "3 is not of type 'string'. Failed validating 'type' in schema['properties']['deal_sets']['items'][0]['properties']['parties']['items'][0]['properties']['customer_transaction_ID']:" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Product with name superproduct is not found." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `deal_sets` | `object` | — | | `deal_set` | `object[]` | — | | `deals` | `object` | — | | `deal` | `object[]` | — | ##### Response `200``application/json` 1 fields Collection is valid | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Validation Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/products/ide-output-adapter/request-schema` #### Retrieve Request Schema `retrieveRequestSchema` Retrieve Request Schema retrieves a JSON schema for the request to the product waterfall. It also has the option of returning an example for the request object expected through the return_example attribute. ##### Response 200400403404500 application/json Copy Successfully returned the list of elements needed for product waterfall. ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values: true, false" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Product with name superproduct is not found." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 1 fields Successfully returned the list of elements needed for product waterfall. | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | — | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/products/ide-output-adapter/response-elements` #### Retrieve Response Elements `responseElements` Retrieve Response Elements provides a list of elements that will be returned by a data partner after invoking the product. ##### Response 200400403404500 application/json Copy Example for the Product Invocation Request Elements object ``` { "elements": "not implemented." } ``` application/json Copy Validation Error ``` { "message": "3 is not of type 'string'. Failed validating 'type' in schema['properties']['deal_sets']['items'][0]['properties']['parties']['items'][0]['properties']['customer_transaction_ID']:" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Product with name superproduct is not found." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Response `200``application/json` 1 fields Elements were retrieved successfully | Field | Type | Description | | --- | --- | --- | | `elements`required | `string[]` | — | ##### Response `400``application/json` 1 fields Validation Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/products/ide-output-adapter/response-schema` #### Retrieve Response Schema `retrieveResponseSchema` Retrieve Schema retrieves a JSON schema for the response returned by the product. It can also return an example for the response output object through return_example attribute. ##### Response 200400403404500 application/json Copy Successfully returned the list of elements of response of the product waterfall. ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values: true, false" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Product with name superproduct is not found." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 1 fields Successfully returned the list of elements of response of the product waterfall. | Field | Type | Description | | --- | --- | --- | | `schema` | `object` | — | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` 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" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | adapter.staircaseapi.com environment API key. | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /get-collection ##### Request application/json Copy ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` ##### Response 201400403404500 application/json Copy Collection created successfully ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collection data" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction Id" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `document`required | `object` | — | | `file_data_id`required | `string` | — | | `metadata` | `—` | — | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection idExample `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `array` | — | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 200403404 GetCollectionError404 GetCollectionsError500 application/json Copy Successfully Retrieved Collection ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please check the transaction id" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 2 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `document`required | `object` | — | | `file_data_id`required | `string` | — | | `metadata` | `—` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ##### Other responses `400` `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given `collection_id` associated with a `transaction_id`. ##### Request application/json Copy ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` ##### Response 200400403404500 application/json Copy Collection updated successfully ``` { "data": { "request_example_v0": { "deal_sets": { "deal_set": [ { "deals": { "deal": [ { "parties": { "party": [ { "individual": { "name": { "first": "John", "last": "Deere" } }, "taxpayer_identifiers": { "taxpayer_identifier": [ { "value": "999-00-0000" } ] } } ] }, "loans": { "loan": [ { "loan_identifiers": { "loan_identifier": [ { "identifier": "6f039329-3fd6-44c1-a460-9af546e798de" } ] } } ] } } ] } } ] } } }, "metadata": {} } ``` application/json Copy Error ``` { "message": "Unable to update collection. Please check the collection data" } ``` 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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | adapter.staircaseapi.com environment API key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `document`required | `object` | — | | `file_data_id`required | `string` | — | | `metadata` | `—` | — | ##### Response `200``application/json` 2 fields Collection updated successfully | Field | Type | Description | | --- | --- | --- | | `data` | `object` | — | | `document`required | `object` | — | | `file_data_id`required | `string` | — | | `metadata` | `—` | — | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | — | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ## Providers - Docutech ## Errors `400``403``404``405``422``500` ## More in Contract - Next product: Electronic --- # Electronic # Electronic Electronic delivery of borrower-facing disclosures, and the acknowledgment record that delivery requires. Delivery of a disclosure is a regulated event with a timestamp, not a file transfer. The slot covers sending the loan estimate and closing disclosure electronically, capturing consent to electronic delivery, and recording acknowledgment — which is the record that establishes when a disclosure period began. The catalogue names this slot. No specification for it survives in the recorded definitions, so no endpoint detail is on record. ## More in Contract - Previous product: Document - Next product: Fee --- # Fee # Fee Closing-cost computation: the fee set on a closing disclosure, comparison between successive disclosures, and buy-up and buy-down mechanics. A caller sends the loan and the fees known so far and receives the computed closing-cost set, itemised into the sections the disclosure requires. Comparison between two disclosures is a first-class operation rather than a diff left to the caller: the answer is whether a change is one the tolerance rules permit, which is a computation over the pair. ## How it works Buy-up and buy-down are handled as an adjustment to the rate-price pair rather than as a separate fee line, because that is what they are: paying points moves the price, and the fee schedule follows from it. Keeping the mechanic where the price lives is what keeps the disclosure consistent with the lock. ## Operations ### Setup `GET` `/ernst/credentials` #### Get Ernst Credentials `getErnstCredentials` Get credentials of Ernst saved beforehand ##### Response 200 Example200 State Based Provider Example200 County Based Provider Example200 Complete Example400403404500 application/json Copy Setup API Triggered Successfully ``` { "username": "--------", "password": "", "title_provider_orderings": { "default_ordering": [ "fidelity", "first_american", "stewart" ] } } ``` application/json Copy Setup API Triggered Successfully ``` { "username": "--------", "password": "", "title_provider_orderings": { "states": [ { "state_code": "CA", "default_ordering": [ "first_american", "stewart" ] } ] } } ``` application/json Copy Setup API Triggered Successfully ``` { "username": "--------", "password": "", "title_provider_orderings": { "states": [ { "state_code": "CA", "default_ordering": [ "first_american", "stewart" ], "counties": [ { "county_name": "Alameda County", "default_ordering": [ "first_american", "stewart" ] } ] } ] } } ``` application/json Copy Setup API Triggered Successfully ``` { "username": "--------", "password": "", "title_provider_orderings": { "default_ordering": [ "stewart", "fidelity", "first_american" ], "states": [ { "state_code": "NY", "default_ordering": [ "stewart", "fidelity" ], "counties": [ { "county_name": "Suffolk", "default_ordering": [ "fidelity", "stewart" ], "cities": [ { "city_name": "Riverhead", "default_ordering": [ "fidelity", "first_american" ] } ] } ] }, { "state_code": "CA", "default_ordering": [ "first_american", "fidelity" ] } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Setup API Triggered Successfully ``` { "message": "Credentials not found" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Response `200``application/json` 3 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `username` | `string` | Ernst username | | `password` | `string` | Ernst password | | `title_provider_orderings` | `object` | An object to set default title fees' provider list for states, counties and cities | | `default_ordering` | `string[]` | Root default ordering for title fees' provider | | `states` | `object[]` | States | | `state_code` | `string` | State code | | `default_ordering` | `string[]` | Default title provider ordering for the state | | `counties` | `object[]` | Counties | | `county_name` | `string` | County name | | `default_ordering` | `string[]` | Default title provider ordering for the county | | `cities` | `object[]` | Cities | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | `POST` `/ernst/credentials` #### Set Ernst Credentials `setErnstCredentials` Set credentials to be used when Ernst is selected as Fees vendor. #### Usage You need to set your Ernst credentials to use Ernst as a vendor in Fees product. `username` and `password` are required credentials. For title fees Ernst works with three providers. You can choose the provider that is going to be used for the title fees. There are three available providers: Stewart, Fidelity and First American.`title_provider_orderings` is an array field that you can use to set your default provider choices for states, counties and cities. Show the rest Example: ``` { "title_provider_orderings": { "default_ordering": [ "stewart", "fidelity", "first_american" ], "states": [ { "state_code": "NY", "default_ordering": [ "stewart", "fidelity" ], "counties": [ { "county_name": "Suffolk", "default_ordering": [ "fidelity", "stewart" ], "cities": [ { "city_name": "Riverhead", "default_ordering": [ "fidelity", "first_american" ] } ] } ] }, { "state_code": "CA", "default_ordering": [ "first_american", "fidelity" ] } ] } } ``` Fees will check your default choices and find the most specific address in `title_provider_ordering` matching the address sent in the request. For example if your address object in the request is the following : ``` { "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" } } ``` Fees will first try Fidelity, and then First American, since this is the ordering for Riverhead, NY, according to configuration. If the address in the request is in NY state but in Westchester County, Fees will first try Stewart, and then Fidelity because that is the default ordering for NY according to configuration and there is no default ordering specified for Westchester County. If the request has an address in TX state, the root ordering in `title_provider_orderings` will be used meaning that Fees will first try Stewart , then Fidelity, and only if all of them fails First American will be tried. ##### Request ExampleState Based Provider ExampleCounty Based Provider ExampleComplete Example application/json Copy ``` { "username": "--------", "password": "", "title_provider_orderings": { "default_ordering": [ "fidelity", "first_american", "stewart" ] } } ``` application/json Copy ``` { "username": "--------", "password": "", "title_provider_orderings": { "states": [ { "state_code": "CA", "default_ordering": [ "first_american", "stewart" ] } ] } } ``` application/json Copy ``` { "username": "--------", "password": "", "title_provider_orderings": { "states": [ { "state_code": "CA", "default_ordering": [ "first_american", "stewart" ], "counties": [ { "county_name": "Alameda County", "default_ordering": [ "first_american", "stewart" ] } ] } ] } } ``` application/json Copy ``` { "username": "--------", "password": "", "title_provider_orderings": { "default_ordering": [ "stewart", "fidelity", "first_american" ], "states": [ { "state_code": "NY", "default_ordering": [ "stewart", "fidelity" ], "counties": [ { "county_name": "Suffolk", "default_ordering": [ "fidelity", "stewart" ], "cities": [ { "city_name": "Riverhead", "default_ordering": [ "fidelity", "first_american" ] } ] } ] }, { "state_code": "CA", "default_ordering": [ "first_american", "fidelity" ] } ] } } ``` ##### Response 200400403404422500 application/json Copy Setup API Triggered Successfully ``` { "message": "Credentials are saved" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Setup API Triggered Successfully ``` { "message": "Partner xyz not found" } ``` application/json Copy Request data failed validation ``` { "message": "Invalid request body", "error": "[object has missing required properties ([\"client_secret\"])]" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Staircase Environment API Key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `username` | `string` | Ernst username | | `password` | `string` | Ernst password | | `title_provider_orderings` | `object` | An object to set default title fees' provider list for states, counties and cities | | `default_ordering` | `string[]` | Root default ordering for title fees' provider | | `states` | `object[]` | States | | `state_code` | `string` | State code | | `default_ordering` | `string[]` | Default title provider ordering for the state | | `counties` | `object[]` | Counties | | `county_name` | `string` | County name | | `default_ordering` | `string[]` | Default title provider ordering for the county | | `cities` | `object[]` | Cities | ##### Response `200``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `422``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | | `error` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ### Fees `GET` `/products/fees/info` #### Fees Info `Fees Info` Get Fees Product Info ##### Response 400403422500 application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` application/json Copy Request data failed validation ``` { "message": "Invalid request body", "error": "[object has missing required properties ([\"client_secret\"])]" } ``` application/json Copy The product has encountered an internal server error ``` { "message": "The product has encountered an internal server error" } ``` ##### Response `200``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 2 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | | `error` | `string` | Message | ##### Response `500``application/json` 1 fields The product has encountered an internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message | ##### Other responses `404` ### Workflow `POST` `/products/fees/invocations` #### Invoke Product Flow `InvokeSpecificProductFlow` This endpoint retrieves the fees that may arise during closing. #### Usage You can send a request in two different ways: - Using `request_data`: If you provide this parameter, flow invocation would use the data here as input. If you also provide a `transaction_id` in the request body, Response Collection would be created in the related Transaction object. If you don't provide a `transaction_id` we will automatically create a Transaction for you and Response Collection would be created in this new Transaction as well. - Using `transaction_id` and `request_collection_id`: If you already have a request collection, you can provide its details using these two parameters. Note that in this case Response Collection would be created in the provided Transaction. Note: You cannot provide `product_flow_name` and `vendor_name` parameters together. When provided together, simply `product_flow_name` is used. Show the rest ##### Retrieving the Invocation Result After invocation, endpoint returns an `invocation_id` which you can poll for its status using /products/fees/invocations/{invocation_id} endpoint. Once the invocation is completed, the Response Collection is populated with these search results. If you would rather receive a callback once the invocation is completed instead of polling it, you can set `callback_url` parameter in the request body. #### Request Collection Description ##### Mortgage & Deed Recording Taxes & Fees Each State requests specific information to calculate recording fees & taxes. Based on this information expected fees may increase or decrease. The set of questions asked by states change according to the loan purpose (purchase, refinancing or a modification). ###### Purchase, Refinancing, Modification Purposes Following questions are answered for all loan purpose types: | Impacting States | Question | Provided In | Default | | --- | --- | --- | --- | | AL, FL, GA, NY, OK | Is Lender a Credit Union? | `organizations[@type=lender].has_credit_union_indicator.has_value` | `false` | | CA, HI, IL, MD, VT | Will Buyer stay in the newly purchased House? | `declarations[0].has_intent_to_occupy_indicator.has_value` | `false` | | N/A | DC, ME, TN | Fair Market Value | `property_valuations[0].has_property_valuation_amount.has_value` | | DC, DE, MA, MD | Is this Buyer's first home purchase? | `declarations[0].has_borrower_first_time_home_buyer_indicator.has_value` | `false` | | DC, NY | Property Project Type | `properties[@type=subject_property].has_project_type.has_value` | N/A | | FL, KS, LA, NY | Number of Units in Property | `properties[@type=subject_property].has_number_of_units_type.has_value` | N/A | | IL | Age / Birth Date of Borrower | `people[@type=borrower].has_birth_date.has_value` | N/A | | CT, KY | Is the document being recorded a MERS document | `loans[0].has_mers_mortgage_identification_number.has_value` | N/A | | PA | Are the seller/developer and the builder affiliated? | `declarations[0].has_seller_or_developer_affiliated_with_builder_indicator.has_value` | `false` | | NJ | Is the borrower senior citizen, blind or disabled person? | `declarations[0].current_owner_is_senior_citizen_blind_or_disabled_person_indicator.has_value` | | | N/A | CA, MI, NJ, TN | Is this a taxable Quit Claim Deed? | `documents[@type=conveyance_deed_quit_claim_deed]` should exist | | MD | Is the Deed of Trust being recorded an Indemnity Deed of Trust? | `documents[@type=indemnity_deed_of_trust]` should exist | N/A | | CA, CT, DC, DE, IL, MD, NY | Property Usage Type | `properties[@type=subject_property].has_land_use_type.has_value` | N/A | | DC, ME, NJ, TN, VA | Sales Price | `sales_contracts[@type=subject_property].has_sales_contract_amount.has_value` | N/A | | MD | Loan Closing Date | `loans[0].has_loan_closing_date.has_value` | N/A | | CA, DE, MD | Is the property occupied by the owner? | `properties[@type=subject_property].has_property_current_occupancy_type.has_value` | N/A | | AL, CA, DC, LA, MD | Loan Purpose Type | `loans[@id={current_loan_id}].with_loan_terms,loan_terms[0].has_loan_purpose_type.has_value` | N/A | | NY | Does borrower owe liability with heloc type | First add a liability with 'heloc' type: `liabilities[has_liability_type=heloc]` then connect it to your borrower object by adding liability id to following field: `people[@type=borrower].owes_liability` | N/A | | CA, NY | Parcel count related to property | First add parcel identifications to following container `parcel_identifications` then connect the parcels to your legal descriptions by adding their ids to following field: `legal_descriptions[0].with_parcel_identification` | N/A | | FL | Land description count | First add land descriptions to the following containers identifications to following container `unplatted_lands` `platted_lands` then reference them by adding their ids into the following field of related parsed_legal_descriptions `parsed_legal_descriptions[*].with_unplatted_land` `parsed_legal_descriptions[0].platted_land` | N/A | | AL | Is the time to pay being extended? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_al_modification_time_to_pay_extended_indicator.has_value` | N/A | | AL | Is the amount of the loan increasing from the original amount? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_al_modification_loan_amount_increasing_from_original_indicator.has_value` | N/A | | CA | Is the recording exempt from the additional Real Estate Fraud Prosecution Trust Fund Fee pursuant to Cal Govt. Code § 27388? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ca_all_recording_exempt_from_additional_real_estate_fraud_prosecution_trust_fund_fee_indicator.has_value` | N/A | | CA | Is this a taxable Quit Claim Deed? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ca_deed_taxable_quit_claim_deed_indicator.has_value` | N/A | | CA | Is this document a Multi-Caption document? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ca_release_multicaption_document_indicator.has_value` | N/A | | CA | How many captions or titles on this document? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ca_release_captions_number.has_value` | N/A | | FL | Does the new money Intangible Tax exemption for mortgage modifications and refinances apply to this transaction? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_fl_modification_exempt_from_intangible_tax_indicator.has_value` | N/A | | FL | What is the amount of the taxable new money associated with this transaction? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_fl_modification_taxable_new_money_amount.has_value` | N/A | | GA | Is the debt to be refinanced with the original lender and the original borrower (must be all the original borrowers if more than one)? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ga_modification_lender_and_borrower_unchanged_indicator.has_value` | N/A | | IL | Are the documents being recorded not subject to the $5.00 mail handling fee? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_il_all_recorded_documents_exempt_from_mail_handling_fee_indicator.has_value` | N/A | | MA | Will a Municipal Lien Certificate be recorded as part of this transaction? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ma_deed_municipal_lien_certificate_being_recorded_indicator.has_value` | N/A | | MD | Is this a purchase-money mortgage (associated with a purchase) being recorded at the same time with a deed? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_deed_mortgage_and_deed_recorded_at_same_time_indicator.has_value` | N/A | | MD | Is the property a non-principal residence and is the borrower the same or has the borrower assumed this debt from the previous mortgagor? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_md_modification_lender_assumed_previous_debt_indicator.has_value` | N/A | | MD | On this refinance, has the original purchase money mortgage been on record more than 12 months?? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_md_refinance_original_purchase_money_mortgage_older_than_12_months_indicator.has_value` | N/A | | MN | Is there a well certificate being recorded with this document? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_mn_deed_well_certificate_being_recorded_indicator.has_value` | N/A | | NY | Number of references to consolidations in document? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_fee_ny_modification_number_of_colsolidation_references.has_value` | N/A | | NY | Number of references to assignments in document? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ny_modification_references_to_assignment_number.has_value` | N/A | | NY | What is the Percentage of this property that is residential real property? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ny_deed_residential_real_property_ratio.has_value` | N/A | | NY | Is this document a CEMA? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ny_modification_cema_indicator.has_value` | N/A | | NY | Has the mortgagor recorded any other mortgages against this property in the past 12 months, which had values of less than $500,000 but, when taken together with this mortgage, cumulatively total $500,000 or more? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_ny_refinance_previous_mortgage_in_past_12_months_amount.has_value` | N/A | | PA | Does this transaction involve an executory construction contract which is effective prior to, or contemporaneously with, the transfer of the title to the real estate? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_pa_deed_executory_construction_contract_prior_to_or_during_title_transfer_indicator.has_value` | N/A | | VA | Is the amount of the existing debt certified? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_va_modification_existing_debt_certified_indicator.has_value` | N/A | | WA | Is the second title on a multiple instrument an Assignment of Deed of Trust or a Trustee Change (appointment, substitution, or resignation)? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_wa_release_second_title_type.has_value` | N/A | | WA | How many captions or titles on this document? | `loans[@id={current_loan_id}].with_closing_cost_fee_information,closing_cost_fee_information[0].has_closing_cost_fee_wa_release_captions_or_titles_number.has_value` | N/A | ###### Refinancing, Modification Purposes In case of a refinancing, we also need to collect the information of the old loan. We do not support getting and processing old loan information yet. We will update here when this operation is available for the clients. ###### Modification Purpose In case of a loan modification, Fees API expects there to be a `modifications` objects in the request collection. If there's no modifications object, this refinancing operation will not be regarded as a modification, and different fees and taxes may apply. When the loan purpose is loan modification, following questions are answered: | Question | Provided In | Default | Impacting States | | --- | --- | --- | --- | | Is this a modification of an existing mortgage/deed of trust | `modifications[]` | N/A | AL, FL, TN | | Is the time to pay being extended? | `modification_aspects.[].has_loan_modification_type.has_value ` | N/A | AL | | Is the amount of the loan changing from the original amount? | `modification_aspects.[].has_loan_modification_type.has_value == principal_amount` | N/A | AL, MN, OK | ##### Title Insurance Fees Fees product returns title insurance fees including followings: - Lender and Owner Premium Calculations - Itemized Settlement Fees - Endorsements ###### Title Insurance Fees Providers For title fees Ernst works with three providers. You can choose the provider that is going to be used for the title fees. You can send your preference of the providers in the options field while invoking the product as following: ``` { "vendor_name": "ernst", "request_data": { }, "options": { "title_provider_orderings": ["first_american", "stewart", "fidelity"] } } ``` For the configuration above, Fees will first try to get title fees using First American. If Fees fails, Fees will use Stewart next. If Fees fails again, it finally will try to get title providers using Fidelity. You can also set default title fees configurations for specific states, counties and cities. Check Set Ernst Credentials ###### Endorsement Fees By default, Fees return only default endorsement fees. Based on the property & loan parameters, the set of returned endorsements fees are updated. | Endorsement Type | Provided In | | --- | --- | | Adjustable Rate endorsement | `loan_terms[0].has_loan_amortization_type.has_value == "adjustable_rate"` | | Condominium endorsement | `properties[@type=subject_property].has_project_type.has_value == "condominium"` | | Balloon Mortgage endorsement | `loan_terms[0].has_balloon_indicator.has_value == true` | | Manufactured Home endorsement | `properties[@type=subject_property].has_construction_method_type.has_value == "manufactured"` | | Planned Unit Development (PUD) endorsement | `properties[@type=subject_property].has_planned_unit_development_pud_indicator.has_value == true` | ##### Inspection Fees If you'd like to calculate inspection fees along with recording & title insurance fees, you'll need to provide `inspections` array in the request collection. ##### Request Flow Invocation with Collection IDRequest ExampleRecording Fees ExampleTitle Insurance And Recording Fees ExampleInspection And Recording Fees Example application/json Copy ``` { "vendor_name": "ernst", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN" } ``` application/json Copy ``` { "vendor_name": "ernst", "request_data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] } } ``` application/json Copy ``` { "vendor_name": "ernst", "request_data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_current_occupancy_type": { "has_value": "owner_occupied" }, "has_project_type": { "has_value": "condominium" }, "has_number_of_units_type": { "has_value": "one" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 500000 } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5A" ], "with_borrower": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "funded_by": [ "01FMM41S2RE99T8XGQJCMTE8E" ], "has_loan_closing_date": { "has_value": "2021-12-25" }, "has_mers_mortgage_identification_number": { "has_value": "id123" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5A", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true }, "has_loan_maturity_due_date": { "has_value": "2021-10-22" } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 4 }, "has_page_number_last": { "has_value": 5 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 3 } } ], "organizations": [ { "@id": "01FMM41S2RE99T8XGQJCMTE8E", "@type": "lender", "has_organization_name": { "has_value": "lender_organization" }, "has_credit_union_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PJTJBJZ777RCKUHDF5J", "@type": "declaration", "has_intent_to_occupy_indicator": { "has_value": true }, "has_borrower_first_time_home_buyer_indicator": { "has_value": true } } ], "people": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "borrower", "has_birth_date": { "has_value": "1950-10-10" } } ] } } ``` application/json Copy ``` { "vendor_name": "ernst", "request_data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } } ``` application/json Copy ``` { "vendor_name": "ernst", "request_data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ] } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_loan_amortization_type": { "has_value": "adjustable_rate" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } } ``` ##### Response 201400403404500 application/json Copy Successfully started flow invocation. ``` { "product_flow_name": "ErnstFees", "metadata": {}, "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "STARTED", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Response `201``application/json` 7 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id` | `string` | Invocation ID. | | `invocation_status` | `string` | The status of the invocation.`STARTED` | | `transaction_id` | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name.`ErnstFees` | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/fees/invocations/{invocation_id}` #### Retrieve Invocation Status `RetrieveProductFlowInvocationStatus` Retrieve status of a Product Flow Invocation Retrieves the status of running Product flow invocation. ##### Response 200400403404500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "response_collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "metadata": {}, "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "RUNNING", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "product_flow_name": "ErnstFees", "request_collection": { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] } }, "response_collection": { "metadata": { "created_at": "2021-09-14T03:36:45.193268-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "data": { "fees": [ { "@id": "01FNTJW9GGM6GHQSVYN73NX630", "@type": "fee", "has_fee_type": { "has_value": "recording_fee_for_deed" }, "with_fee_payment": [ "01FNTJWAE246AVTJYDXTEQK7SA" ] }, { "@id": "01FNTJW9GSNCSF7TGQ3JAQTCE8", "@type": "fee", "has_fee_type": { "has_value": "recording_fee_for_mortgage" }, "with_fee_payment": [ "01FNTJWAE2W17RB50Y00R4EWH3" ] }, { "@id": "01FNTJW9H20TWMS42FGB7HT4RR", "@type": "fee", "has_fee_type": { "has_value": "tax_stamp_for_state_mortgage" }, "paid_to": [ "01FNTJWAE5527FEKVY4M1398EV" ], "with_fee_payment": [ "01FNTJWAE2TAZGAVXR2E3KTPM6", "01FNTJWAE2HEEGCMB5PW56T9PZ" ] }, { "@id": "01FNTJW9H27FS1YNC6QCMFY4A5", "@type": "fee", "has_fee_type": { "has_value": "tax_stamp_for_state_deed" }, "paid_to": [ "01FNTJWAE5527FEKVY4M1398EV" ], "with_fee_payment": [ "01FNTJWAE33DFB3WWQHW6W20G3" ] }, { "@id": "01FNTJW9H2JWWRZHG05NEDTWPM", "@type": "fee", "has_fee_type": { "has_value": "tax_stamp_for_city_mortgage" }, "paid_to": [ "01FNTJWAE58VZ8ZXCSZ88ZDV4P" ], "with_fee_payment": [ "01FNTJWAE38989RS7JM88AQSWE" ] } ], "fee_payments": [ { "@id": "01FNTJWAE246AVTJYDXTEQK7SA", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 405 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } }, { "@id": "01FNTJWAE2W17RB50Y00R4EWH3", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 460 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } }, { "@id": "01FNTJWAE2TAZGAVXR2E3KTPM6", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 6400 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } }, { "@id": "01FNTJWAE2HEEGCMB5PW56T9PZ", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 2000 }, "has_fee_payment_responsible_party_type": { "has_value": "lender" } }, { "@id": "01FNTJWAE33DFB3WWQHW6W20G3", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 4400 }, "has_fee_payment_responsible_party_type": { "has_value": "seller" } }, { "@id": "01FNTJWAE38989RS7JM88AQSWE", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 19000 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } } ], "organizations": [ { "@id": "01FNTJWAE5527FEKVY4M1398EV", "@type": "organization", "has_organization_name": { "has_value": "New York State" } }, { "@id": "01FNTJWAE58VZ8ZXCSZ88ZDV4P", "@type": "organization", "has_organization_name": { "has_value": "Riverhead City" } } ] } } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Product flow invocation identifier | ##### Response `200``application/json` 9 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_status`required | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `request_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `response_collection_id` | `string` | Response Collection ID. | | `response_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | — | | `fees`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `with_fee_payment`required | `string[]` | — | | `paid_to` | `string[]` | — | | `has_fee_type`required | `object` | — | | `fee_payments`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_fee_estimated_payment_amount`required | `object` | — | | `has_fee_payment_responsible_party_type`required | `object` | — | | `organizations`required | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_organization_name` | `object` | — | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `callback_url` | `string` | URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished. | | `widget_url` | `string (uri)` | URL of the widget. | | `metadata` | `object` | Response Collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/fees/request-schema` #### Retrieve Request Schema `retrieveRequestSchema` 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. ##### Response 200 Schema200 Schema with Examples400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "required": [ "properties", "addresses", "sales_contracts", "loans", "loan_terms", "documents" ], "properties": { "properties": { "type": "array", "description": "Add the Property related with the Loan in this container", "items": { "type": "object", "required": [ "@id", "@type", "with_address", "with_sales_contract" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "subject_property" ] }, "with_address": { "type": "array", "items": { "type": "string" } }, "with_sales_contract": { "type": "array", "items": { "type": "string" } }, "with_value": { "type": "array", "items": { "type": "string" } }, "with_inspection": { "type": "array", "items": { "type": "string" } }, "with_property_title": { "type": "array", "items": { "type": "string" } }, "with_legal_description": { "type": "array", "items": { "type": "string" } }, "has_property_structure_built_year": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_gross_living_area_square_feet_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_planned_unit_development_pud_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_project_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "common_interest_apartment", "condominium", "cooperative", "other" ] } } }, "has_number_of_units_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "four", "one", "three", "two", "two_to_four" ] } } }, "has_property_current_occupancy_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "abandoned", "adverse_occupied", "occupied_by_unknown", "owner_occupied", "partially_vacant", "tenant_occupied", "unknown", "vacant" ] } } }, "has_construction_method_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "manufactured", "mobile_home", "modular", "on_frame_modular", "other", "site_built" ] } } }, "has_land_use_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "manufactured", "mobile_home", "modular", "on_frame_modular", "other", "site_built" ] } } } } } }, "addresses": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_state_code", "has_county_name", "has_city_name", "has_postal_code" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "sales_contracts": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_sales_contract_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "sales_contract" ] }, "has_sales_contract_amount": { "type": "object", "description": "Deed Taxes & Fees are calculated according to this parameter", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "loans": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_loan_terms" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "loan" ] }, "with_loan_terms": { "type": "array", "items": { "type": "string" } }, "with_borrower": { "type": "array", "items": { "type": "string" } }, "with_modification_information": { "type": "array", "items": { "type": "string" } }, "with_closing_cost_fee_information": { "type": "array", "items": { "type": "string" } }, "funded_by": { "type": "array", "items": { "type": "string" } }, "has_mers_mortgage_identification_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_loan_closing_date": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_current_unpaid_principal_balance_upb_amount": { "type": "object", "description": "Old loans unpaid principal balance", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "loan_terms": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_note_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "loan_term" ] }, "has_note_amount": { "type": "object", "description": "Mortgage Taxes & Fees are calculated according to this parameter", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_loan_amortization_type": { "type": "object", "description": "Title Insurance: When provided endorsements are updated accordingly", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "adjustable_rate", "fixed_rate", "home_equity_line_of_credit", "payment_option_adjustable_rate" ] } } }, "has_balloon_indicator": { "type": "object", "description": "Title Insurance: When provided an additional endorsement for Balloon Mortgage is returned", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_loan_purpose_type": { "required": [ "has_value" ], "type": "object", "properties": { "has_value": { "type": "string", "enum": [ "other", "purchase", "refinance" ] } } }, "has_loan_maturity_due_date": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "documents": { "type": "array", "description": "Documents: Mortgage and Deed recording fees are calculated based on these documents page count.", "items": { "type": "object", "required": [ "@id", "@type", "has_page_number_first", "has_page_number_last" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "conveyance_deed", "conveyance_deed_bargain_and_sale_deed", "conveyance_deed_quit_claim_deed", "conveyance_deed_warranty_deed", "note" ] }, "has_page_number_first": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_page_number_last": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "people": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_birth_date" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "borrower" ] }, "owes_liability": { "type": "array", "items": { "type": "string" } }, "has_birth_date": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "inspections": { "type": "array", "description": "Inspections: When provided inspection fees are returned accordingly.", "items": { "type": "object", "required": [ "@id", "@type", "has_property_inspection_purpose_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "inspection" ] }, "has_property_inspection_purpose_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "home_inspection", "pest" ] } } } } } }, "organizations": { "type": "array", "description": "Includes organizations such as lenders.", "items": { "type": "object", "required": [ "@id", "@type", "has_organization_name" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "lender" ] }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_credit_union_indicator": { "type": "object", "required": [ "has_value" ], "description": "Indicates whether this organization (only applies to lenders) is a Federal or state-accredited credit union or not.", "properties": { "has_value": { "type": "boolean", "default": false } } } } } }, "declarations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "declaration" ] }, "has_intent_to_occupy_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean", "default": false } } }, "has_borrower_first_time_home_buyer_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean", "default": false } } }, "current_owner_is_senior_citizen_blind_or_disabled_person_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean", "default": false } } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_property_valuation_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "property_valuation" ] }, "has_property_valuation_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "modification_information": { "type": "array", "description": "Connects Loan object with Modification object", "items": { "type": "object", "required": [ "@id", "@type", "with_modification" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "modification_information" ] }, "with_modification": { "type": "array", "items": { "type": "string" } } } } }, "modifications": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_modification_aspect" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "modification_information" ] }, "with_modification_aspect": { "type": "array", "items": { "type": "string" } } } } }, "modification_aspects": { "type": "array", "description": "Includes information about what is being changed in a loan", "items": { "type": "object", "required": [ "@id", "@type", "has_loan_modification_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "modification_aspect" ] }, "has_loan_modification_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "amortization_method", "interest_rate", "maturity_date", "other", "payment_amount", "payment_frequency", "principal_amount" ] } } } } } }, "liabilities": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_liability_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "liability" ] }, "has_liability_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "heloc" ] } } } } } }, "property_titles": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "property_title" ] } } } }, "legal_descriptions": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_parsed_legal_description", "with_parcel_identification" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "legal_description" ] }, "with_parsed_legal_description": { "type": "array", "items": { "type": "string" } }, "with_parcel_identification": { "type": "array", "items": { "type": "string" } } } } }, "parcel_identifications": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "platted_land" ] } } } }, "parsed_legal_descriptions": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_platted_land", "with_unplatted_land" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "parsed_legal_description" ] }, "with_platted_land": { "type": "array", "items": { "type": "string" } }, "with_unplatted_land": { "type": "array", "items": { "type": "string" } } } } }, "platted_lands": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "platted_land" ] } } } }, "unplatted_lands": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "unplatted_land" ] } } } }, "closing_cost_fee_information": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "closing_cost_fee_information" ] }, "has_closing_cost_fee_al_modification_time_to_pay_extended_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_al_modification_loan_amount_increasing_from_original_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_all_recording_exempt_from_additional_real_estate_fraud_prosecution_trust_fund_fee_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_deed_taxable_quit_claim_deed_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_release_multicaption_document_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_release_captions_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_closing_cost_fee_ca_release_any_document_has_assignment_of_mortgage_or_rent_as_second_title_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_deed_mortgage_and_deed_recorded_at_same_time_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_fl_modification_exempt_from_intangible_tax_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ga_modification_lender_and_borrower_unchanged_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_il_all_recorded_documents_exempt_from_mail_handling_fee_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ma_deed_municipal_lien_certificate_being_recorded_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_md_modification_lender_assumed_previous_debt_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_md_refinance_original_purchase_money_mortgage_older_than_12_months_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_fee_ny_modification_number_of_colsolidation_references": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_closing_cost_fee_ny_modification_references_to_assignment_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_closing_cost_fee_ny_modification_cema_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ny_deed_residential_real_property_ratio": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_closing_cost_fee_ny_refinance_previous_mortgage_in_past_12_months_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_closing_cost_fee_pa_deed_executory_construction_contract_prior_to_or_during_title_transfer_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_va_modification_existing_debt_certified_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_wa_release_second_title_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_wa_release_captions_or_titles_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } } }, "description": "The data that is needed for invocation. It should follow the request schema" } } ``` application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "required": [ "properties", "addresses", "sales_contracts", "loans", "loan_terms", "documents" ], "properties": { "properties": { "type": "array", "description": "Add the Property related with the Loan in this container", "items": { "type": "object", "required": [ "@id", "@type", "with_address", "with_sales_contract" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "subject_property" ] }, "with_address": { "type": "array", "items": { "type": "string" } }, "with_sales_contract": { "type": "array", "items": { "type": "string" } }, "with_value": { "type": "array", "items": { "type": "string" } }, "with_inspection": { "type": "array", "items": { "type": "string" } }, "with_property_title": { "type": "array", "items": { "type": "string" } }, "with_legal_description": { "type": "array", "items": { "type": "string" } }, "has_property_structure_built_year": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_gross_living_area_square_feet_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_planned_unit_development_pud_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_project_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "common_interest_apartment", "condominium", "cooperative", "other" ] } } }, "has_number_of_units_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "four", "one", "three", "two", "two_to_four" ] } } }, "has_property_current_occupancy_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "abandoned", "adverse_occupied", "occupied_by_unknown", "owner_occupied", "partially_vacant", "tenant_occupied", "unknown", "vacant" ] } } }, "has_construction_method_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "manufactured", "mobile_home", "modular", "on_frame_modular", "other", "site_built" ] } } }, "has_land_use_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "manufactured", "mobile_home", "modular", "on_frame_modular", "other", "site_built" ] } } } } } }, "addresses": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_state_code", "has_county_name", "has_city_name", "has_postal_code" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "sales_contracts": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_sales_contract_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "sales_contract" ] }, "has_sales_contract_amount": { "type": "object", "description": "Deed Taxes & Fees are calculated according to this parameter", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "loans": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_loan_terms" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "loan" ] }, "with_loan_terms": { "type": "array", "items": { "type": "string" } }, "with_borrower": { "type": "array", "items": { "type": "string" } }, "with_modification_information": { "type": "array", "items": { "type": "string" } }, "with_closing_cost_fee_information": { "type": "array", "items": { "type": "string" } }, "funded_by": { "type": "array", "items": { "type": "string" } }, "has_mers_mortgage_identification_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_loan_closing_date": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_current_unpaid_principal_balance_upb_amount": { "type": "object", "description": "Old loans unpaid principal balance", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "loan_terms": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_note_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "loan_term" ] }, "has_note_amount": { "type": "object", "description": "Mortgage Taxes & Fees are calculated according to this parameter", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_loan_amortization_type": { "type": "object", "description": "Title Insurance: When provided endorsements are updated accordingly", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "adjustable_rate", "fixed_rate", "home_equity_line_of_credit", "payment_option_adjustable_rate" ] } } }, "has_balloon_indicator": { "type": "object", "description": "Title Insurance: When provided an additional endorsement for Balloon Mortgage is returned", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_loan_purpose_type": { "required": [ "has_value" ], "type": "object", "properties": { "has_value": { "type": "string", "enum": [ "other", "purchase", "refinance" ] } } }, "has_loan_maturity_due_date": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "documents": { "type": "array", "description": "Documents: Mortgage and Deed recording fees are calculated based on these documents page count.", "items": { "type": "object", "required": [ "@id", "@type", "has_page_number_first", "has_page_number_last" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "conveyance_deed", "conveyance_deed_bargain_and_sale_deed", "conveyance_deed_quit_claim_deed", "conveyance_deed_warranty_deed", "note" ] }, "has_page_number_first": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_page_number_last": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "people": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_birth_date" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "borrower" ] }, "owes_liability": { "type": "array", "items": { "type": "string" } }, "has_birth_date": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "inspections": { "type": "array", "description": "Inspections: When provided inspection fees are returned accordingly.", "items": { "type": "object", "required": [ "@id", "@type", "has_property_inspection_purpose_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "inspection" ] }, "has_property_inspection_purpose_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "home_inspection", "pest" ] } } } } } }, "organizations": { "type": "array", "description": "Includes organizations such as lenders.", "items": { "type": "object", "required": [ "@id", "@type", "has_organization_name" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "lender" ] }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_credit_union_indicator": { "type": "object", "required": [ "has_value" ], "description": "Indicates whether this organization (only applies to lenders) is a Federal or state-accredited credit union or not.", "properties": { "has_value": { "type": "boolean", "default": false } } } } } }, "declarations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "declaration" ] }, "has_intent_to_occupy_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean", "default": false } } }, "has_borrower_first_time_home_buyer_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean", "default": false } } }, "current_owner_is_senior_citizen_blind_or_disabled_person_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean", "default": false } } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_property_valuation_amount" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "property_valuation" ] }, "has_property_valuation_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "modification_information": { "type": "array", "description": "Connects Loan object with Modification object", "items": { "type": "object", "required": [ "@id", "@type", "with_modification" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "modification_information" ] }, "with_modification": { "type": "array", "items": { "type": "string" } } } } }, "modifications": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_modification_aspect" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "modification_information" ] }, "with_modification_aspect": { "type": "array", "items": { "type": "string" } } } } }, "modification_aspects": { "type": "array", "description": "Includes information about what is being changed in a loan", "items": { "type": "object", "required": [ "@id", "@type", "has_loan_modification_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "modification_aspect" ] }, "has_loan_modification_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "amortization_method", "interest_rate", "maturity_date", "other", "payment_amount", "payment_frequency", "principal_amount" ] } } } } } }, "liabilities": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_liability_type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "liability" ] }, "has_liability_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "heloc" ] } } } } } }, "property_titles": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "property_title" ] } } } }, "legal_descriptions": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_parsed_legal_description", "with_parcel_identification" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "legal_description" ] }, "with_parsed_legal_description": { "type": "array", "items": { "type": "string" } }, "with_parcel_identification": { "type": "array", "items": { "type": "string" } } } } }, "parcel_identifications": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "platted_land" ] } } } }, "parsed_legal_descriptions": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_platted_land", "with_unplatted_land" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "parsed_legal_description" ] }, "with_platted_land": { "type": "array", "items": { "type": "string" } }, "with_unplatted_land": { "type": "array", "items": { "type": "string" } } } } }, "platted_lands": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "platted_land" ] } } } }, "unplatted_lands": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "unplatted_land" ] } } } }, "closing_cost_fee_information": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type" ], "properties": { "@id": { "type": "string" }, "@type": { "type": "string", "enum": [ "closing_cost_fee_information" ] }, "has_closing_cost_fee_al_modification_time_to_pay_extended_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_al_modification_loan_amount_increasing_from_original_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_all_recording_exempt_from_additional_real_estate_fraud_prosecution_trust_fund_fee_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_deed_taxable_quit_claim_deed_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_release_multicaption_document_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ca_release_captions_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_closing_cost_fee_ca_release_any_document_has_assignment_of_mortgage_or_rent_as_second_title_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_deed_mortgage_and_deed_recorded_at_same_time_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_fl_modification_exempt_from_intangible_tax_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ga_modification_lender_and_borrower_unchanged_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_il_all_recorded_documents_exempt_from_mail_handling_fee_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ma_deed_municipal_lien_certificate_being_recorded_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_md_modification_lender_assumed_previous_debt_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_md_refinance_original_purchase_money_mortgage_older_than_12_months_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_fee_ny_modification_number_of_colsolidation_references": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_closing_cost_fee_ny_modification_references_to_assignment_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_closing_cost_fee_ny_modification_cema_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_ny_deed_residential_real_property_ratio": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_closing_cost_fee_ny_refinance_previous_mortgage_in_past_12_months_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_closing_cost_fee_pa_deed_executory_construction_contract_prior_to_or_during_title_transfer_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_va_modification_existing_debt_certified_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_wa_release_second_title_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_closing_cost_fee_wa_release_captions_or_titles_number": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } } }, "description": "The data that is needed for invocation. It should follow the request schema" }, "examples": [ { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] }, { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_current_occupancy_type": { "has_value": "owner_occupied" }, "has_project_type": { "has_value": "condominium" }, "has_number_of_units_type": { "has_value": "one" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 500000 } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5A" ], "with_borrower": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "funded_by": [ "01FMM41S2RE99T8XGQJCMTE8E" ], "has_loan_closing_date": { "has_value": "2021-12-25" }, "has_mers_mortgage_identification_number": { "has_value": "id123" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5A", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true }, "has_loan_maturity_due_date": { "has_value": "2021-10-22" } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 4 }, "has_page_number_last": { "has_value": 5 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 3 } } ], "organizations": [ { "@id": "01FMM41S2RE99T8XGQJCMTE8E", "@type": "lender", "has_organization_name": { "has_value": "lender_organization" }, "has_credit_union_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PJTJBJZ777RCKUHDF5J", "@type": "declaration", "has_intent_to_occupy_indicator": { "has_value": true }, "has_borrower_first_time_home_buyer_indicator": { "has_value": true } } ], "people": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "borrower", "has_birth_date": { "has_value": "1950-10-10" } } ] }, { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] }, { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ] } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_loan_amortization_type": { "has_value": "adjustable_rate" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Request schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | Schema for the Request Collection | | `examples` | `object` | Each item in the dictionary corresponds to the name of the example and dictionary content is the sample response. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/fees/response-schema` #### Retrieve Response Schema `retrieveResponseSchema` Retrieve Response Schema returns the JSON schema for the response collection, created by an invocation. If you would like to retrieve examples along with the schema, you can provide `return_examples=True` query parameter. ##### Response 200 Schema200 Schema with Examples Response400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "additionalProperties": false, "required": [ "fees", "fee_payments", "organizations" ], "properties": { "fees": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_fee_payment", "has_fee_type" ], "additionalProperties": false, "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_fee_payment": { "type": "array", "items": { "type": "string" } }, "paid_to": { "type": "array", "items": { "type": "string" } }, "has_fee_type": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "string", "enum": [ "203k_consultant_fee", "203k_discount_on_repairs", "203k_inspection_fee", "203k_permits", "203k_supplemental_origination_fee", "203k_title_update", "application_fee", "appraisal_desk_review_fee", "appraisal_fee", "appraisal_field_review_fee", "appraisal_management_company_fee", "arm_conversion_fee", "asbestos_inspection_fee", "assignment_preparation_fee", "assumption_fee", "attorney_fee", "automated_underwriting_fee", "avm_fee", "bankruptcy_monitoring_fee", "bond_fee", "bond_review_fee", "certification_fee", "chosen_interest_rate_credit_or_charge_total", "commitment_fee", "condominium_association_dues", "condominium_association_special_assessment", "construction_handling_fee", "construction_inspection_fee", "cooperative_association_dues", "cooperative_association_special_assessment", "copy_or_fax_fee", "courier_fee", "credit_disability_insurance_premium", "credit_life_insurance_premium", "credit_property_insurance_premium", "credit_report_fee", "credit_unemployment_insurance_premium", "debt_cancellation_insurance_premium", "debt_suspension_insurance_premium", "deed_preparation_fee", "disaster_inspection_fee", "discount_on_repairs_fee", "document_preparation_fee", "documentary_stamp_fee", "down_payment_protection_fee", "dry_wall_inspection_fee", "electrical_inspection_fee", "electronic_document_delivery_fee", "environmental_inspection_fee", "escrow_holdback_fee", "escrow_service_fee", "escrow_waiver_fee", "filing_fee", "flood_certification", "foundation_inspection_fee", "heating_cooling_inspection_fee", "heloc_annual_fee", "heloc_over_limit_fee", "high_cost_mortgage_counseling_fee", "home_inspection_fee", "home_warranty_fee", "homeowners_association_dues", "homeowners_association_service_fee", "homeowners_association_special_assessment", "late_charge", "lead_inspection_fee", "lenders_attorney_fee", "loan_discount_points", "loan_level_price_adjustment", "loan_origination_fee", "loan_originator_compensation", "manual_underwriting_fee", "manufactured_housing_inspection_fee", "manufactured_housing_processing_fee", "mers_registration_fee", "modification_fee", "mold_inspection_fee", "mortgage_broker_fee", "mortgage_insurance_initial_premium", "mortgage_insurance_upfront_premium", "mortgage_surcharge_county_or_parish", "mortgage_surcharge_municipal", "mortgage_surcharge_state", "mortgage_tax_credit_service_fee", "multiple_loans_closing_fee", "municipal_lien_certificate_fee", "non_sufficient_funds_fee", "notary_fee", "other", "our_origination_charge_total", "partial_lien_release_fee", "payoff_request_fee", "pest_inspection_fee", "plumbing_inspection_fee", "power_of_attorney_preparation_fee", "power_of_attorney_recording_fee", "preclosing_verification_control_fee", "processing_fee", "program_guarantee_fee", "property_inspection_waiver_fee", "radon_inspection_fee", "rate_lock_fee", "real_estate_commission_buyers_broker", "real_estate_commission_sellers_broker", "reconveyance_fee", "reconveyance_tracking_fee", "recording_fee_for_assignment", "recording_fee_for_deed", "recording_fee_for_mortgage", "recording_fee_for_municipal_lien_certificate", "recording_fee_for_other_document", "recording_fee_for_release", "recording_fee_for_subordination", "recording_fee_total", "recording_service_fee", "redraw_fee", "reinspection_fee", "renovation_consultant_fee", "repairs_fee", "roof_inspection_fee", "septic_inspection_fee", "settlement_fee", "signing_agent_fee", "smoke_detector_inspection_fee", "state_title_insurance_fee", "structural_inspection_fee", "subordination_fee", "survey_fee", "tax_service_fee", "tax_stamp_for_city_deed", "tax_stamp_for_city_mortgage", "tax_stamp_for_county_deed", "tax_stamp_for_county_mortgage", "tax_stamp_for_state_deed", "tax_stamp_for_state_mortgage", "tax_status_research_fee", "temporary_buydown_administration_fee", "temporary_buydown_points", "title_abstract_fee", "title_borrower_closing_protection_letter_fee", "title_certification_fee", "title_closing_coordination_fee", "title_closing_fee", "title_closing_protection_letter_fee", "title_commitment_fee", "title_document_preparation_fee", "title_endorsement_fee", "title_examination_fee", "title_final_policy_short_form_fee", "title_insurance_binder_fee", "title_insurance_fee", "title_lenders_coverage_premium", "title_notary_fee", "title_owners_coverage_premium", "title_search_fee", "title_services_fee_total", "title_services_sales_tax", "title_sub_escrow_fee", "title_subordination_processing_fee", "title_underwriting_issue_resolution_fee", "transfer_tax_total", "underwriting_fee", "usda_rural_development_guarantee_fee", "va_funding_fee", "verification_of_assets_fee", "verification_of_employment_fee", "verification_of_income_fee", "verification_of_residency_status_fee", "verification_of_tax_return_fee", "verification_of_taxpayer_identification_fee", "water_testing_fee", "well_inspection_fee", "wire_transfer_fee" ] } } } } } }, "fee_payments": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_fee_estimated_payment_amount", "has_fee_payment_responsible_party_type" ], "additionalProperties": false, "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_fee_estimated_payment_amount": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "number" } } }, "has_fee_payment_responsible_party_type": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "string", "enum": [ "branch", "broker", "buyer", "lender", "other", "seller" ] } } } } } }, "organizations": { "type": "array", "required": [ "@id", "@type", "has_organization_name" ], "items": { "type": "object", "additionalProperties": false, "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "string" } } } } } } } } } ``` application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": { "type": "object", "additionalProperties": false, "required": [ "fees", "fee_payments", "organizations" ], "properties": { "fees": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "with_fee_payment", "has_fee_type" ], "additionalProperties": false, "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "with_fee_payment": { "type": "array", "items": { "type": "string" } }, "paid_to": { "type": "array", "items": { "type": "string" } }, "has_fee_type": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "string", "enum": [ "203k_consultant_fee", "203k_discount_on_repairs", "203k_inspection_fee", "203k_permits", "203k_supplemental_origination_fee", "203k_title_update", "application_fee", "appraisal_desk_review_fee", "appraisal_fee", "appraisal_field_review_fee", "appraisal_management_company_fee", "arm_conversion_fee", "asbestos_inspection_fee", "assignment_preparation_fee", "assumption_fee", "attorney_fee", "automated_underwriting_fee", "avm_fee", "bankruptcy_monitoring_fee", "bond_fee", "bond_review_fee", "certification_fee", "chosen_interest_rate_credit_or_charge_total", "commitment_fee", "condominium_association_dues", "condominium_association_special_assessment", "construction_handling_fee", "construction_inspection_fee", "cooperative_association_dues", "cooperative_association_special_assessment", "copy_or_fax_fee", "courier_fee", "credit_disability_insurance_premium", "credit_life_insurance_premium", "credit_property_insurance_premium", "credit_report_fee", "credit_unemployment_insurance_premium", "debt_cancellation_insurance_premium", "debt_suspension_insurance_premium", "deed_preparation_fee", "disaster_inspection_fee", "discount_on_repairs_fee", "document_preparation_fee", "documentary_stamp_fee", "down_payment_protection_fee", "dry_wall_inspection_fee", "electrical_inspection_fee", "electronic_document_delivery_fee", "environmental_inspection_fee", "escrow_holdback_fee", "escrow_service_fee", "escrow_waiver_fee", "filing_fee", "flood_certification", "foundation_inspection_fee", "heating_cooling_inspection_fee", "heloc_annual_fee", "heloc_over_limit_fee", "high_cost_mortgage_counseling_fee", "home_inspection_fee", "home_warranty_fee", "homeowners_association_dues", "homeowners_association_service_fee", "homeowners_association_special_assessment", "late_charge", "lead_inspection_fee", "lenders_attorney_fee", "loan_discount_points", "loan_level_price_adjustment", "loan_origination_fee", "loan_originator_compensation", "manual_underwriting_fee", "manufactured_housing_inspection_fee", "manufactured_housing_processing_fee", "mers_registration_fee", "modification_fee", "mold_inspection_fee", "mortgage_broker_fee", "mortgage_insurance_initial_premium", "mortgage_insurance_upfront_premium", "mortgage_surcharge_county_or_parish", "mortgage_surcharge_municipal", "mortgage_surcharge_state", "mortgage_tax_credit_service_fee", "multiple_loans_closing_fee", "municipal_lien_certificate_fee", "non_sufficient_funds_fee", "notary_fee", "other", "our_origination_charge_total", "partial_lien_release_fee", "payoff_request_fee", "pest_inspection_fee", "plumbing_inspection_fee", "power_of_attorney_preparation_fee", "power_of_attorney_recording_fee", "preclosing_verification_control_fee", "processing_fee", "program_guarantee_fee", "property_inspection_waiver_fee", "radon_inspection_fee", "rate_lock_fee", "real_estate_commission_buyers_broker", "real_estate_commission_sellers_broker", "reconveyance_fee", "reconveyance_tracking_fee", "recording_fee_for_assignment", "recording_fee_for_deed", "recording_fee_for_mortgage", "recording_fee_for_municipal_lien_certificate", "recording_fee_for_other_document", "recording_fee_for_release", "recording_fee_for_subordination", "recording_fee_total", "recording_service_fee", "redraw_fee", "reinspection_fee", "renovation_consultant_fee", "repairs_fee", "roof_inspection_fee", "septic_inspection_fee", "settlement_fee", "signing_agent_fee", "smoke_detector_inspection_fee", "state_title_insurance_fee", "structural_inspection_fee", "subordination_fee", "survey_fee", "tax_service_fee", "tax_stamp_for_city_deed", "tax_stamp_for_city_mortgage", "tax_stamp_for_county_deed", "tax_stamp_for_county_mortgage", "tax_stamp_for_state_deed", "tax_stamp_for_state_mortgage", "tax_status_research_fee", "temporary_buydown_administration_fee", "temporary_buydown_points", "title_abstract_fee", "title_borrower_closing_protection_letter_fee", "title_certification_fee", "title_closing_coordination_fee", "title_closing_fee", "title_closing_protection_letter_fee", "title_commitment_fee", "title_document_preparation_fee", "title_endorsement_fee", "title_examination_fee", "title_final_policy_short_form_fee", "title_insurance_binder_fee", "title_insurance_fee", "title_lenders_coverage_premium", "title_notary_fee", "title_owners_coverage_premium", "title_search_fee", "title_services_fee_total", "title_services_sales_tax", "title_sub_escrow_fee", "title_subordination_processing_fee", "title_underwriting_issue_resolution_fee", "transfer_tax_total", "underwriting_fee", "usda_rural_development_guarantee_fee", "va_funding_fee", "verification_of_assets_fee", "verification_of_employment_fee", "verification_of_income_fee", "verification_of_residency_status_fee", "verification_of_tax_return_fee", "verification_of_taxpayer_identification_fee", "water_testing_fee", "well_inspection_fee", "wire_transfer_fee" ] } } } } } }, "fee_payments": { "type": "array", "items": { "type": "object", "required": [ "@id", "@type", "has_fee_estimated_payment_amount", "has_fee_payment_responsible_party_type" ], "additionalProperties": false, "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_fee_estimated_payment_amount": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "number" } } }, "has_fee_payment_responsible_party_type": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "string", "enum": [ "branch", "broker", "buyer", "lender", "other", "seller" ] } } } } } }, "organizations": { "type": "array", "required": [ "@id", "@type", "has_organization_name" ], "items": { "type": "object", "additionalProperties": false, "properties": { "@id": { "type": "string" }, "@type": { "type": "string" }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "additionalProperties": false, "properties": { "has_value": { "type": "string" } } } } } } } }, "examples": [ { "fees": [ { "@id": "01FNTJW9GGM6GHQSVYN73NX630", "@type": "fee", "has_fee_type": { "has_value": "recording_fee_for_deed" }, "with_fee_payment": [ "01FNTJWAE246AVTJYDXTEQK7SA" ] }, { "@id": "01FNTJW9GSNCSF7TGQ3JAQTCE8", "@type": "fee", "has_fee_type": { "has_value": "recording_fee_for_mortgage" }, "with_fee_payment": [ "01FNTJWAE2W17RB50Y00R4EWH3" ] }, { "@id": "01FNTJW9H20TWMS42FGB7HT4RR", "@type": "fee", "has_fee_type": { "has_value": "tax_stamp_for_state_mortgage" }, "paid_to": [ "01FNTJWAE5527FEKVY4M1398EV" ], "with_fee_payment": [ "01FNTJWAE2TAZGAVXR2E3KTPM6", "01FNTJWAE2HEEGCMB5PW56T9PZ" ] }, { "@id": "01FNTJW9H27FS1YNC6QCMFY4A5", "@type": "fee", "has_fee_type": { "has_value": "tax_stamp_for_state_deed" }, "paid_to": [ "01FNTJWAE5527FEKVY4M1398EV" ], "with_fee_payment": [ "01FNTJWAE33DFB3WWQHW6W20G3" ] }, { "@id": "01FNTJW9H2JWWRZHG05NEDTWPM", "@type": "fee", "has_fee_type": { "has_value": "tax_stamp_for_city_mortgage" }, "paid_to": [ "01FNTJWAE58VZ8ZXCSZ88ZDV4P" ], "with_fee_payment": [ "01FNTJWAE38989RS7JM88AQSWE" ] } ], "fee_payments": [ { "@id": "01FNTJWAE246AVTJYDXTEQK7SA", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 405 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } }, { "@id": "01FNTJWAE2W17RB50Y00R4EWH3", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 460 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } }, { "@id": "01FNTJWAE2TAZGAVXR2E3KTPM6", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 6400 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } }, { "@id": "01FNTJWAE2HEEGCMB5PW56T9PZ", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 2000 }, "has_fee_payment_responsible_party_type": { "has_value": "lender" } }, { "@id": "01FNTJWAE33DFB3WWQHW6W20G3", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 4400 }, "has_fee_payment_responsible_party_type": { "has_value": "seller" } }, { "@id": "01FNTJWAE38989RS7JM88AQSWE", "@type": "fee_payment", "has_fee_estimated_payment_amount": { "has_value": 19000 }, "has_fee_payment_responsible_party_type": { "has_value": "buyer" } } ], "organizations": [ { "@id": "01FNTJWAE5527FEKVY4M1398EV", "@type": "organization", "has_organization_name": { "has_value": "New York State" } }, { "@id": "01FNTJWAE58VZ8ZXCSZ88ZDV4P", "@type": "organization", "has_organization_name": { "has_value": "Riverhead City" } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Response schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | JSON-Schema as a single object | | `examples` | `object` | A key-value pair for the examples. Keys are the example names, while values correspond to the example values for the response collections you can retrieve. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Platform `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /products/fees/invocations ##### Request Request ExampleRecording Fees ExampleTitle Insurance And Recording Fees ExampleInspection And Recording Fees Example application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] } } ``` application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_current_occupancy_type": { "has_value": "owner_occupied" }, "has_project_type": { "has_value": "condominium" }, "has_number_of_units_type": { "has_value": "one" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 500000 } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5A" ], "with_borrower": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "funded_by": [ "01FMM41S2RE99T8XGQJCMTE8E" ], "has_loan_closing_date": { "has_value": "2021-12-25" }, "has_mers_mortgage_identification_number": { "has_value": "id123" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5A", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true }, "has_loan_maturity_due_date": { "has_value": "2021-10-22" } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 4 }, "has_page_number_last": { "has_value": 5 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 3 } } ], "organizations": [ { "@id": "01FMM41S2RE99T8XGQJCMTE8E", "@type": "lender", "has_organization_name": { "has_value": "lender_organization" }, "has_credit_union_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PJTJBJZ777RCKUHDF5J", "@type": "declaration", "has_intent_to_occupy_indicator": { "has_value": true }, "has_borrower_first_time_home_buyer_indicator": { "has_value": true } } ], "people": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "borrower", "has_birth_date": { "has_value": "1950-10-10" } } ] } } ``` application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } } ``` application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ] } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_loan_amortization_type": { "has_value": "adjustable_rate" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] } } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collectionchr\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction\nID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data that is needed for invocation. It should follow the request schema | | `properties`required | `object[]` | Add the Property related with the Loan in this container | | `@id`required | `string` | — | | `@type`required | `string` | `subject_property` | | `with_address`required | `string[]` | — | | `with_sales_contract`required | `string[]` | — | | `with_value` | `string[]` | — | | `with_inspection` | `string[]` | — | | `with_property_title` | `string[]` | — | | `with_legal_description` | `string[]` | — | | `has_property_structure_built_year` | `object` | — | | `has_value`required | `integer` | — | | `has_gross_living_area_square_feet_number` | `object` | — | | `has_value`required | `number` | — | | `has_planned_unit_development_pud_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_project_type` | `object` | — | | `has_value`required | `string` | `common_interest_apartment``condominium``cooperative``other` | | `has_number_of_units_type` | `object` | — | | `has_value`required | `string` | `four``one``three``two``two_to_four` | | `has_property_current_occupancy_type` | `object` | — | | `has_value`required | `string` | `abandoned``adverse_occupied``occupied_by_unknown``owner_occupied``partially_vacant``tenant_occupied``unknown``vacant` | | `has_construction_method_type` | `object` | — | | `has_value`required | `string` | `manufactured``mobile_home``modular``on_frame_modular``other``site_built` | | `has_land_use_type` | `object` | — | | `has_value`required | `string` | `manufactured``mobile_home``modular``on_frame_modular``other``site_built` | | `addresses`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_county_name`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code`required | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `sales_contracts`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `sales_contract` | | `has_sales_contract_amount`required | `object` | Deed Taxes & Fees are calculated according to this parameter | | `has_value`required | `number` | — | | `loans`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `loan` | | `with_loan_terms`required | `string[]` | — | | `with_borrower` | `string[]` | — | | `with_modification_information` | `string[]` | — | | `with_closing_cost_fee_information` | `string[]` | — | | `funded_by` | `string[]` | — | | `has_mers_mortgage_identification_number` | `object` | — | | `has_value`required | `string` | — | | `has_loan_closing_date` | `object` | — | | `has_value`required | `string` | — | | `has_current_unpaid_principal_balance_upb_amount` | `object` | Old loans unpaid principal balance | | `has_value`required | `number` | — | | `loan_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `loan_term` | | `has_note_amount`required | `object` | Mortgage Taxes & Fees are calculated according to this parameter | | `has_value`required | `number` | — | | `has_loan_amortization_type` | `object` | Title Insurance: When provided endorsements are updated accordingly | | `has_value`required | `string` | `adjustable_rate``fixed_rate``home_equity_line_of_credit``payment_option_adjustable_rate` | | `has_balloon_indicator` | `object` | Title Insurance: When provided an additional endorsement for Balloon Mortgage is returned | | `has_value`required | `boolean` | — | | `has_loan_purpose_type` | `object` | — | | `has_value`required | `string` | `other``purchase``refinance` | | `has_loan_maturity_due_date` | `object` | — | | `has_value`required | `string` | — | | `documents`required | `object[]` | Documents: Mortgage and Deed recording fees are calculated based on these documents page count. | | `@id`required | `string` | — | | `@type`required | `string` | `conveyance_deed``conveyance_deed_bargain_and_sale_deed``conveyance_deed_quit_claim_deed``conveyance_deed_warranty_deed``note` | | `has_page_number_first`required | `object` | — | | `has_value`required | `integer` | — | | `has_page_number_last`required | `object` | — | | `has_value`required | `integer` | — | | `people` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `borrower` | | `owes_liability` | `string[]` | — | | `has_birth_date`required | `object` | — | | `has_value`required | `string` | — | | `inspections` | `object[]` | Inspections: When provided inspection fees are returned accordingly. | | `@id`required | `string` | — | | `@type`required | `string` | `inspection` | | `has_property_inspection_purpose_type`required | `object` | — | | `has_value`required | `string` | `home_inspection``pest` | | `organizations` | `object[]` | Includes organizations such as lenders. | | `@id`required | `string` | — | | `@type`required | `string` | `lender` | | `has_organization_name`required | `object` | — | | `has_value`required | `string` | — | | `has_credit_union_indicator` | `object` | Indicates whether this organization (only applies to lenders) is a Federal or state-accredited credit union or not. | | `has_value`required | `boolean` | — | | `declarations` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `declaration` | | `has_intent_to_occupy_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_borrower_first_time_home_buyer_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `current_owner_is_senior_citizen_blind_or_disabled_person_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `property_valuations` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `property_valuation` | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | | `modification_information` | `object[]` | Connects Loan object with Modification object | | `@id`required | `string` | — | | `@type`required | `string` | `modification_information` | | `with_modification`required | `string[]` | — | | `modifications` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `modification_information` | | `with_modification_aspect`required | `string[]` | — | | `modification_aspects` | `object[]` | Includes information about what is being changed in a loan | | `@id`required | `string` | — | | `@type`required | `string` | `modification_aspect` | | `has_loan_modification_type`required | `object` | — | | `has_value`required | `string` | `amortization_method``interest_rate``maturity_date``other``payment_amount``payment_frequency``principal_amount` | | `liabilities` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `liability` | | `has_liability_type`required | `object` | — | | `has_value`required | `string` | `heloc` | | `property_titles` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `property_title` | | `legal_descriptions` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `legal_description` | | `with_parsed_legal_description`required | `string[]` | — | | `with_parcel_identification`required | `string[]` | — | | `parcel_identifications` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `platted_land` | | `parsed_legal_descriptions` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `parsed_legal_description` | | `with_platted_land`required | `string[]` | — | | `with_unplatted_land`required | `string[]` | — | | `platted_lands` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `platted_land` | | `unplatted_lands` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `unplatted_land` | | `closing_cost_fee_information` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `closing_cost_fee_information` | | `has_closing_cost_fee_al_modification_time_to_pay_extended_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_al_modification_loan_amount_increasing_from_original_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_all_recording_exempt_from_additional_real_estate_fraud_prosecution_trust_fund_fee_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_deed_taxable_quit_claim_deed_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_release_multicaption_document_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_release_captions_number` | `object` | — | | `has_value`required | `integer` | — | | `has_closing_cost_fee_ca_release_any_document_has_assignment_of_mortgage_or_rent_as_second_title_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_deed_mortgage_and_deed_recorded_at_same_time_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_fl_modification_exempt_from_intangible_tax_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ga_modification_lender_and_borrower_unchanged_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_il_all_recorded_documents_exempt_from_mail_handling_fee_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ma_deed_municipal_lien_certificate_being_recorded_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_md_modification_lender_assumed_previous_debt_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_md_refinance_original_purchase_money_mortgage_older_than_12_months_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_fee_ny_modification_number_of_colsolidation_references` | `object` | — | | `has_value`required | `integer` | — | | `has_closing_cost_fee_ny_modification_references_to_assignment_number` | `object` | — | | `has_value`required | `integer` | — | | `has_closing_cost_fee_ny_modification_cema_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ny_deed_residential_real_property_ratio` | `object` | — | | `has_value`required | `number` | — | | `has_closing_cost_fee_ny_refinance_previous_mortgage_in_past_12_months_amount` | `object` | — | | `has_value`required | `number` | — | | `has_closing_cost_fee_pa_deed_executory_construction_contract_prior_to_or_during_title_transfer_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_va_modification_existing_debt_certified_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_wa_release_second_title_type` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_wa_release_captions_or_titles_number` | `object` | — | | `has_value`required | `integer` | — | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 403404 GetCollectionError404 GetCollectionsError500 application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 4 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | — | | `collection_id`required | `string` | — | | `metadata`required | `object` | — | | `created_at`required | `string` | — | | `validation`required | `boolean` | — | | `data`required | `object` | — | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` Retrieve Transaction Collections returns the content of a given `collection_id` associated with a specific `transaction_id`. ##### Response 200400403404500 application/json Copy Transaction collection retrieved successfully ``` { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": {} } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Transaction collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given `collection_id` associated with a `transaction_id`. ##### Request Request ExampleRecording Fees ExampleTitle Insurance And Recording Fees ExampleInspection And Recording Fees Example application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] } } ``` application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_current_occupancy_type": { "has_value": "owner_occupied" }, "has_project_type": { "has_value": "condominium" }, "has_number_of_units_type": { "has_value": "one" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 500000 } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5A" ], "with_borrower": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "funded_by": [ "01FMM41S2RE99T8XGQJCMTE8E" ], "has_loan_closing_date": { "has_value": "2021-12-25" }, "has_mers_mortgage_identification_number": { "has_value": "id123" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5A", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true }, "has_loan_maturity_due_date": { "has_value": "2021-10-22" } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 4 }, "has_page_number_last": { "has_value": 5 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 3 } } ], "organizations": [ { "@id": "01FMM41S2RE99T8XGQJCMTE8E", "@type": "lender", "has_organization_name": { "has_value": "lender_organization" }, "has_credit_union_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PJTJBJZ777RCKUHDF5J", "@type": "declaration", "has_intent_to_occupy_indicator": { "has_value": true }, "has_borrower_first_time_home_buyer_indicator": { "has_value": true } } ], "people": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "borrower", "has_birth_date": { "has_value": "1950-10-10" } } ] } } ``` application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } } ``` application/json Copy ``` { "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ] } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_loan_amortization_type": { "has_value": "adjustable_rate" } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 3 }, "has_page_number_last": { "has_value": 6 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 2 } } ] } } ``` ##### Response 200400 UpdateCollectionError400 text/html403404 UpdateCollectionError404 text/html500 application/json Copy Collection updated successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "properties": [ { "@id": "01FMM41S2RE99T8XGQJC2MTE8E", "@type": "subject_property", "with_address": [ "01FMM41S2R86Q33TC28H9RC197" ], "with_sales_contract": [ "01FDTQ5PJTJLYZ444RCH7TDF5J" ], "with_inspection": [ "01FMM41S2R86Q33TC28H9RC191", "01FMM41S2R86Q33TC28H9RC192" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ], "has_property_structure_built_year": { "has_value": 2020 }, "has_gross_living_area_square_feet_number": { "has_value": 120 }, "has_planned_unit_development_pud_indicator": { "has_value": true }, "has_project_type": { "has_value": "condominium" }, "has_construction_method_type": { "has_value": "manufactured" } } ], "addresses": [ { "@id": "01FMM41S2R86Q33TC28H9RC197", "@type": "residential_address", "has_county_name": { "has_value": "Suffolk" }, "has_state_code": { "has_value": "NY" }, "has_city_name": { "has_value": "Riverhead" }, "has_postal_code": { "has_value": "77069" }, "has_address_line_1_text": { "has_value": "5118 Westerham Pl" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "has_mers_mortgage_identification_number": { "has_value": "id123" }, "has_loan_closing_date": { "has_value": "2021-12-25" } } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_note_amount": { "has_value": 800000 }, "has_loan_amortization_type": { "has_value": "adjustable_rate" }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_balloon_indicator": { "has_value": true } } ], "sales_contracts": [ { "@id": "01FDTQ5PJTJLYZ444RCH7TDF5J", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1100000 } } ], "inspections": [ { "@id": "01FMM41S2R86Q33TC28H9RC191", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "home_inspection" } }, { "@id": "01FMM41S2R86Q33TC28H9RC192", "@type": "inspection", "has_property_inspection_purpose_type": { "has_value": "pest" } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 800000 } } ], "documents": [ { "@id": "01FMM22S2R86Q77TC28H9RC191", "@type": "conveyance_deed", "has_page_number_first": { "has_value": 14 }, "has_page_number_last": { "has_value": 16 } }, { "@id": "01FMM23S2R86Q22TC28K9RC191", "@type": "conveyance_deed_bargain_and_sale_deed", "has_page_number_first": { "has_value": 17 }, "has_page_number_last": { "has_value": 20 } }, { "@id": "01FMM24S2R86Q33TC28T9RC191", "@type": "conveyance_deed_quit_claim_deed", "has_page_number_first": { "has_value": 21 }, "has_page_number_last": { "has_value": 24 } }, { "@id": "01FMM25S2R86Q44TC28X9RC191", "@type": "conveyance_deed_warranty_deed", "has_page_number_first": { "has_value": 25 }, "has_page_number_last": { "has_value": 30 } }, { "@id": "01FMM26S2R86Q99TC28R9RC191", "@type": "note", "has_page_number_first": { "has_value": 1 }, "has_page_number_last": { "has_value": 13 } } ] } } ``` application/json Copy Error ``` { "description": "Error details.", "message": "Unable to update collection. Please check the collection\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data that is needed for invocation. It should follow the request schema | | `properties`required | `object[]` | Add the Property related with the Loan in this container | | `@id`required | `string` | — | | `@type`required | `string` | `subject_property` | | `with_address`required | `string[]` | — | | `with_sales_contract`required | `string[]` | — | | `with_value` | `string[]` | — | | `with_inspection` | `string[]` | — | | `with_property_title` | `string[]` | — | | `with_legal_description` | `string[]` | — | | `has_property_structure_built_year` | `object` | — | | `has_value`required | `integer` | — | | `has_gross_living_area_square_feet_number` | `object` | — | | `has_value`required | `number` | — | | `has_planned_unit_development_pud_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_project_type` | `object` | — | | `has_value`required | `string` | `common_interest_apartment``condominium``cooperative``other` | | `has_number_of_units_type` | `object` | — | | `has_value`required | `string` | `four``one``three``two``two_to_four` | | `has_property_current_occupancy_type` | `object` | — | | `has_value`required | `string` | `abandoned``adverse_occupied``occupied_by_unknown``owner_occupied``partially_vacant``tenant_occupied``unknown``vacant` | | `has_construction_method_type` | `object` | — | | `has_value`required | `string` | `manufactured``mobile_home``modular``on_frame_modular``other``site_built` | | `has_land_use_type` | `object` | — | | `has_value`required | `string` | `manufactured``mobile_home``modular``on_frame_modular``other``site_built` | | `addresses`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_county_name`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name`required | `object` | — | | `has_value`required | `string` | — | | `has_postal_code`required | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `sales_contracts`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `sales_contract` | | `has_sales_contract_amount`required | `object` | Deed Taxes & Fees are calculated according to this parameter | | `has_value`required | `number` | — | | `loans`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `loan` | | `with_loan_terms`required | `string[]` | — | | `with_borrower` | `string[]` | — | | `with_modification_information` | `string[]` | — | | `with_closing_cost_fee_information` | `string[]` | — | | `funded_by` | `string[]` | — | | `has_mers_mortgage_identification_number` | `object` | — | | `has_value`required | `string` | — | | `has_loan_closing_date` | `object` | — | | `has_value`required | `string` | — | | `has_current_unpaid_principal_balance_upb_amount` | `object` | Old loans unpaid principal balance | | `has_value`required | `number` | — | | `loan_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `loan_term` | | `has_note_amount`required | `object` | Mortgage Taxes & Fees are calculated according to this parameter | | `has_value`required | `number` | — | | `has_loan_amortization_type` | `object` | Title Insurance: When provided endorsements are updated accordingly | | `has_value`required | `string` | `adjustable_rate``fixed_rate``home_equity_line_of_credit``payment_option_adjustable_rate` | | `has_balloon_indicator` | `object` | Title Insurance: When provided an additional endorsement for Balloon Mortgage is returned | | `has_value`required | `boolean` | — | | `has_loan_purpose_type` | `object` | — | | `has_value`required | `string` | `other``purchase``refinance` | | `has_loan_maturity_due_date` | `object` | — | | `has_value`required | `string` | — | | `documents`required | `object[]` | Documents: Mortgage and Deed recording fees are calculated based on these documents page count. | | `@id`required | `string` | — | | `@type`required | `string` | `conveyance_deed``conveyance_deed_bargain_and_sale_deed``conveyance_deed_quit_claim_deed``conveyance_deed_warranty_deed``note` | | `has_page_number_first`required | `object` | — | | `has_value`required | `integer` | — | | `has_page_number_last`required | `object` | — | | `has_value`required | `integer` | — | | `people` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `borrower` | | `owes_liability` | `string[]` | — | | `has_birth_date`required | `object` | — | | `has_value`required | `string` | — | | `inspections` | `object[]` | Inspections: When provided inspection fees are returned accordingly. | | `@id`required | `string` | — | | `@type`required | `string` | `inspection` | | `has_property_inspection_purpose_type`required | `object` | — | | `has_value`required | `string` | `home_inspection``pest` | | `organizations` | `object[]` | Includes organizations such as lenders. | | `@id`required | `string` | — | | `@type`required | `string` | `lender` | | `has_organization_name`required | `object` | — | | `has_value`required | `string` | — | | `has_credit_union_indicator` | `object` | Indicates whether this organization (only applies to lenders) is a Federal or state-accredited credit union or not. | | `has_value`required | `boolean` | — | | `declarations` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `declaration` | | `has_intent_to_occupy_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_borrower_first_time_home_buyer_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `current_owner_is_senior_citizen_blind_or_disabled_person_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `property_valuations` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `property_valuation` | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | | `modification_information` | `object[]` | Connects Loan object with Modification object | | `@id`required | `string` | — | | `@type`required | `string` | `modification_information` | | `with_modification`required | `string[]` | — | | `modifications` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `modification_information` | | `with_modification_aspect`required | `string[]` | — | | `modification_aspects` | `object[]` | Includes information about what is being changed in a loan | | `@id`required | `string` | — | | `@type`required | `string` | `modification_aspect` | | `has_loan_modification_type`required | `object` | — | | `has_value`required | `string` | `amortization_method``interest_rate``maturity_date``other``payment_amount``payment_frequency``principal_amount` | | `liabilities` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `liability` | | `has_liability_type`required | `object` | — | | `has_value`required | `string` | `heloc` | | `property_titles` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `property_title` | | `legal_descriptions` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `legal_description` | | `with_parsed_legal_description`required | `string[]` | — | | `with_parcel_identification`required | `string[]` | — | | `parcel_identifications` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `platted_land` | | `parsed_legal_descriptions` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `parsed_legal_description` | | `with_platted_land`required | `string[]` | — | | `with_unplatted_land`required | `string[]` | — | | `platted_lands` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `platted_land` | | `unplatted_lands` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `unplatted_land` | | `closing_cost_fee_information` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | `closing_cost_fee_information` | | `has_closing_cost_fee_al_modification_time_to_pay_extended_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_al_modification_loan_amount_increasing_from_original_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_all_recording_exempt_from_additional_real_estate_fraud_prosecution_trust_fund_fee_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_deed_taxable_quit_claim_deed_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_release_multicaption_document_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ca_release_captions_number` | `object` | — | | `has_value`required | `integer` | — | | `has_closing_cost_fee_ca_release_any_document_has_assignment_of_mortgage_or_rent_as_second_title_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_deed_mortgage_and_deed_recorded_at_same_time_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_fl_modification_exempt_from_intangible_tax_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ga_modification_lender_and_borrower_unchanged_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_il_all_recorded_documents_exempt_from_mail_handling_fee_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ma_deed_municipal_lien_certificate_being_recorded_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_md_modification_lender_assumed_previous_debt_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_md_refinance_original_purchase_money_mortgage_older_than_12_months_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_fee_ny_modification_number_of_colsolidation_references` | `object` | — | | `has_value`required | `integer` | — | | `has_closing_cost_fee_ny_modification_references_to_assignment_number` | `object` | — | | `has_value`required | `integer` | — | | `has_closing_cost_fee_ny_modification_cema_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_ny_deed_residential_real_property_ratio` | `object` | — | | `has_value`required | `number` | — | | `has_closing_cost_fee_ny_refinance_previous_mortgage_in_past_12_months_amount` | `object` | — | | `has_value`required | `number` | — | | `has_closing_cost_fee_pa_deed_executory_construction_contract_prior_to_or_during_title_transfer_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_va_modification_existing_debt_certified_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_wa_release_second_title_type` | `object` | — | | `has_value`required | `boolean` | — | | `has_closing_cost_fee_wa_release_captions_or_titles_number` | `object` | — | | `has_value`required | `integer` | — | ##### Response `200``application/json` 4 fields Collection updated successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` ### Operations `POST` `/fees` #### Create Fees `post-fees` Create Fees creates views of fees and closing data costs for settlement, escrow, and other charges that emerge during the loan decisioning process . ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Fees Report request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Fees Report request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ## Errors `400``403``404``405``422``500` ## More in Contract - Previous product: Electronic - Next product: Insurance --- # Insurance # Insurance The mortgage-insurance premium model: the four premium structures and their effect on the payment and the closing costs. Four structures are modelled — borrower-paid monthly, borrower-paid single premium, split premium, and lender-paid. They differ in where the cost lands: in the monthly payment, in the cash due at closing, in both, or in the rate. A caller sends the loan and the selected structure and receives the premium schedule and the effect on the disclosed costs. Which carriers will insure the loan at all is the separate question answered by Insurance under Eligibility. ## How it works This slot is dual-listed against Eligibility on purpose. The eligibility question and the cost question have different callers — one runs during underwriting, the other during disclosure — and separating them keeps a disclosure computation from depending on a carrier round trip. ## Dual listing Insurance is filed under two categories. The other listing is Insurance under Eligibility , and the recorded specifications resolve there — its 10 operations render on that page. ## Providers - Wilqo ## More in Contract - Previous product: Fee - Next product: Lexicon --- # Lexicon # Lexicon The canonical mortgage ontology, published as a product: the class dictionary every other product's request and response is a subset of. A caller queries the model — classes, properties, relationships, enumerations — and validates a payload against it. The classes themselves are documented under Data; this product is the surface that serves and enforces them. Two validation modes exist. A syntactic shape constrains datatype, enumeration membership, pattern, length and range. A semantic shape carries conditional rules: if a borrower's marital status is married, the spouse's name becomes required. A record is valid only when it satisfies both. ## How it works The model is a graph rather than a relational schema, and it is flat: no class nests another. A relationship between two classes is itself a class, whose properties are the object properties joining them. That keeps every class independently addressable and lets a relationship carry its own attributes, which a foreign key cannot. Naming is governed by a written style guide rather than by convention. Property suffixes are load-bearing — an indicator is boolean, an identifier is an identifier, a type is an enumeration whose range is a named enumeration set — so a property's type is legible from its name before its definition is read. Definitions are required to be complete sentences that define the term, not expand the acronym. The stated reason on record is future use by a conversational system: a glossary stub transfers nothing to a model reading it. Identity is immutable. Every state of an entity is a new database-generated identifier, and a stable global identifier groups every state of the same real-world thing. Reading history is therefore a query rather than an audit table. The model has a deprecation pipeline: duplicate analysis, impact analysis across every consumer of a class, automatic upcasting of a caller's payload to the current model, and usage monitoring of classes on the way out. Several executed removals are recorded with their own runbooks. ## Operations The shape queries take a product API identifier, a schema type of request or response, a shape type of syntactic or semantic, and the model name — because a product's contract is itself a derived view of the model rather than a separate document. ### Document `POST` `/1003` #### Loan Application `generateURLADocument` Generate URLA(1003, Loan Application) Document. This endpoint allows user to generate URLA(1003, Loan Application) Document. The input is Staircase collection described below. The output is a download link to the generated document. ##### Request application/json Copy ``` { "data": { "people": [ { "@id": "01HHEEBDSDHQK6H2FB884BDY3F", "@type": "person", "birth_day": "15", "birth_month": "7", "birth_year": "1980", "full_name": "John Doe", "has_alias": "01HHEEBDS89MPT7HCP0MBVX9GC", "has_dependent": [ "01HHEEBDSBXFETBGCMY9KPRXXE", "01HHEEBDSCTQ2SCQ3WQ517CH87" ], "marital_status_type": "Married", "ssn": "123456789", "us_citizenship_status": "USCitizen" }, { "@id": "01HHEEBDS89MPT7HCP0MBVX9GC", "@type": "person", "full_name": "Johnny, JD" }, { "@id": "01HHEEBDSCTQ2SCQ3WQ517CH87", "@type": "person", "age": 8 }, { "@id": "01HHEEBDSBXFETBGCMY9KPRXXE", "@type": "person", "age": 10 } ], "residences": [ { "@id": "01HHEEBDS9QTEXDP9QVBB1MYFN", "@type": "residence", "has_address": "01HHEEBDS9D8ZH0NG7J8K20YVE7", "has_resident": "01HHEEBDSDHQK6H2FB884BDY3F", "residency_basis_type": "Rent", "residency_duration_years_count": 2, "residency_type": "Current", "has_expense": "01HKMHPJ6TSMZQDPNRAHZYV9VN" }, { "@id": "01HHEEBDS9D8ZH0NG7J8K20YVE5", "@type": "residence", "has_address": "01HHEEBDS87XJ4XXSHBRMMWWCY", "has_resident": "01HHEEBDSDHQK6H2FB884BDY3F", "residency_basis_type": "Own", "residency_duration_months_count": 6, "residency_duration_years_count": 3, "residency_type": "Prior" } ], "expenses": [ { "@id": "01HKMHPJ6TSMZQDPNRAHZYV9VN", "@type": "expense", "expense_monthly_payment_amount": 1000 } ], "addresses": [ { "@id": "01HHEEBDS9D8ZH0NG7J8K20YVE7", "@type": "address", "address_line_1": "123 Main St", "city_name": "Anytown", "country_name": "USA", "postal_code": "12345", "state_code": "AL", "unit_identifier": "Unit 101" }, { "@id": "01HHEEBDS87XJ4XXSHBRMMWWCY", "@type": "address", "address_line_1": "456 Old St", "city_name": "Oldtown", "country_name": "USA", "postal_code": "54321", "state_code": "AK", "unit_identifier": "Unit 202" }, { "@id": "01HHEEBDSBV3Q1J8YCKYNTYZ2T", "@type": "address", "address_line_1": "789 Postal St", "city_name": "Mailville", "country_name": "USA", "postal_code": "67890", "state_code": "AZ", "unit_identifier": "Box 303" }, { "@id": "01HHEEBDSBAYVZ7EKP7N5FPTK21", "@type": "address", "address_line_1": "100 Solar Way", "city_name": "Sunnyville", "country_name": "USA", "postal_code": "93001", "state_code": "CA", "unit_identifier": "Suite 500" }, { "@id": "01HHEEBDSAYEBGX1PSGNEDFN4Q", "@type": "address", "address_line_1": "20 Commerce Blvd", "city_name": "Businesstown", "country_name": "USA", "postal_code": "20202", "state_code": "AS", "unit_identifier": "Suite 2" }, { "@id": "01HKKY764AT0AD029K7W34EECB", "@type": "address", "address_line_1": "123 Main St", "city_name": "Anytown", "country_name": "US", "postal_code": "12345", "state_code": "CA", "unit_identifier": "Unit 5" }, { "@id": "01HKKZ88Y0563MGWSV945J406B", "@type": "address", "address_line_1": "456 Oak Street", "city_name": "Springfield", "country_name": "US", "postal_code": "65432", "state_code": "NY", "unit_identifier": "Apt 202" } ], "communications": [ { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P8", "@type": "communication", "has_mailing_address": "01HHEEBDSBV3Q1J8YCKYNTYZ2T", "contact_person": "01HHEEBDSDHQK6H2FB884BDY3F", "home_phone_number": "1234567890", "phone_number": "2345678901", "work_phone_number": "3456789012" }, { "@id": "01HHEEBDS82QCSZEDWFSAPGHRF", "@type": "communication", "phone_number": "555101111" }, { "@id": "01HHEEBDSBAYVZ7EKP7N5FPTK24", "@type": "communication", "phone_number": "555202222" } ], "employments": [ { "@id": "01HHEEBDSBRYRXXGXZ55JJMPVW", "@type": "employment", "associated_income": "01HHEEBDS9D8ZH0NG7J8K20YVE9", "employment_end_date": "2020-12-31", "employment_start_date": "2018-03-15", "employment_status_type": "Previous", "has_employee": "01HHEEBDSDHQK6H2FB884BDY3F", "has_employer": "01HHEEBDS98S79HQ6JESFG93JZ", "position_title": "Environmental Engineer", "self_employment_indicator": false }, { "@id": "01HHEEBDSBT17PNE759GJ25PGG", "@type": "employment", "associated_income": [ "01HHEEBDS9GK1DHGS07GXP06ZV6", "01HHEEBDSARWSDN7DN6RY72Y4X", "01HHEEBDS855MCXMMK2HRP5ESH", "01HHEEBDS9GK1DHGS07GXP06ZV4", "01HHEEBDS9GK1DHGS07GXP06ZV5", "01HHEEBDS9GK1DHGS07GXP06ZV7" ], "employment_start_date": "2010-01-10", "employment_status_type": "Current", "employment_time_in_line_of_work_years_count": 3, "has_employee": "01HHEEBDSDHQK6H2FB884BDY3F", "has_employer": "01HHEEBDSB27TBFYPCF2XQ8J11", "ownership_interest_type": "GreaterThanOrEqualTo25Percent", "position_title": "Manager", "self_employment_indicator": true, "special_borrower_employer_relationship_indicator": true, "time_in_line_of_work_months_count": 2 }, { "@id": "01HHEEBDSBH00GD7716WZ1AF98", "@type": "employment", "associated_income": [ "01HHEEBDSAZ357ZQKYTDE2S6Q5", "01HHEEBDSD1438AFBY9K2VCKZY1", "01HHEEBDS9GK1DHGS07GXP06ZV8", "01HHEEBDSB9EFK3PH3SWWJCGH9", "01HHEEBDSDMQ3RSY6K2Y9AHEMG", "01HHEEBDS9GK1DHGS07GXP06ZV9" ], "employment_start_date": "2015-06-15", "employment_status_type": "Current", "employment_time_in_line_of_work_years_count": 10, "has_employee": "01HHEEBDSDHQK6H2FB884BDY3F", "has_employer": "01HHEEBDSBVT47DCTAZ1T546WA", "position_title": "Senior Analyst", "self_employment_indicator": false, "special_borrower_employer_relationship_indicator": false, "time_in_line_of_work_months_count": 0 } ], "incomes": [ { "@id": "01HHEEBDS9D8ZH0NG7J8K20YVE9", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 6500, "income_type": "Base" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV3", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 450, "income_type": "DividendsInterest" }, { "@id": "01HHEEBDS9MDSGMCN8M6KE9G4M", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 800, "income_type": "CapitalGains" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV1", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 1200, "income_type": "Alimony" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV9", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 0, "income_type": "Other" }, { "@id": "01HHEEBDSAZ357ZQKYTDE2S6Q5", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 600, "income_type": "Overtime" }, { "@id": "01HHEEBDSDMQ3RSY6K2Y9AHEMG", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 0, "income_type": "MilitaryBasePay" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV4", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 300, "income_type": "Bonuses" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV8", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 300, "income_type": "Bonuses" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV5", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 0, "income_type": "Other" }, { "@id": "01HHEEBDSD1438AFBY9K2VCKZY1", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 100, "income_type": "Commissions" }, { "@id": "01HHEEBDS855MCXMMK2HRP5ESH", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 200, "income_type": "Commissions" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV7", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 4000, "income_type": "Base" }, { "@id": "01HHEEBDS9GK1DHGS07GXP06ZV6", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 500, "income_type": "Overtime" }, { "@id": "01HHEEBDSB9EFK3PH3SWWJCGH9", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 5000, "income_type": "Base" }, { "@id": "01HHEEBDSARWSDN7DN6RY72Y4X", "@type": "income", "income_recipient": "01HHEEBDSDHQK6H2FB884BDY3F", "income_amount": 0, "income_type": "MilitaryBasePay" } ], "companies": [ { "@id": "01HHEEBDS98S79HQ6JESFG93JZ", "@type": "company", "has_address": "01HHEEBDSBAYVZ7EKP7N5FPTK21", "name": "GreenTech Innovations" }, { "@id": "01HHEEBDSB27TBFYPCF2XQ8J11", "@type": "company", "has_address": "01HHEEBDS95T2CKY8KN0GK3EX4", "has_communication_method": "01HHEEBDS82QCSZEDWFSAPGHRF", "name": "Company One" }, { "@id": "01HHEEBDSBVT47DCTAZ1T546WA", "@type": "company", "has_address": "01HHEEBDSAYEBGX1PSGNEDFN4Q", "has_communication_method": "01HHEEBDSBAYVZ7EKP7N5FPTK24", "name": "Company Two" }, { "@id": "01HHEEBDS9V68J5NE6SQFWZXTA", "@type": "company", "name": "Credit Union C" }, { "@id": "01HHEEBDSBAYVZ7EKP7N5FPTK29", "@type": "company", "name": "Bank A" }, { "@id": "01HKKYNEXGQMZA6384RY4AF2DV", "@type": "company", "name": "ABC Lending" } ], "assets": [ { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P4", "@type": "asset", "asset_account_identifier": "998877665", "asset_cash_or_market_value_amount": 35000, "asset_type": "MutualFund", "held_by_financial_institution": "01HHEEBDSBAYVZ7EKP7N5FPTK29", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P3", "@type": "asset", "asset_account_identifier": "123456789", "asset_cash_or_market_value_amount": 5000, "asset_type": "CheckingAccount", "held_by_financial_institution": "01HHEEBDSBAYVZ7EKP7N5FPTK29", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P5", "@type": "asset", "asset_account_identifier": "987654321", "asset_cash_or_market_value_amount": 15000, "asset_type": "SavingsAccount", "held_by_financial_institution": "01HHEEBDS9V68J5NE6SQFWZXTA", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P7", "@type": "asset", "asset_account_identifier": "556677889", "asset_cash_or_market_value_amount": 45000, "asset_type": "Stock", "held_by_financial_institution": "01HHEEBDS9V68J5NE6SQFWZXTA", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P6", "@type": "asset", "asset_account_identifier": "112233445", "asset_cash_or_market_value_amount": 25000, "asset_type": "MoneyMarketFund", "held_by_financial_institution": "01HHEEBDS9V68J5NE6SQFWZXTA", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDSCSCMK10J7CK7ZAFM7", "@type": "asset", "asset_cash_or_market_value_amount": 100000, "asset_type": "PendingNetSaleProceedsFromRealEstateAssets", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P1", "@type": "asset", "asset_cash_or_market_value_amount": 5000, "asset_type": "ProceedsFromSaleOfNonRealEstateAsset", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDSD3APA7QJJRQGJTNDB", "@type": "asset", "asset_cash_or_market_value_amount": 15000, "asset_liquidity_indicator": false, "asset_type": "GiftOfPropertyEquity", "funds_source_type": "Employer", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" }, { "@id": "01HHEEBDSCN405T3MK0MPBW2K1", "@type": "asset", "asset_cash_or_market_value_amount": 10000, "asset_liquidity_indicator": true, "asset_type": "GiftOfCash", "funds_source_type": "Relative", "possessed_by": "01HHEEBDSDHQK6H2FB884BDY3F" } ], "liabilities": [ { "@id": "01HHEEBDS82E4FXB7XKB2EFN54", "@type": "liability", "has_liability_timeline": "01HHEEBDS84EHE26GE3JDCXYWG", "has_liability_holder": "01HHEEBDSDHQK6H2FB884BDY3F", "liability_account_identifier": "12340002", "liability_monthly_payment_amount": 300, "liability_payoff_status_indicator": true, "liability_type": "Installment", "owed_to": "01HHEEBDS9V68J5NE6SQFWZXTA" }, { "@id": "01HHEEBDS9RXSCP5F72MAN3AB75", "@type": "liability", "has_liability_timeline": "01HKKXH29GPH21N38PPCXEZ2HK", "has_liability_holder": "01HHEEBDSDHQK6H2FB884BDY3F", "liability_account_identifier": "12340001", "liability_monthly_payment_amount": 150, "liability_payoff_status_indicator": true, "liability_type": "Revolving", "owed_to": "01HHEEBDS9V68J5NE6SQFWZXTA" }, { "@id": "01HHEEBDS9RXSCP5F72MAN3AB79", "@type": "liability", "has_liability_timeline": "01HKKXH9604TFHK6CP8E8VXE5A", "has_liability_holder": "01HHEEBDSDHQK6H2FB884BDY3F", "liability_account_identifier": "12340003", "liability_monthly_payment_amount": 100, "liability_payoff_status_indicator": true, "liability_type": "Open30DayChargeAccount", "owed_to": "01HHEEBDS9V68J5NE6SQFWZXTA" } ], "liability_timelines": [ { "@id": "01HHEEBDS84EHE26GE3JDCXYWG", "@type": "liability_timeline", "liability_unpaid_balance_amount": 10000 }, { "@id": "01HKKXH29GPH21N38PPCXEZ2HK", "@type": "liability_timeline", "liability_unpaid_balance_amount": 8000 }, { "@id": "01HKKXH9604TFHK6CP8E8VXE5A", "@type": "liability_timeline", "liability_unpaid_balance_amount": 6000 } ], "settlements": [ { "@id": "01HKKYP4GK210SDCYCZZ8TT8N1", "@type": "settlement", "has_loan": "01HKKYMREK90A70C6KKSPCH6H1", "has_ownership": "01HKKYJYNCN5NFV5E62D538B6W", "has_company": "01HKKYNEXGQMZA6384RY4AF2DV" } ], "loans": [ { "@id": "01HKKYMREK90A70C6KKSPCH6H1", "@type": "loan", "monthly_payment": 1500, "has_loan_timeline": "01HKKYMDAYMK31Q67DHCYF1MAW", "mortgage_type": "Conventional" }, { "@id": "01HKKYVNHW67R39873M8AEN4MC", "@type": "loan", "base_loan_amount": 300000, "loan_purpose_type": "Purchase" } ], "loan_timelines": [ { "@id": "01HKKYMDAYMK31Q67DHCYF1MAW", "@type": "loan_timeline", "unpaid_balance_amount": 200000 } ], "ownerships": [ { "@id": "01HKKYJYNCN5NFV5E62D538B6W", "@type": "ownership", "owned_property": "01HKKYHSWWTDV943CM8BCE67JH", "owned_by": "01HHEEBDSDHQK6H2FB884BDY3F" } ], "properties": [ { "@id": "01HKKYHSWWTDV943CM8BCE67JH", "@type": "property", "has_address": "01HKKY764AT0AD029K7W34EECB", "property_estimated_value_amount": 500000, "property_current_usage_type": "PrimaryResidence", "owned_property_maintenance_expense_amount": 300, "owned_property_disposition_status_type": "Retain", "owned_property_rental_income_gross_amount": 0 }, { "@id": "01HKKYWF88WAB9QTZ6ZJTXX3CM", "@type": "property", "has_address": "01HKKZ88Y0563MGWSV945J406B", "accessory_unit_count": 1, "property_estimated_value_amount": 350000, "property_current_usage_type": "PrimaryResidence", "fha_secondary_residence_indicator": false, "property_mixed_usage_indicator": false, "manufactured_home_indicator": false, "rental_estimated_gross_monthly_rent_amount": 0 } ], "relationships": [ { "@type": "finance_relation", "has_person": "01HHEEBDSDHQK6H2FB884BDY3F", "has_loan": "01HKKYMREK90A70C6KKSPCH6H1", "has_property": "01HKKYHSWWTDV943CM8BCE67JH", "role": "Borrower" }, { "@type": "finance_relation", "has_company": "01HKKYNEXGQMZA6384RY4AF2DV", "has_loan": "01HKKYMREK90A70C6KKSPCH6H1", "role": "Lender" }, { "@type": "finance_relation", "has_person": "01HHEEBDSDHQK6H2FB884BDY3F", "has_loan": "01HKKYVNHW67R39873M8AEN4MC", "has_property": "01HKKYWF88WAB9QTZ6ZJTXX3CM", "role": "Borrower" } ], "leads": [ { "@id": "01HKKZ77VKJKB0XNA9PZR9CK5T", "@type": "lead", "has_property": "01HKKYWF88WAB9QTZ6ZJTXX3CM", "has_loan": "01HKKYVNHW67R39873M8AEN4MC" } ], "declarations": [ { "@id": "01HHEEBDS8G6X59BPK9G7E9N7P9", "@type": "declaration", "has_person": "01HHEEBDSDHQK6H2FB884BDY3F", "intent_to_occupy_indicator": true, "homeowner_past_three_years_indicator": true, "prior_property_title_type": "JointWithSpouse", "prior_property_usage_type": "PrimaryResidence", "special_borrower_seller_relationship_indicator": true, "undisclosed_borrowed_funds_indicator": true, "undisclosed_borrowed_funds_amount": 50000, "undisclosed_mortgage_application_indicator": false, "undisclosed_credit_application_indicator": false, "property_proposed_clean_energy_lien_indicator": true, "undisclosed_comaker_of_note_indicator": false, "outstanding_judgments_indicator": false, "presently_delinquent_indicator": false, "party_to_lawsuit_indicator": true, "prior_property_deed_in_lieu_conveyed_indicator": false, "prior_property_short_sale_completed_indicator": false, "prior_property_foreclosure_completed_indicator": true, "bankruptcy_indicator": true } ], "military_services": [ { "@id": "01HHEEBDS9D8ZH0NG7J8K20YVE0", "@type": "military_service", "associated_with": "01HHEEBDSDHQK6H2FB884BDY3F", "military_service_expected_completion_date": "2025-12-31", "military_status_type": "ActiveDuty" } ], "government_monitoring": [ { "@id": "01HHEEBDS9RXSCP5F72MAN3AB74", "@type": "government_monitoring", "represents": "01HHEEBDSDHQK6H2FB884BDY3F", "application_taken_method_type": "Internet", "ethnicity_collected_based_on_visual_observation_or_surname_indicator": false, "ethnicity_origin_type": "Other", "ethnicity_origin_type_other_description": "Salvadoran", "ethnicity_refusal_indicator": false, "ethnicity_type": "HispanicOrLatino", "gender_collected_based_on_visual_observation_or_name_indicator": false, "gender_refusal_indicator": false, "gender_type": "Male", "race_collected_based_on_visual_observation_or_surname_indicator": false, "race_refusal_indicator": false, "race_type": "AmericanIndianOrAlaskaNative", "race_type_additional_description": "Navajo" } ] } } ``` ##### Response 200400403422 application/json Copy Successfully generated the document ``` { "code": 200, "message": "https://www.example.com/" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Invalid key for service ``` { "message": "Please check the key you used to call this service." } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Response `200``application/json` 2 fields Successfully generated the document | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `string` | Link to download the generated document | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/pre-approval` #### Loan Application `generatePreApprovalLetter` Generate Pre Approval Letter Document This endpoint allows user to generate pre approval letter document. Document. The input is Staircase collection described below. The output is a download link to the generated document. ##### Request application/json Copy ``` { "data": { "people": [ { "@id": "_borrower", "@type": "person", "first_name": "Vladyslav", "middle_name": "J", "last_name": "Kartavets" }, { "@id": "_borrower2", "@type": "person", "first_name": "Mariia", "last_name": "Kartavets" }, { "@id": "_borrower3", "@type": "person", "first_name": "MMM", "last_name": "Kartavets" } ], "relationships": [ { "@type": "finance_relation", "role": "Borrower", "has_loan": "_loan", "has_person": "_borrower" }, { "@type": "finance_relation", "role": "CoBorrower", "has_loan": "_loan", "has_person": "_borrower2" }, { "@type": "finance_relation", "role": "CoBorrower", "has_loan": "_loan", "has_person": "_borrower3" } ], "loans": [ { "@id": "_loan", "@type": "loan", "has_property": "_property", "base_loan_amount": 425000, "note_rate_percent": 5.948, "loan_amortization_period_count": 30, "loan_amortization_period_type": "Year", "amortization_type": "Fixed", "rebate_percent": 1.1 } ], "properties": [ { "@id": "_property", "@type": "property", "has_address": "_address" } ], "addresses": [ { "@id": "_address", "@type": "address", "address_line_1": "1452 N. Mustang Rd", "city_name": "Mustang", "state_code": "OK", "postal_code": "73604" } ] } } ``` ##### Response 200400403422 application/json Copy Successfully generated the document ``` { "code": 200, "message": "https://www.example.com/" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Invalid key for service ``` { "message": "Please check the key you used to call this service." } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Response `200``application/json` 2 fields Successfully generated the document | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `string` | Link to download the generated document | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/xml` #### Loan Application Mismo `GenerateMismo` Create Mismo Generate Mismo FIle From Json ##### Request application/json Copy ``` { "transaction_id": "1234566880876439263" } ``` ##### Response 200400422500 application/json Copy Retrieve mismo presigned_url ``` { "mismo_presigned_url": "presigned_url", "mismo_blob_id": "blob_id", "mismo_blob_name": "blob_name" } ``` application/json Copy Request data failed validation ``` { "message": "{\"data\": [\"Missing data for required field.\"]}" } ``` application/json Copy Unprocessable entity error ``` { "code": 422, "message": { "response": "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" } } ``` 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" } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Loan application transaction_id. | ##### Response `200``application/json` 2 fields Retrieve mismo presigned_url | Field | Type | Description | | --- | --- | --- | | `code` | `string` | Status code for the api call. | | `message` | `object` | Mismo File | | `mismo_presigned_url` | `string` | Presigned_url to download the mismo file. | | `mismo_blob_id` | `string` | blob_id to download the mismo file. | | `mismo_blob_name` | `string` | blob_name for mismo file. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `422``application/json` 2 fields Unprocessable entity error | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `object` | Error Message. | | `response` | `string` | Response for the integrated product. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `403` `POST` `/listing-agreement` #### Generate Listing Agreement Cancellation Document `generateListingAgreementModification` This endpoint allows user to generate listing agreement cancellation document. The input is Staircase transaction identifier and lead identifier. The output is a download link to the generated document. ##### Request application/json Copy ``` { "transaction_id": "01J294HJWN2WV8FACHH7V4B4XN", "lead_id": "01J294HSCKRWKNGPBD7VAYSC3P" } ``` ##### Response 200400403422 application/json Copy Successfully generated the document ``` { "code": 200, "message": "https://www.example.com/" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Invalid key for service ``` { "message": "Please check the key you used to call this service." } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction Identifer | | `lead_id`required | `string` | Lead Identifier | ##### Response `200``application/json` 2 fields Successfully generated the document | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Link to download the generated document and blob id | | `report_link`required | `string` | Link to the generated document | | `blob_id`required | `string` | Blob identifier | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Bad request error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ### Examples `POST` `/api-examples` #### API Example Filtering Service `filter_api_example` This API provides a way to filter existing examples, which are comprehensive instances of a model, according to specific criteria, such as product API language (schema). The examples are then returned as subsets in the product API's registered language. The `generation_id` can be used to get the filtered example by the Get Api Example service. Each schema data point should be added to Product API Languages List View And, input body for generating example for one of the example collections on this schema should look like this: ``` { "product_api_identifier": "629abdf1-5fe1-4e7b-be30-eabcf9a157ae", "schema_type": "request", "example_language": "florida", "example_transaction_label": "01H5MBM1DTS7E2KTJW2YNEAA58" } ``` example_transaction_label is example identifier in Lexicon Example Store ##### Request application/json Copy ``` { "example_transaction_label": "01H4JF1F3BPX9TCTAAK9A3VA2A", "product_api_identifier": "01H4JF1F3BPX9TCTAAK9A3VA2B", "schema_type": "request", "output_language": "staircase-graph" } ``` ##### Response 201202 application/json Copy Generation is succeeded. ``` { "generated_examples": [ { "example_transaction_label": "01H4JF1F3BPX9TCTAAK9A3VA2A", "example_data": { "foo": "bar", "biz": [ "baz", "booz" ] } } ] } ``` application/json Copy Generation process is started successfully. ``` { "generation_id": "01H4JF1F3BPX9TCTAAK9A3VA2C" } ``` ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `example_transaction_label` | `string` | The label of the transaction that should be used to get the latest example collection. | | `product_api_identifier`required | `string` | The product API identifier. | | `schema_type`required | `string` | The type of the schema used for example to generate.`request``response` | | `example_language` | `string` | The language of the schema that should be applied to the example. Possible values are `lexicon` & `florida`. | | `output_language` | `string` | The output language of the generated example. The translation rules from example language to specified one must be defined in the `Language`. | ##### Response `201``application/json` 1 fields Generation is succeeded. | Field | Type | Description | | --- | --- | --- | | `generated_examples`required | `object[]` | Generated examples. | | `example_transaction_label`required | `string` | The identifier of the example. | | `example_data`required | `one of` | The generated example data. | ##### Response `202``application/json` 1 fields Generation process is started successfully. | Field | Type | Description | | --- | --- | --- | | `generation_id`required | `string` | The identifier of the generation process. | ##### Response `400``application/json` 1 fields Request data is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 1 fields Missing or wrong API key. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/api-examples/{generation_id}` #### Get Api Filtered Example `get_filtered_api_example` The service provides filtered example request by the call to the API Example Filtering Service service. ##### Response 200 Running200 Succeeded200 Failed application/json Copy Example is generated successfully ``` { "generation_id": "5f7b1b3a-0b0a-4b0a-9b0a-0b0a0b0a0b0c", "status": "RUNNING" } ``` application/json Copy Example is generated successfully ``` { "generation_id": "01H4JF1F3BPX9TCTAAK9A3VA2C", "status": "COMPLETED", "generated_examples": [ { "example_transaction_label": "01H4JF1F3BPX9TCTAAK9A3VA2A", "example_data": { "foo": "bar", "biz": [ "baz", "booz" ] } } ] } ``` application/json Copy Example is generated successfully ``` { "generation_id": "01H4JF1F3BPX9TCTAAK9A3VA2C", "status": "FAILED", "failure_reason": "The generation failed because of the failed translation to the `output_language`." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `generation_id` required | `string` path | `01H4JF1F3BPX9TCTAAK9A3VA2C` | The identifier of the generation process. | ##### Response `200``application/json` 4 fields Example is generated successfully | Field | Type | Description | | --- | --- | --- | | `generation_id`required | `string` | The identifier of the generation process. | | `status`required | `string` | The status of the generation process.`COMPLETED``FAILED``RUNNING` | | `failure_reason` | `string` | The reason of the generation failure. | | `generated_examples` | `object[]` | Generated examples. | | `example_transaction_label`required | `string` | The identifier of the example. | | `example_data`required | `one of` | The generated example data. | ##### Response `400``application/json` 1 fields Request data is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 1 fields Missing or wrong API key. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Lexicon `GET` `/lexicon/documents` #### List Documents `listDocuments` Returns the list of the available documents for labeling. ##### Response `200``application/json` 2 fields OK. | Field | Type | Description | | --- | --- | --- | | `documents_count`required | `integer` | Count of documents | | `documents`required | `object[]` | Available documents. | | `document_type`required | `string` | Document type | | `fields_count` | `integer` | Count of fields | | `_links` | `object` | Links | | `fields` | `string` | Link to get document fields | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `GET` `/lexicon/documents/{document_type}` #### Get Document `getDocument` Returns the document information. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `document_type` required | `string` path | `closing_disclosure` | Document type | ##### Response `200``application/json` 1 fields OK. | Field | Type | Description | | --- | --- | --- | | `document`required | `object` | Document | | `document_type`required | `string` | Document type | | `fields_count` | `integer` | Count of fields | | `fields`required | `object[]` | The array of all document root-level fields | | `base_class`required | `string` | The base class (parent type) of the document | | `container_name`required | `string` | The name of the container | | `properties`required | `object[]` | Fields of the document | | `name` | `string` | Field name | | `type` | `string` | Field type | | `enum` | `array` | Possible values for the field | | `relations`required | `object[]` | Relations of the document | | `property` | `string` | Name of the relation property | | `type` | `string` | The type of the related object | | `container_name` | `string` | Container name where the related object is located | | `types`required | `string[]` | Possible values of @type for this container. | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `404``application/json` 1 fields Resource is not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | `POST` `/lexicon/refresh` #### Refresh GTL Lexicon `refreshGtlLexicon` Forcibly refreshes the GTL lexicon according to the current Lexicon. ##### Response `202``application/json` 1 fields Accepted. | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | Message | ##### Response `403``application/json` 1 fields Missing API key | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ### Shapes `POST` `/validation` #### Validation `shapeValidation` Validate your data with SHACL shapes This endpoint receives your data payload and a set of SHACL shapes, both supplied in JSON-LD format. The SHACL shapes define the constraints that the data should meet. On submission, the API validates the provided data against the supplied SHACL shapes and returns a report, providing detailed feedback on the data validation. The report includes a list of validation messages (invocations) and a boolean flag (conforms) indicating whether the data meets all the constraints defined in the SHACL shapes. The API is not domain-specific and can be used for validating any kind of data structure against any set of SHACL shapes. This makes it a powerful tool for ensuring data quality and compliance across various domains and use cases. If you're new to SHACL, you can learn more about it from the official SHACL specification. ##### Request Format ExampleRequired ExamplePattern ExampleEnumeration Example application/json Copy Format Example ``` { "request_payload": { "people": [ { "@id": "sc:Bob", "@type": "person", "age": 20 } ] }, "shapes": { "@context": { "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/" }, "@type": "sh:NodeShape", "sh:targetClass": { "@id": "sc:person" }, "sh:property": [ { "sh:path": { "@id": "sc:age" }, "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#integer" } } ] } } ``` application/json Copy Example 2 ``` { "request_payload": { "people": [ { "@id": "01FD6ZKZD7WGZXYFGJBVPVP2Q5", "@type": "borrower", "has_first_name": { "has_value": "FirstName" }, "has_last_name": { "has_value": "LastName" }, "has_birth_date": { "has_value": "1972-09-03" }, "has_taxpayer_identifier_value": { "has_value": "000000001" }, "with_address": [ "01FD6ZNGJADZ0RB1H96FSE8BAB" ], "contact_at": [ "01FD6ZNGJW9X96WGWX2BD37CFY" ] } ], "addresses": [ { "@id": "01FD6ZNGJADZ0RB1H96FSE8BAB", "@type": "address", "has_address_line_1_text": { "has_value": "1234 Address Line" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Someplace" }, "has_state_code": { "has_value": "CA" }, "has_postal_code": { "has_value": "93308" }, "has_country_name": { "has_value": "US" } } ], "contact_information": [ { "@id": "01FD6ZNGJW9X96WGWX2BD37CFY", "@type": "contact_information", "has_email_address": { "has_value": "test@test.com" } } ] }, "shapes": { "@context": { "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@id": "sc:BorrowerShape", "@type": "sh:NodeShape", "sh:targetClass": { "@id": "sc:borrower" }, "sh:property": [ { "sh:path": { "@id": "sc:has_first_name" }, "sh:node": { "sh:property": { "sh:path": { "@id": "sc:has_value" }, "sh:datatype": { "@id": "xsd:string" }, "sh:minCount": 1 } }, "sh:minCount": 1 }, { "sh:path": { "@id": "sc:has_last_name" }, "sh:node": { "sh:property": { "sh:path": { "@id": "sc:has_value" }, "sh:datatype": { "@id": "xsd:string" }, "sh:minCount": 1 } }, "sh:minCount": 1 } ] } } ``` application/json Copy Pattern Example ``` { "request_payload": { "people": [ { "@id": "01FD6ZKZD7WGZXYFGJBVPVP2Q5", "@type": "person", "first_name": "john", "last_name": "Doe", "email": "john.doe" } ] }, "shapes": { "@context": { "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@id": "sc:PersonShape", "@type": "sh:NodeShape", "sh:targetClass": { "@id": "sc:person" }, "sh:property": [ { "sh:path": { "@id": "sc:first_name" }, "sh:minCount": 1, "sh:datatype": { "@id": "xsd:string" } }, { "sh:path": { "@id": "sc:last_name" }, "sh:datatype": { "@id": "xsd:string" }, "sh:minCount": 1 }, { "sh:path": { "@id": "sc:email" }, "sh:datatype": { "@id": "xsd:string" }, "sh:minCount": 1, "sh:pattern": "[\\w-]+(\\.[\\w-]+)*@[\\w-]+(\\.[\\w-]+)*(\\.[a-zA-Z]{2,})" } ] } } ``` application/json Copy ``` { "request_payload": { "people": [ { "@id": "sc:Bob", "@type": "borrower", "has_taxpayer_identifier_type": { "has_value": "individual_taxpayer_identification_number" } } ] }, "shapes": { "@context": { "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "shape": "https://www.staircase.co/florida/shapes/", "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@id": "shape:borrower_shape", "@type": "sh:NodeShape", "sh:property": [ { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "individual_taxpayer_identification_number" }, { "@type": "xsd:string", "@value": "social_security_number" }, { "@type": "xsd:string", "@value": "employer_identification_number" } ] }, "sh:path": { "@id": "sc:has_value" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" } } }, "sh:path": { "@id": "sc:has_taxpayer_identifier_type" } } ], "sh:targetClass": { "@id": "sc:borrower" } } } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `request_payload` | `object` | The data that you want to validate, provided in JSON-LD format | | `shapes` | `object` | SHACL shapes defining the constraints | | `@context` | `object` | The JSON-LD context, defining prefixes and base URLs | | `@id` | `string` | The identifier for the SHACL shape | | `@type` | `string` | The type of the SHACL shape, generally "sh:NodeShape" | | `sh:targetClass` | `object` | The target class that this shape applies to | | `sh:property` | `object[]` | SHACL shapes defining property | ##### Response `200``application/json` 1 fields The validation operation was successful. The response will contain a report of the validation results. | Field | Type | Description | | --- | --- | --- | | `invocations` | `object[]` | Invocation response | ##### Other responses `400``500` `POST` `/generate/syntactic/{language_name}` #### Syntactic Shapes Generation `generateSyntacticShape` Generate Syntactic Shapes This endpoint receives graph entities as a request body, language name as a path parameter and generates shacl shapes persisting them into graph. Language name parameter only accepts `florida` or `lexicon` values. Generated shapes can then be queried and utilized for further validation. Example of persisted shape (Lexicon): ``` @prefix owl: . @prefix rdf: . @prefix sc: . @prefix sh: . @prefix shape: . @prefix xsd: . shape:loan_shape a sh:NodeShape ; sh:targetClass sc:class2 ; shape:type "syntactic" . shape:person_shape a sh:NodeShape ; sh:property [ sh:datatype xsd:string ; sh:in [ a rdf:List ; rdf:first "val1" ; rdf:rest [ a rdf:List ; rdf:first "val2" ; rdf:rest [ a rdf:List ; rdf:first "val3" ; rdf:rest ] ] ] ; sh:maxInclusive 1e+02 ; sh:maxLength 35 ; sh:minInclusive 1e+00 ; sh:minLength 2 ; sh:path sc:prop1 ; sh:pattern "[A_Z]" ], [ sh:class sc:class2 ; sh:path sc:prop2 ] ; sh:targetClass sc:class1 ; shape:type "syntactic" . shape:type a owl:AnnotationProperty . ``` Example of persisted shape (Florida): Show the rest ``` @prefix owl: . @prefix rdf: . @prefix sc: . @prefix sh: . @prefix shape: . @prefix xsd: . shape:loan_shape a sh:NodeShape ; sh:targetClass sc:class2 ; shape:type "syntactic" . shape:person_shape a sh:NodeShape ; sh:property [ sh:class sc:class2 ; sh:path sc:prop2 ], [ sh:node [ sh:property [ sh:datatype xsd:string ; sh:in [ a rdf:List ; rdf:first "val1" ; rdf:rest [ a rdf:List ; rdf:first "val2" ; rdf:rest ] ] ; sh:maxInclusive 1e+02 ; sh:maxLength 35 ; sh:minCount 1 ; sh:minInclusive 1e+00 ; sh:minLength 2 ; sh:path sc:has_value ; sh:pattern "[A_Z]" ] ] ; sh:path sc:prop1 ] ; sh:targetClass sc:class1 ; shape:type "syntactic" . shape:type a owl:AnnotationProperty . ``` ##### Request application/json Copy Example ``` { "graph_entities": [ { "@id": "1", "@type": "graph_entity", "label": "person", "container_name": "people", "subClassOf": "class" }, { "@id": "2", "@type": "graph_entity", "label": "loan", "container_name": "loans", "subClassOf": "class" }, { "@id": "3", "@type": "graph_entity", "label": "has_first_name", "subClassOf": "data_property", "domain": "person", "range": "string", "minimum_length": 2, "maximum_length": 35, "minimum_value": 1, "maximum_value": 100, "pattern": "[A_Z]", "enumeration": [ "val1", "val2", "val3" ] }, { "@id": "4", "@type": "graph_entity", "label": "with_loan", "subClassOf": "object_property", "domain": "person", "range": "loan" } ] } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `lexicon` | Language Name, can either be lexicon or florida | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `graph_entities` | `object[]` | List of graph entities with required constrains. | | `label` | `string` | Label of a class or a property in Lexicon. | | `lexicon_identifier` | `string` | Lexicon Identifier of a class or a property in Lexicon. | | `subClassOf` | `string` | Type of a graph entity.`class``data_property``object_property` | | `container_name` | `string` | Container name of a class. | | `domain` | `string` | Domain of a property, should match lexicon identifier of one of the provided class graph entities. | | `range` | `string` | Range of a property, should either be lexicon identifier of a class (in case of object property) or one of the [`string`, `double`, `integer`, `date`, `dateTime`, `dateTimeStamp`, `boolean`] in case of data property. | | `minimum_length` | `integer` | Can be utilize to set minimum length constrain on a property. | | `maximum_length` | `integer` | Can be utilize to set maximum length constrain on a property. | | `minimum_value` | `number` | Can be utilize to set minimum value constrain on a property. | | `maximum_value` | `number` | Can be utilize to set maximum value constrain on a property. | | `pattern` | `string` | Can be utilize to set regex pattern constrain on a property. | | `enumeration` | `string[]` | Can be utilize to set enumeration constrain on a property. | ##### Response `200``application/json` 4 fields The syntactic shape generation was successful. | Field | Type | Description | | --- | --- | --- | | `code` | `integer` | Status Code. | | `message` | `string` | Message. | | `transaction_id` | `string` | Transaction ID. | | `collection_id` | `string` | Collection ID. | ##### Other responses `400``500` `POST` `/query/{language_name}` #### Shapes Query `queryShapes` Query Shapes The Shapes Query endpoint is for retrieving SHACL shapes in json-ld format which can further be inputted into validation endpoint. You can learn more about SHACL shapes from the official SHACL specification. #### Shapes Classification Lexicon Level Shapes - Syntactic shapes: Responsible for defining constraints such as datatype, enumeration, pattern, max/min length, and max/min value. - Semantic shapes: Responsible for implementing if-else kind of rules, such as conditional requirements for properties (e.g., if property1 exists, then property2 is required). API Level Shapes Show the rest - Semantic shapes: Currently, only semantic shapes are implemented for API level. They present the required/optional field information for properties and containers. To configure API schema information Product API Languages List View should be utilized. #### Retrieving Shapes Lexicon level shapes require a list of class `graph_entities` in the request body, indicating list of classes (e.g. person, loan, asset) you are willing to validate, see schema below. For obtaining API level shapes, the query parameters `product_api_identifier` and `schema_type` (request or response) should be defined. No need to provide any request body. The optional `shape_type` query parameter can take values 'syntactic' or 'semantic'. It defaults to 'syntactic' when not specified. ##### Request application/json Copy Lexicon level shapes retrieval ``` { "graph_entities": [ { "@id": "1", "@type": "graph_entity", "label": "person", "container_name": "people", "subClassOf": "class" }, { "@id": "2", "@type": "graph_entity", "label": "loan", "container_name": "loans", "subClassOf": "class" } ] } ``` ##### Response 200 Florida single syntactic shape200 Florida multiple syntactic shapes200 Lexicon syntactic shape200 Florida API level semantic shape application/json Copy The shape querying was successful. ``` { "@context": { "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "shape": "https://www.staircase.co/florida/shapes/", "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@id": "shape:borrower_shape", "@type": "sh:NodeShape", "sh:property": [ { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "individual_taxpayer_identification_number" }, { "@type": "xsd:string", "@value": "social_security_number" }, { "@type": "xsd:string", "@value": "employer_identification_number" } ] }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_taxpayer_identifier_type" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "married" }, { "@type": "xsd:string", "@value": "separated" }, { "@type": "xsd:string", "@value": "unmarried" } ] }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_marital_status_type" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "jointly" }, { "@type": "xsd:string", "@value": "not_jointly" } ] }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_joint_asset_liability_reporting_type" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "civil_union" }, { "@type": "xsd:string", "@value": "domestic_partnership" }, { "@type": "xsd:string", "@value": "other" }, { "@type": "xsd:string", "@value": "registered_reciprocal_beneficiary_relationship" } ] }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_domestic_relationship_type" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_domestic_relationship_type_other_description" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_first_name" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]{2}$" } }, "sh:path": { "@id": "sc:has_dependent_count" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_credit_report_identifier" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_full_name" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_policy_feature_description" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_domestic_relationship_state_code" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_community_property_state_resident_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_middle_name" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_domestic_relationship_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_self_declared_military_service_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]{3}$" } }, "sh:path": { "@id": "sc:has_borrower_total_mortgaged_properties_count" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_spousal_va_benefits_eligibility_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$" } }, "sh:path": { "@id": "sc:has_borrower_birth_date" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_suffix_name" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]{9}$" } }, "sh:path": { "@id": "sc:has_taxpayer_identifier_value" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_last_name" } } ], "sh:targetClass": { "@id": "sc:borrower" } } ``` application/json Copy The shape querying was successful. ``` { "@context": { "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "shape": "https://www.staircase.co/florida/shapes/", "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@graph": [ { "@id": "shape:address_shape", "@type": "sh:NodeShape", "sh:property": [ { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "mailing" } ] }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_address_type" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_address_line_1_text" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_county_name" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_state_code" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_postal_code" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_city_name" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_unit_identifier" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_country_code" } } ], "sh:targetClass": { "@id": "sc:address" } }, { "@id": "shape:loan_shape", "@type": "sh:NodeShape", "sh:property": [ { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:in": { "@list": [ { "@type": "xsd:string", "@value": "related_loan" }, { "@type": "xsd:string", "@value": "subject_loan" } ] }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_loan_role_type" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_below_market_subordinate_financing_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_prepayment_penalty_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_buydown_temporary_subsidy_funding_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^\\d{1,9}(\\.\\d{1,2})?$" } }, "sh:path": { "@id": "sc:has_pace_loan_payoff_amount" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_construction_loan_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#date" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$" } }, "sh:path": { "@id": "sc:has_application_received_date" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_loan_to_value_ltv_ratio_percent" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_lending_limit_amount" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_home_equity_combined_loan_to_value_hcltv_ratio_percent" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_balloon_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#integer" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]\\{2}$" } }, "sh:path": { "@id": "sc:has_total_mortgaged_properties_count" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#integer" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]\\{3}$" } }, "sh:path": { "@id": "sc:has_initial_fixed_period_effective_months_count" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_interest_only_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^\\d{1,9}(\\.\\d{1,2})?$" } }, "sh:path": { "@id": "sc:has_energy_improvement_amount" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_heloc_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_negative_amortization_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_energy_related_improvements_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_loan_affordable_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_conversion_of_contract_for_deed_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_total_subordinate_financing_amount" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_total_subordinate_financing_proceeds_applied_amount" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#boolean" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_renovation_loan_indicator" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#double" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_combined_loan_to_value_cltv_ratio_percent" } }, { "sh:node": { "sh:property": { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#integer" }, "sh:path": { "@id": "sc:has_value" }, "sh:pattern": "^[0-9]\\{1}$" } }, "sh:path": { "@id": "sc:has_borrower_count" } } ], "sh:targetClass": { "@id": "sc:loan" } } ] } ``` application/json Copy The shape querying was successful. ``` { "@context": { "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "shape": "https://www.staircase.co/lexicon/shapes/", "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@id": "shape:person_shape", "@type": "sh:NodeShape", "sh:property": [ { "sh:datatype": { "@id": "http://www.w3.org/2001/XMLSchema#string" }, "sh:maxLength": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "35" }, "sh:minLength": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "2" }, "sh:path": { "@id": "sc:first_name" } }, { "sh:class": { "@id": "sc:loan" }, "sh:path": { "@id": "sc:has_loan" } } ], "sh:targetClass": { "@id": "sc:person" } } ``` application/json Copy The shape querying was successful. ``` { "@context": { "sh": "http://www.w3.org/ns/shacl#", "sc": "https://www.staircase.co/ontology/", "shape": "https://www.staircase.co/florida/shapes/", "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "xsd": "http://www.w3.org/2001/XMLSchema#" }, "@graph": [ { "@id": "shape:person_shape", "@type": "sh:NodeShape", "sh:property": [ { "sh:node": { "sh:property": { "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_first_name" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" } }, { "sh:node": { "sh:property": { "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" }, "sh:path": { "@id": "sc:has_value" } } }, "sh:path": { "@id": "sc:has_last_name" } }, { "sh:path": { "@id": "sc:with_loan" }, "sh:minCount": { "@type": "http://www.w3.org/2001/XMLSchema#integer", "@value": "1" } } ], "sh:targetClass": { "@id": "sc:person" } }, { "@id": "sc:CollectionShape", "@type": "sh:NodeShape", "sh:targetNode": { "@id": "sc:root" }, "sh:property": [ { "sh:path": { "@id": "sc:people" }, "sh:minCount": 1 } ] } ] } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `language_name` required | `string` path | `lexicon` | Language Name, can either be lexicon or florida | | `shape_type` | `string` query | `semantic` | Shape type, either semantic or syntactic. | | `product_api_identifier` | `string` query | `f4d96037-ef32-4c21-a90e-5261425d16d` | Staircase product api identifier. | | `schema_type` | `string` query | `request` | Shape type, either request or response. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `graph_entities` | `object[]` | List of graph entities with required constrains. | | `label` | `string` | Label of a class or a property in Lexicon. | | `lexicon_identifier` | `string` | Lexicon Identifier of a class or a property in Lexicon. | | `subClassOf` | `string` | Type of a graph entity.`class` | | `container_name` | `string` | Container name of a class. | ##### Other responses `200``400``500` ### Language Utils `POST` `/language-equivalent-generator/execute` #### Entity Equator `entityEquator` Entity Equator API can be utilized to generate equivalence class information from the mappings. This API requires the input of a ruleset_name and rules. You can also specify callback_url. The rules need to be defined from/to the staircase-graph/lexicon in order to generate equivalence information. This operation is asynchronous, meaning that once you execute this API, the process of generating equivalences will commence and the results will be visible in the list-view after a certain amount of time. Show the rest Important note: ruleset_name should one of the following this template: ``` "staircase-graph_CUSTOMER_LANGUAGE_NAME_TRANSLATE" ``` ``` "CUSTOMER_LANGUAGE_NAME_staircase-graph_TRANSLATE" ``` ``` "lexicon_CUSTOMER_LANGUAGE_NAME_TRANSLATE" ``` ``` "CUSTOMER_LANGUAGE_NAME_lexicon_TRANSLATE" ``` Example input: ``` { "rules": [ { "id": "2", "definition": { "from": { "path": "foreign_objects" }, "to": { "path": "blobs" }, "attribute_mappings": [ { "from": { "path": "has_mime_type_identifier" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_value" }, "to": { "path": "mimeTypeIdentifier" } } ] }, { "from": { "path": "has_object_name" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_value" }, "to": { "path": "name" } } ] } ] } }, { "id": "3", "definition": { "from": { "path": "messages", "evaluate_separate": True }, "to": { "path": "messages" }, "attribute_mappings": [ { "from": { "path": "with_document_sets", "evaluate_separate": True }, "to": { "path": "messages" }, "attribute_mappings": [ { "from": { "path": "with_document_set" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "with_document" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_document_identifier" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_value" }, "to": { "path": "id" } } ] } ] } ] } ] } ] } } ], "ruleset_name": "staircase-graph_CUSTOMER_LANGUAGE_NAME_TRANSLATE" } ``` Important note: In order to execute this API automatically with creating/updating rules: please subscribe lexicon-workflow-data bundle in marketplace. You can review generated equivalences from list-view: ##### Request application/json Copy ``` { "ruleset_name": "CUSTOMER_LANGUAGE_NAME_staircase-graph_TRANSLATE", "rules": [ { "id": "1", "definition": { "from": { "path": "foreign_objects" }, "to": { "path": "blobs" }, "attribute_mappings": [ { "from": { "path": "has_mime_type_identifier" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_value" }, "to": { "path": "mimeTypeIdentifier" } } ] }, { "from": { "path": "has_object_name" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_value" }, "to": { "path": "name" } } ] } ] } }, { "id": "2", "definition": { "from": { "path": "messages", "evaluate_separate": true }, "to": { "path": "messages" }, "attribute_mappings": [ { "from": { "path": "with_document_sets", "evaluate_separate": true }, "to": { "path": "messages" }, "attribute_mappings": [ { "from": { "path": "with_document_set" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "with_document" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_document_identifier" }, "to": { "path": "" }, "attribute_mappings": [ { "from": { "path": "has_value" }, "to": { "path": "id" } } ] } ] } ] } ] } ] } } ] } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `ruleset_name` | `string` | Ruleset name for the rules | | `rules` | `object[]` | Rule array | ##### Response `200``application/json` 2 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/entity-translation/execute` #### Entity Translation `entityTranslation` This API can translate graph entities by providing equivalent information between the input language and output language. Entity Translation API requires the input_language and output_language parameters to be provided as query parameters, and the translated data object should be included in the request body. Example input: ``` { "graph_entities": [ { "@id": "g_e_1", "@type": "graph_entity", "has_comment": { "has_value": "string" }, "has_container_name": { "has_value": "string" }, "has_data_path": { "has_value": "string" }, "has_deprecation_indicator": { "has_value": "boolean" }, "has_domain": { "has_value": "string" }, "has_graph_entity_type": { "has_value": "enum - class, data_property, object_property" }, "has_label": { "has_value": "string" }, "has_language": { "has_value": "string" }, "has_lexicon_identifier": { "has_value": "string" }, "has_range": { "has_value": "string" } } ] } ``` The API performs entity translation based on the equivalent information for properties in the languages. Show the rest ##### Request application/json Copy ``` { "graph_entities": [ { "@id": "g_e_1", "@type": "graph_entity", "has_comment": { "has_value": "string" }, "has_container_name": { "has_value": "string" }, "has_data_path": { "has_value": "string" }, "has_deprecation_indicator": { "has_value": true }, "has_domain": { "has_value": "string" }, "has_graph_entity_type": { "has_value": "class" }, "has_label": { "has_value": "string" }, "has_language": { "has_value": "string" }, "has_lexicon_identifier": { "has_value": "string" }, "has_range": { "has_value": "string" } } ] } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `input_language` required | `string` query | `input_language` | The input language for the translation. It can be 'staircase-graph' or a customer-specific language. | | `output_language` required | `string` query | `output_language` | The output language for the translation. It can be 'staircase-graph' or a customer-specific language. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `graph_entities` | `object[]` | Graph entities that is going to be translated | | `@id` | `string` | The unique identifier for the graph entity | | `@type` | `string` | The type of the graph entity | | `has_comment` | `object` | Property for "has_comment" | | `has_value` | `string` | The value of the comment for the entity | | `has_container_name` | `object` | Property for "has_container_name" | | `has_value` | `string` | The value of the container name for the entity | | `has_data_path` | `object` | Property for "has_data_path" | | `has_value` | `string` | The value of the data path for the entity | | `has_deprecation_indicator` | `object` | Property for "has_deprecation_indicator" | | `has_value` | `boolean` | The value of the deprecation indicator for the entity | | `has_domain` | `object` | Property for "has_domain" | | `has_value` | `string` | The value of the domain for the entity | | `has_graph_entity_type` | `object` | Property for "has_graph_entity_type" | | `has_value` | `string` | The value of the graph entity type for the entity | | `has_label` | `object` | Property for "has_label" | | `has_value` | `string` | The value of the label for the entity | | `has_language` | `object` | Property for "has_language" | | `has_value` | `string` | The value of the language for the entity | | `has_lexicon_identifier` | `object` | Property for "has_lexicon_identifier" | | `has_value` | `string` | The value of the lexicon identifier for the entity | | `has_range` | `object` | Property for "has_range" | | `has_value` | `string` | The value of the range for the entity | ##### Response `200``application/json` 2 fields Successfully translated entity | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/graph-registration/{language_name}` #### Register Language `registerLanguage` Language Registration The Register Language API allows you to register a customer's language in Persistence Graph. To register a language, you need to provide a JSON-Schema and the name of the language as input. Please note that this operation is asynchronous. After registering the language, you can view the resulting schema in the entity viewer of your environment by appending the language name as the first path parameter. For example, to view the schema for a language named "test_language," you would use the URL: Show the rest The Entity Viewer incorporates a caching mechanism with a refresh rate of 30 minutes. This means that once you have viewed the language schema, any changes made to the JSON-Schema will be reflected in the viewer after a 30-minute interval. In order to get status of your language registration you can either check returned transaction and collection ids or add `callback_url` parameter to request body. In order to use this API please subscribe to "Language Graph Registration" component in your environment. Important note: In order to execute this API automatically with creating languages: please subscribe lexicon-workflow-data bundle in marketplace. ##### Request application/json Copy ``` { "json_schema": { "$schema": "https://json-schema.org/draft/2020-12/schema", "title": "Person", "type": "object", "properties": { "firstName": { "type": "string", "description": "The person's first name." }, "lastName": { "type": "string", "description": "The person's last name." }, "age": { "description": "Age in years which must be equal to or greater than zero.", "type": "integer" } } } } ``` ##### Response 200400 application/json Copy Successfully switched input source ``` { "message": "Registration process started!", "transaction_id": "01FJCADX5QEXEDVRWNXAK206MA", "collection_id": "01EZQ32PJQGKRA6HR8D72Q9FFF" } ``` application/json Copy Request data failed validation ``` { "message": "Provided JSON Schema is invalid or missing!" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `language_name` required | `string` path | `test_language` | Language Name | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string` | Callback url. | | `json_schema`required | `object` | JSON-Schema of a language. | ##### Response `200``application/json` 3 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `message` | `object` | Message. | | `transaction_id` | `object` | Transaction ID. | | `collection_id` | `object` | Collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `message`required | `object` | Message. | | `transaction_id` | `object` | Transaction ID. | | `collection_id` | `object` | Collection ID. | `POST` `/invocation-extension` #### Extend Invocation `extendInvocation` This endpoint receives list of invocations with invocation codes and extends each with invocation category and invocation message. One can also provide message parameters that will be replacing placeholders in the invocation message if any are present. Invocation codes, categories and messages are configured through the list view. In order to use this feature please subscribe to `Lexicon Invocation Extension` component in the Marketplace. ##### Request Florida ExampleLexicon Example application/json Copy Florida Example ``` { "invocations": [ { "has_invocation_code_type": { "has_value": "40002" }, "has_message_parameters": { "has_value": [ "has_first_name", "person" ] } }, { "has_invocation_code_type": { "has_value": "2000" } } ] } ``` application/json Copy Lexicon Example ``` { "invocations": [ { "invocation_code": "40002", "message_parameters": [ "first_name", "person" ] }, { "invocation_code": "2000" } ] } ``` ##### Response 200 Florida response example200 Lexicon response example application/json Copy Florida Example ``` { "invocations": [ { "has_invocation_code_type": { "has_value": "40002" }, "has_message_parameters": { "has_value": [ "has_first_name", "person" ] }, "has_invocation_category_type": { "has_value": "CARDINALITY_ERROR" }, "has_invocation_message": { "has_value": "Cardinality Error: Less than the required number of values found fo", "the property has_first_name on the specified class at person. Ensure the correct cardinality according to the constraints'": null } }, { "has_invocation_code_type": { "has_value": "2000" }, "has_invocation_category_type": { "has_value": "OK" }, "has_invocation_message": { "has_value": "Invocation is successful" } } ] } ``` application/json Copy Lexicon Example ``` { "invocations": [ { "invocation_code": "40002", "message_parameters": [ "first_name", "person" ], "invocation_category_type": "CARDINALITY_ERROR", "invocation_message": "Cardinality Error: Less than the required number of value", "found for the property first_name on the specified class at person. Ensure the correct cardinality according to the constraints'": null }, { "invocation_code": "2000", "invocation_category_type": "OK", "invocation_message": "Invocation is successful" } ] } ``` ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `invocations` | `array` | List of Invocations | ##### Response `200``application/json` 1 fields The operation was successful. | Field | Type | Description | | --- | --- | --- | | `invocations` | `array` | Extended invocation response | ##### Other responses `400``500` ## Canonical model - `document` ## Errors `400``403``404``422``500` ## More in Contract - Previous product: Insurance - Next product: Notary --- # Notary # Notary Remote online notarisation: scheduling the ceremony, running it, and returning the notarised documents and the notary's record. A caller sends the closing package and the participants. The product schedules the session with the notarisation vendor, tracks it through completion, and returns the executed documents together with the audit record the notary is required to keep. The session is asynchronous and can span days. The caller is not made to poll for it: the flow is declared with a callback and the completion arrives as an event. ## Operations ### Workflow `POST` `/notary/input/selection` #### Switch Input Source `switchInputSource` Switch Input Source API can be used to switch input source for Notary process. Available sources: - docutech - encompass ##### Request application/json Copy ``` { "source": "docutech" } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `source` | `string` | Input Source`docutech``encompass` | ##### Response `200``application/json` 2 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/products/notary/invocations` #### Notary API `invokeProductFlow` Services In Notary API operation: - File is created in E-Notary partner. - If documents are provided in input collection: documents are added to created file in E-Notary partner. - If documents are not provided in input collection: it invokes document generation then collects the generated documents and added to created file in E-Notary partner. - File is retrieved **Notary API ** invokes an automated process that sends the Staircase collection data to given e-Notary partner. Show the rest To invoke Notary API, you will need: - transaction_id, a unique identifier for Staircase operations. - collection_id, a unique identifier that contains Staircase V2 data that is going to send to the partner. - vendor_name, a supported vendor name for this operation - product_flow_name, a Staircase Connector flow name that is going to be executed in the process. - callback_url, URL for getting result of this asynchronous operation.(optional) To send a file to e-notary partner, there are some mandatory Staircase containers you should store in the collection that you provide in the input: - documents container for storing the document itself, document id, document name.(optional, documents can be generated if it's missing) - contact_point_emails container for storing signer email information. - addresses container for storing subject property address information. - loan_identifiers container for storing loan identifier information. - terms_of_loans container for storing purpose type and note amount information - contact_points container for establishing relationship between person and email. - people container for signer name and establishing relationship between person and contact point. - closing_information container for storing closing date information. - sales_contracts container for storing sale price information. Example Staircase Collection data: ``` { "closing_information": [ { "has_closing_date": { "has_value": "2022-12-27" }, "@type": "closing_information", "@id": "01GMX7JA3NFZTXYJCQAYJB36C8" } ], "contact_point_emails": [ { "@type": "contact_point_email", "@id": "01GMX7JA3MJMZCS0GSZAB48RV0", "has_contact_point_email_value": { "has_value": "utku.ozdil@staircase.co" } }, { "@type": "contact_point_email", "@id": "01GMX7JA3MJMZCS0GSZAB48RV1", "has_contact_point_email_value": { "has_value": "utku.ozdil1@staircase.co" } } ], "addresses": [ { "has_address_line_1_text": { "has_value": "TEST ROAD" }, "has_state_code": { "has_value": "AL" }, "@type": "subject_property_address", "@id": "sprop_RWbmV8HG5TRDHwutizUiRM", "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "35020" }, "has_city_name": { "has_value": "HELENA" } } ], "loan_identifiers": [ { "has_loan_identifier_type": { "has_value": "lender_loan" }, "@type": "loan_identifier", "has_loan_identifier_value": { "has_value": "STAIRCASE_DEMO" }, "@id": "01GMX7JA3NDAYKA02ZC3P4TXWS" } ], "contact_points": [ { "with_contact_point_email": [ "01GMX7JA3MJMZCS0GSZAB48RV0" ], "@type": "contact_point", "@id": "01GMX7JA3M17XW1C0N71T4TS1J" }, { "with_contact_point_email": [ "01GMX7JA3MJMZCS0GSZAB48RV1" ], "@type": "contact_point", "@id": "01GMX7JA3M17XW1C0N71T4TS1K" } ], "terms_of_loans": [ { "has_loan_purpose_type": { "has_value": "purchase" }, "@id": "01GMX7JA3N7QV53DA8K922HB7N", "has_note_amount": { "has_value": 100000 }, "@type": "terms_of_loan" } ], "people": [ { "has_full_name": { "has_value": "STAIRCASE TEST USER" }, "with_contact_point": [ "01GMX7JA3M17XW1C0N71T4TS1J" ], "@id": "utku.ozdil@staircase.co", "@type": "borrower" }, { "has_full_name": { "has_value": "STAIRCASE TEST USER 2" }, "with_contact_point": [ "01GMX7JA3M17XW1C0N71T4TS1K" ], "@id": "utku.ozdil1@staircase.co", "@type": "lender" } ], "sales_contracts": [ { "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1000000 }, "@id": "01GMX7JA3NZSKH4QYQPTEJ2V6N" } ] } ``` Example Staircase Collection data for a document after Document generation: ``` { "document_form_fields": [ { "@id": "SignatureDate1", "@type": "form_field_text", "with_field_reference": [ "01GKXY7YJBJSMBK5PHZK1ZXZVK" ], "with_signer": [ "BOR1" ] }, { "@id": "SignerSignature1", "@type": "form_field_signature", "with_field_reference": [ "01GKXY7YJB26S751TBTBNHN74E" ], "with_signer": [ "BOR1" ] } ], "document_forms": [ { "@id": "01GKXY7YJBY543NCPQXS51VP6S", "@type": "document_form", "with_document_form_field": [ "01GKXY7YJBAZ731PHEW6GR71KB", "01GKXY7YJBCFD5XTRTQHFGJGKD" ] } ], "documents": [ { "@id": "18566", "@type": "document", "has_document_name": { "has_value": "Closing Disclosure (John Test)" }, "has_staircase_blob_identifier": { "has_value": "01GKXY7V1F3RGVGTW5FY28GWFT" }, "with_document_form": [ "01GKXY7YJBY543NCPQXS51VP6S" ] } ], "field_references": [ { "@id": "01GKXY7YJBJSMBK5PHZK1ZXZVK", "@type": "field_reference", "has_field_height_number": { "has_value": 10 }, "has_field_width_number": { "has_value": 40.68 }, "has_offset_from_left_number": { "has_value": 256.1 }, "has_offset_from_top_number": { "has_value": 188.56 }, "has_page_number_value": { "has_value": "5" } }, { "@id": "01GKXY7YJB26S751TBTBNHN74E", "@type": "field_reference", "has_field_height_number": { "has_value": 15.4 }, "has_field_width_number": { "has_value": 194.04 }, "has_offset_from_left_number": { "has_value": 28.8 }, "has_offset_from_top_number": { "has_value": 186.06 }, "has_page_number_value": { "has_value": "5" } } ] } ``` Example Staircase response for Retrieve File operation: ``` { "closing_information": [ { "has_closing_date": { "has_value": "2022-12-27" }, "@type": "closing_information", "@id": "01GNVY2GKZZ154SCVTG3WT419K" } ], "contact_point_emails": [ { "@type": "contact_point_email", "@id": "01GNVY2GKZ2FW6FVKJW2NFB74W", "has_contact_point_email_value": { "has_value": "utku.ozdil@staircase.co" } }, { "@type": "contact_point_email", "@id": "01GNVY2GKZX4P8MN9QKW0HJ0N8", "has_contact_point_email_value": { "has_value": "utku.ozdil1@staircase.co" } } ], "addresses": [ { "has_address_line_1_text": { "has_value": "TEST ROAD" }, "has_state_code": { "has_value": "AL" }, "@type": "subject_property_address", "@id": "sprop_XxdZMVAzMJ8ty9CrESh4PY", "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "35020" }, "has_city_name": { "has_value": "HELENA" } } ], "documents": [ { "@id": "filedoc_fdBXc9PRynQy4jg8dfLUPg", "has_document_signed_indicator": { "has_value": false }, "has_staircase_blob_identifier": { "has_value": "01GNVY2DDEM6K57HBBM4BP4C7P" }, "@type": "document" }, { "@id": "filedoc_2KmscMkesntZnREiBSeTXP", "has_document_signed_indicator": { "has_value": false }, "has_staircase_blob_identifier": { "has_value": "01GNVY2EFXQGMS5PFK0FA047CE" }, "@type": "document" }, { "@id": "filedoc_FRMjvbgyYY3FPYk8ParAkY", "has_document_signed_indicator": { "has_value": false }, "has_staircase_blob_identifier": { "has_value": "01GNVY2E9EG2BVPJD1DZJFT2TP" }, "@type": "document" }, { "@id": "filedoc_LRNh6osA3PVDj5tnPDouai", "has_document_signed_indicator": { "has_value": false }, "has_staircase_blob_identifier": { "has_value": "01GNVY2DZ0M8W6Y1KJYBD7QYSD" }, "@type": "document" }, { "@id": "filedoc_UuxRL8mjFD6HBkuqYbarNf", "has_document_signed_indicator": { "has_value": false }, "has_staircase_blob_identifier": { "has_value": "01GNVY2EQ9TRG4XBVYN6DG839W" }, "@type": "document" }, { "@id": "filedoc_k2viwb7N92kN6XJohVNq42", "has_document_signed_indicator": { "has_value": false }, "has_staircase_blob_identifier": { "has_value": "01GNVY2DPHEFHQP4M5GTZX7MSZ" }, "@type": "document" } ], "customer_requests": [ { "@type": "customer_request", "has_customer_request_identifier": { "has_value": "file_L3uAMczFbzbUt4GqJhYsJ6" }, "@id": "01GNVY2GKZ17BWFDFTZ0WGBFQH" } ], "loan_identifiers": [ { "@type": "loan_identifier", "has_loan_identifier_value": { "has_value": "STAIRCASE_DEMO" }, "@id": "01GNVY2GKZZ01V63234K08CZYJ" } ], "contact_points": [ { "with_contact_point_email": [ "01GNVY2GKZ2FW6FVKJW2NFB74W" ], "@type": "contact_point", "@id": "01GNVY2GKZ1AXV165ZC57ZHB8M" }, { "with_contact_point_email": [ "01GNVY2GKZX4P8MN9QKW0HJ0N8" ], "@type": "contact_point", "@id": "01GNVY2GKZV669YHX85Q7ASNJT" } ], "terms_of_loans": [ { "has_loan_purpose_type": { "has_value": "purchase" }, "@id": "01GNVY2GKZ1YJT6500TQ4CVRZZ", "has_note_amount": { "has_value": 100000 }, "@type": "terms_of_loan" } ], "people": [ { "has_last_name": { "has_value": "USER" }, "with_contact_point": [ "01GNVY2GKZ1AXV165ZC57ZHB8M" ], "@id": "01GNVY2GKZ9NMSCVZJQHJR41AF", "has_first_name": { "has_value": "STAIRCASE" }, "has_middle_name": { "has_value": "TEST" }, "@type": "borrower" }, { "has_last_name": { "has_value": "USER" }, "with_contact_point": [ "01GNVY2GKZV669YHX85Q7ASNJT" ], "@id": "01GNVY2GKZXB7GJ8M5S879MDZH", "has_first_name": { "has_value": "STAIRCASE" }, "has_middle_name": { "has_value": "TEST" }, "@type": "person" } ], "sales_contracts": [ { "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 1000000 }, "@id": "01GNVY2GKZBBEZZK8YHFE0XNX4" } ] } ``` ##### Request Create A FileAdd Document application/json Copy ``` { "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X", "collection_id": "01FV0H1MWC9N5F71DG0W79V0H3", "product_flow_name": "create_file", "vendor_name": "" } ``` application/json Copy ``` { "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X", "collection_id": "01FV0H1MWC9N5F71DG0W79V0H3", "product_flow_name": "add_document", "vendor_name": "", "options": { "file_identifier": "file_identifier" } } ``` ##### Response 201400403404 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" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 9 fields | Field | Type | Description | | --- | --- | --- | | `partner_name` | `string` | Vendor 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. | | `transaction_id` | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `response_collection_id` | `string` | Response Collection ID. | | `callback_url` | `string (uri)` | Callback URL. | | `request_data` | `object` | Request JSON body. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | | `invocation_mode` | `string` | The invocation mode of a product flow single_flow or waterfall, default value single_flow | ##### Response `201``application/json` 12 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `request_collection_id`required | `string` | Request collection ID. | | `response_collection_id`required | `string` | Response collection ID. | | `product_flow_name` | `string` | Product flow name. | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | | `tags` | `string[]` | List of tags. | | `options` | `object` | Additional information that should be passed to the connector but not be added to the request collection. | | `widget_url` | `string` | Product widget_url listening on the connector widget_url | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | `GET` `/products/notary/invocations/{invocation_id}` #### Retrieve Status `RetrieveProductFlowInvocationStatus` Retrieves the status of running e-notary invocation. ##### Response 200400403404500 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", "partner_language": "test-convert-v2-output_language", "service_invocation": { "Connector": { "connector_flow_name": "test-convert_flow", "debug_config": { "dry_run": true }, "status": "COMPLETED", "invocation_id": "08589dde-d0ab-48d2-8912-6060f7413c52" }, "Translator": { "output": { "status": "COMPLETED", "invocation_id": "f70d76d8-c57f-42c5-8685-ea64fcc64d16", "language_name": "staircase" }, "input": { "status": "COMPLETED", "invocation_id": "b38f8b65-e5de-4acd-b2f3-7a372f922fc2", "language_name": "test-convert-v2-input_language" }, "convert_output": { "status": "COMPLETED", "invocation_id": "f70d76d8-c57f-42c5-8685-ea64fcc64d16", "language_name": "staircase" }, "convert_input": { "status": "COMPLETED", "invocation_id": "850d7d39-b90d-4ee5-a903-b3ad6d06ec4a", "language_name": "staircase" } } }, "staircase_language_version": 2, "staircase_output_version": 0, "validation": false, "version": 2 } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | Product flow invocation identifier | ##### Response `200``application/json` 6 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Mapped status of the invocation.Example `STARTED` | | `message` | `string` | Message.Example `Verification is completed, please check response collection to see verification data.` | | `created_at` | `string` | Time of creation | | `invocation_status` | `string` | Status of the product invocation before mapping | | `last_updated_at` | `string` | Last time the collection was updated | | `service_invocation` | `object` | Includes underlying services invocation. | | `Connector` | `object` | Response from Connector service. | | `connector_flow_name` | `string` | Vendor flow name. | | `invocation_id` | `string (uuid)` | Connector job ID. | | `status` | `string` | Connector flow status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING` | | `Translator` | `object` | Response from Translator service about input and output translation. | | `input` | `object` | Input translation status. | | `language_name` | `string` | Input translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Input translation status.`COMPLETED``FAILED``RUNNING` | | `convert_input` | `object` | Convert input translation status. | | `language_name` | `string` | Input translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Input translation status.`COMPLETED``FAILED``RUNNING` | | `output` | `object` | Output translation status. | | `language_name` | `string` | Output translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Output translation status.`COMPLETE``FAILED``RUNNING` | | `convert_output` | `object` | Convert output translation status. | | `language_name` | `string` | Output translation language. | | `translation_id` | `string (uuid)` | Translation ID. | | `status` | `string` | Output translation status.`COMPLETE``FAILED``RUNNING` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message`required | `string` | — | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `PATCH` `/connector-jobs/vendors/docutech/passed-credentials` #### Set Docutech Credentials `setDocutechCredentials` Set Docutech Credentials API can be used to set Docutech Credentials for the environment. Example input body: ``` { "docutech_url": "EXAMPLE" } ``` ##### Request application/json Copy ``` { "docutech_url": "example" } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `docutech_url` | `string` | Docutech URL | ##### Response `200``application/json` 1 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `docutech_url` | `string` | Stored Docutech URL | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `PUT` `/customer-account-manager/update-configurations` #### Set Docutech Token Configuration `setDocutechTokenConfiguration` Set Docutech Token Configuration API can be used to set Docutech token configuration for the environment. Example input body: ``` { "product": "document", "environment": "YOUR_SUBDOMAIN.staircaseapi.com", "configurations": [ { "key": "private_key", "value": "EXAMPLE" }, { "key": "iss", "value": "EXAMPLE" }, { "key": "sub", "value": "EXAMPLE" }, { "key": "aud", "value": "EXAMPLE" }, { "key": "token_url", "value": "EXAMPLE" } ] } ``` ##### Request application/json Copy ``` { "product": "example", "environment": "example", "configurations": [ { "key": "private_key", "value": "example" }, { "key": "iss", "value": "example" }, { "key": "sub", "value": "example" }, { "key": "aud", "value": "example" }, { "key": "token_url", "value": "example" } ] } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `product` | `string` | Product Name | | `environment` | `string` | Staircase environment information | | `configurations` | `string[]` | Configuration array | ##### Response `200``application/json` 3 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `product` | `string` | Product Name | | `environment` | `string` | Staircase environment information | | `configurations` | `string[]` | Configuration array | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/customer-account-manager/retrieve-configurations` #### Retrieve Docutech Token Configuration `retrieveDocutechTokenConfiguration` Retrieve Docutech Token Configuration API can be used to retrieve Docutech token configuration for the environment. For query parameters; product should be "document" and environment should be subdomain.staircaseapi.com Example query parameters: ``` ?product=document&environment=stavvy.staircaseapi.com ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `product` | `string` query | `document` | You can use this to filter configurations by product name | | `environment` | `string` query | `.staircaseapi.com` | You can use this to filter configurations by environment name | ##### Response `200``application/json` 3 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `product` | `string` | Product Name | | `environment` | `string` | Staircase environment information | | `configurations` | `string[]` | Configuration array | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `POST` `/connector-jobs/vendors/stavvy/configurations` #### Store Stavvy Credentials For Brands `storeStavvyCredentialsForBrands` Store Stavvy Credentials For Brand Store Stavvy Credentials For Brands API is used to store Stavvy credentials for brands. You can use this API to securely manage credentials for multiple brands in a single environment. Each brand configuration is identified using a unique brand identifier. To ensure proper identification, the "partner_configuration_id" should be unique and follow the pattern: "stavvy-brand-BRAND_IDENTIFIER". Show the rest #### Example Input: ``` { "partner_configuration_id": "stavvy-brand-BRAND_IDENTIFIER", "partner_configuration": { "partner_configuration": { "company_connections": [ { "@id": "company_connection_id", "@type": "company_connection", "has_client_identifier": { "has_value": "STAVVY_CLIENT_ID" }, "has_client_secret_value": { "has_value": "STAVVY_CLIENT_SECRET" }, "has_token_url": { "has_value": "STAVVY_TOKEN_URL" }, "has_token_audience": { "has_value": "STAVVY_TOKEN_AUDIENCE" }, "has_main_url": { "has_value": "STAVVY_MAIN_URL" } } ] } } } ``` #### Success Response: If successful, the API responds with a status code of 201 Created and provides the unique identifier for the partner configuration: ``` { "partner_configuration_id": "stavvy-brand-BRAND_IDENTIFIER" } ``` Note: You can use the same "@id" value for multiple executions, and the "@type" value should always be "company_connection". ##### Request application/json Copy ``` { "partner_configuration_id": "-brand-test", "partner_configuration": { "partner_configuration": { "company_connections": [ { "@id": "01H8HBR6NESARDAYMP7V5DZZHM", "@type": "company_connection", "has_client_identifier": { "has_value": "test" }, "has_client_secret_value": { "has_value": "test" }, "has_token_url": { "has_value": "test" }, "has_token_audience": { "has_value": "test" }, "has_main_url": { "has_value": "test" } } ] } } } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `partner_configuration_id` | `string` | Unique identifier for the partner configuration | | `partner_configuration` | `object` | Partner configuration object | | `partner_configuration` | `object` | Main configuration for the partner | | `company_connections` | `object[]` | Company connections array | | `@id` | `string` | Unique identifier for the company connection | | `@type` | `string` | Type of the connection (company connection)`company_connection` | | `has_client_identifier` | `object` | The client identifier for the connection | | `has_client_secret_value` | `object` | The client secret for the connection | | `has_token_url` | `object` | The token URL for the connection | | `has_token_audience` | `object` | The token audience for the connection | | `has_main_url` | `object` | The main URL for the connection | ##### Response `201``application/json` 1 fields Configuration created successfully | Field | Type | Description | | --- | --- | --- | | `partner_configuration_id` | `string` | Partner configuration identifier | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/notary/input/selection` #### Retrieve Selected Input Source `retrieveSelectedInputSource` Retrieve Selected Input Source API can be used to retrieve selected input source for Notary process. Available sources: - docutech - encompass ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 2 fields Successfully switched input source | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | | `input_source` | `string` | Input Source`docutech``encompass` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `GET` `/connector-jobs/vendors/stavvy/configurations` #### Retrieve Stavvy Credentials For Brands `retrieveStavvyCredentialsForBrands` This API allows you to retrieve Stavvy configurations for brands. The retrieved data includes partner configuration IDs that have the "brand identifier" as a suffix. #### Example Response: ``` { "page": { "next_token": null, "count": 1 }, "product_name": null, "partner_configurations": [ { "partner_configuration_id": "stavvy-brand-1" } ], "vendor_name": "stavvy" } ``` ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Response `200``application/json` 4 fields Stavvy configurations retrieved successfully | Field | Type | Description | | --- | --- | --- | | `page` | `object` | Page information | | `next_token` | `string` | Next token information | | `count`required | `integer` | Count information | | `product_name` | `string` | Product name information | | `partner_configurations` | `object[]` | Partner configurations array | | `partner_configuration_id` | `string` | Partner configuration identifier | | `vendor_name` | `string` | Vendor name information | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | `DELETE` `/notary/brands/{configuration_id}` #### Delete Stavvy Credential For Brands `deleteStavvyCredentialForBrands` The Delete Stavvy Configuration API provides the capability to remove a Stavvy configuration associated with a specific brand. To use this API, specify the unique configuration ID of the Stavvy configuration you wish to delete. Each brand's configuration is uniquely identified by a configuration ID. #### Configuration ID: The `configuration_id` parameter represents the unique identifier of the Stavvy configuration you want to delete. This ID is crucial for pinpointing the specific configuration to be removed. ##### Response 400422 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `configuration_id` required | `string` path | `-brand-1` | Configuration identifier | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Other responses `204` ### Platform `POST` `/transactions` #### Create Transaction `create_transaction` 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 | | ##### Request application/json Copy ``` { "label": "first_transaction" } ``` ##### Response 201400403 application/json Copy Transaction have been created ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` 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" } ``` ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `callback_url` | `string (url)` | URL for receiving events about changes inside transaction | | `label` | `string` | Transaction label | ##### Response `201``application/json` 2 fields Transaction have been created | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | `POST` `/transactions/{transaction_id}/collections` #### Create Collection `create_collection` ##### Request 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" } } ] } } ``` ##### Response 201400403404 GetProduct404 text/html 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" } } ] } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` 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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | Collection data | | `metadata` | `object` | Collection metadata. Maximum allowable length of the dumped json object - 400 000 symbols. | | `version` | `integer` | Version of staircase language with what collection has been created.`0``2` | | `validation` | `boolean` | Flag that enables validation | | `linked_collections` | `object[]` | List of linked collections | | `collection_id` | `string (ulid)` | Collection ID of linked collection | | `label` | `string` | Label of linked collection | ##### Response `201``application/json` 4 fields 201 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `get_collections` 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 ##### Response 400404 GetProduct404 text/html application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` ##### Parameters 5 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `filter` | `string` query | `collection_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51` | Filter expression in format {field_name}+{operation}+{value} | | `sort` | `string` query | `asc` | Order of sorting | | `limit` | `number` query | `5` | Amount of items to show | | `after_id` | `string` query | `01EZQ32PJQGKRA6HR8D72Q9FFF` | id of last evaluated transaction | ##### Response `200``application/json` 4 fields 200 response | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `422``application/json` 2 fields Unprocessable Entity | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | | `collections` | `object[]` | List of collections without 'data' field and with links to retrieve single collections. | | `transaction_id` | `string (ulid)` | Transaction id | | `collection_id` | `string (ulid)` | Collection id | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema Maximum allowable length of the dumped json object - 400 000 symbols. | | `_links` | `object` | Links | | `collection` | `string (url)` | Link to retrieve full collection. | `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `get_collection` ##### Response 200400403404 GetProduct404 text/html422 application/json Copy 200 response ``` { "transaction_id": "01FJCADX5QEXEDVRWNXAK206MA", "collection_id": "01FJCAQW7EYJAA6FY05WRKRM3T", "metadata": { "version": 2 }, "data": { "contact_point_emails": [ { "@id": "01GK25GGSH00VWJ3RY6K1XCHTH", "@type": "contact_point_email", "has_contact_point_email_value": { "has_value": "jdoe@exampleemail.com" } } ], "contact_points": [ { "@id": "01GK25GGSH9EZFR92CC5QMGFR7", "@type": "contact_point", "with_contact_point_email": [ "01GK25GGSH00VWJ3RY6K1XCHTH" ] } ], "documents": [ { "@type": "document", "@id": "18566", "has_document_name": { "has_value": "Closing Disclosure (John Doe)" }, "has_staircase_blob_identifier": { "has_value": "01GK25FYZ868JHCPXSHDP74J0E" } } ], "page_extraction_metadata": [ { "@id": "01GK25GGSH4BPPE0K1JBA5JAW4", "@type": "page_extraction_metadata", "has_page_number": { "has_value": "5" } } ], "people": [ { "@type": "person", "@id": "Borrower1", "with_contact_point": [ "01GK25GGSH9EZFR92CC5QMGFR7" ], "with_signature": [ "SignerSignature1" ] } ], "property_extraction_metadata": [ { "@id": "01GK25GGSH25569942YTGNXSX6", "@type": "property_extraction_metadata", "has_bounding_box_height_ratio": { "has_value": "10" }, "has_bounding_box_left_ratio": { "has_value": "256.1" }, "has_bounding_box_top_ratio": { "has_value": "188.56" }, "has_bounding_box_width_ratio": { "has_value": "40.68" } }, { "@id": "01GK25GGSH7RVP88650D8MAGYT", "@type": "property_extraction_metadata", "has_bounding_box_height_ratio": { "has_value": "15.4" }, "has_bounding_box_left_ratio": { "has_value": "28.8" }, "has_bounding_box_top_ratio": { "has_value": "186.06" }, "has_bounding_box_width_ratio": { "has_value": "194.04" } } ], "signatures": [ { "@type": "signature", "@id": "SignerSignature1", "has_signature_date": { "has_value": "", "with_data_extraction_metadata": [ "01GK25GGSH25569942YTGNXSX6" ] }, "has_signed_indicator": { "has_value": false, "with_data_extraction_metadata": [ "01GK25GGSH7RVP88650D8MAGYT" ] }, "with_page_extraction_metadata": [ "01GK25GGSH4BPPE0K1JBA5JAW4" ] } ] } } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` 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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Unprocessable entity 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" } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | Transaction ID | | `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | Collection ID | | `refs` | `boolean` query | `true` | If `true`, refs will not be resolved | | `flatten` | `boolean` query | `true` | If `true`, the collection will be flattened | ##### Response `200``application/json` 1 fields 200 response | Field | Type | Description | | --- | --- | --- | | `people` | `object[]` | People information | | `@id` | `string` | ID information | | `@type` | `string` | Type information | | `with_contact_point` | `string[]` | Contact point information | | `with_signature` | `string[]` | Signature information | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `422``application/json` 1 fields Unprocessable entity error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ### Operations `POST` `/` #### Create eNotary `post-enotary` Create eNotary invokes a data partner for eNotary. Data partners: HelloSign Notarize, HelloFax, DocuSign, NotaryCam, eOriginal, Escrow Tab, Nexsys, OneSpan ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy eNotary request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields eNotary request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ##### Other responses `400``404` ## Providers - Stavvy ## Errors `400``403``404``422``500` ## More in Contract - Previous product: Lexicon - Next product: Price --- # Price # Price Best-execution rate and price selection: the eligible-product search across amortisation terms, and the candidate closest to par. A caller sends the loan characteristics and the borrower's credit profile. The product runs the eligible-product search against the pricing engine and returns the selected product with its rate, price, investor and identifier. The search runs three times, once per amortisation term — thirty-year fixed, fifteen-year fixed, and thirty-year adjustable — so a caller sees the choice across terms rather than a single quote. ## How it works Selection rule, as recorded: for each term, take the product closest to par whose price is above par. That is a stated rule rather than a scoring model, which is what makes a quote reproducible from the inputs. Several inputs the engine needs are derived rather than asked for. Debt-to-income is computed from the liability and income totals already on the file, and state and county are derived from the postal code through a lookup rather than collected again. ## Operations ### Pricing `POST` `/bestexsearch` #### Best Execution Search `InvokePricingFlow` Invoke Best Pricing Flow The `Best Execution API` facilitates the retrieval of pricing details for the best execution product offered by lenders based on provided borrower and loan information. Additionally, it provides the ability to calculate monthly payments for various buydown options. #### API Input In order to run `Best Execution` below data is required in the request payload: - `partner_name`, supported partners: Show the rest - optimalBlue - `request_data`: You need to provide `people`, `properties`, `loans`, `incomes`, `credits` classes in your request collection, in addition each of these should have a relationship defined in the `relationships` list. Below is detailed explaination for the `request_data` attributes. People - `first_name` - (string) - The person's first name. - `last_name` - (string) - The person's last name. - `us_citizenship_status` - (boolean) - Whether the person is a US citizen. - `first_time_home_owner` - (boolean) - Whether the person is a first time homeowner. `Optional` - Default: True - `person_identifier` - (string) - The identifier for the person class. Properties - `purchase_price` - (string) - The property purchase price. - `property_type` - (string) - The property type. - Possible enum values `["SingleFamily", "Condo", "ManufacturedDoubleWide", "Condotel", "Modular", "PUD", "Timesharer", "ManufacturedSingleWide", "Coop", "NonWarrantableCondo", "Townhouse", "DetachedCondo"]` - `Optional`. Default: SingleFamily - `property_identifier` - (string) - The identifier for the property class. - `full_address_txt` - (string) - The property full address. - `county_name` - (string) - The property county. - `state_name` - (string) - The property state. - `postal_code` - (string) - The postal code. - `property_identifier` - (string) - The identifier for the property class. - `lien_type` - (string) - The property lien type. `Optional` - Default: "first" - `numberOfUnits` - (string) - The number of units. `Optional` - Default: OneUnit - `numberOfStories` - (integer) - The number of stories. `Optional` - Default: 1 Loans - `downpayment_amount` - (string) - The loan down payment amount. - `downpayment_percentage` - (string) - The loan down payment percentage. - `monthly_payment` - (integer) - The loan monthly payment value - `buydown_type` - (string) - The loan buydown method - Possible enum values `["ThreeTwoOne", "TwoOne", "OneZero", "None"]` - `loan_role_type` - (string) - The loan role type. - `loan_identifier` - (string) - The identifier for the loan class. - `loan_type` - (string) - The loan type. `Optional` Default: conventional - `loan_purpose` - (string) - The loan purpose. `Optional` Default: purchase - `interest_only` - (boolean) - Whether it's interest only. `Optional` Default: True - `prepayment_penalty` - (string) - The prepayment penalty. `Optional` Default: None - `borrower_paid_mi` - (boolean) - Whether the borrower paid the mortgage insurance. `Optional` Default: False - `amortization_type` - (string) - The loan amortization type. `Optional` Default: Fixed - `loan_terms` - (string) - The terms of the loan. `Optional` Default: ThirtyYear Incomes - `annual_income` - (integer) - The annual income value for a person. - `income_identifier` - (string) - The identifier for the income class. Credits - `credit_score` - (integer) - The credit score for a person. - `credit_identifier` - (string) - The identifier for the credit class. Lease - `lease_identifier` - (string) - The identifier for the lease class. - `monthly_rate` - (number) - The monthly rate of the lease. Rents - `rent_identifier` - (string) - The identifier for the rent class. - `monthly_rate` - (number) - The monthly rate of the rent. Automobiles - `automobile_identifier` - (string) - The identifier for the automobile class. - `automobile_type` - (string) - The automobile type. Relationships - `@type` - (string) - The identifier of the relationship class. Possible enum `["finance_relation", "person_credit", "person_income"]` - Attributes required will vary according to `@type`. If `@type` is `finance_relation`, below are the attributes required: - `has_person` - (string) - The identifier for the people class. - `has_loan` - (string) - The identifier for the loans class. - `has_property` - (string) - The identifier for the properties class. - `has_rent` - (string) - The identifier for the rents class. - `has_lease` - (string) - The identifier for the lease class. - `has_automobile` - (string) - The identifier for the automobiles class. - `main_applicant` - (boolean) - Whether the person is the main applicant. - If `@type` is `person_income`, below are the attributes required: - `has_income` - (string) - The identifier for the incomes class. - `has_person` - (string) - The identifier for the people class. - If `@type` is `person_credit`, below are the attributes required: - `has_credit` - (string) - The identifier for the credit class. - `has_person` - (string) - The identifier for the person class. - `callback_url`: If you don't want to continuously poll the result, you can provide a callback_url in request body. Once the invocation is completed, response content will be posted to this endpoint. Note: All relationships between classes need to be defined and present in the `relationships` list. If this is not the case the API may encounter issues getting the correct price. In case of invalid request data, you will receive `400` status code with information about missing fields. #### Running Best Execution API API can run in two modes: - Real Call: In the case of a Real Partner Call, an actual call will be made to the partner. Prior to making this call, it is necessary to call Setup Partner Configurations API through this link. Please note that Staircase and Partners may apply charges for this service. - Mock Call: The API will return a mock partner response without making a real call in the case of a mock scenario. To return the corresponding response for each scenario, the API will use the `People[*].ssn` field. However, if any other SSN values are used in the call, the API will switch to Real Partner Call Mode. ###### Mock Scenarios Examples If you want to test the system and see possible pricing results without invoking partners you can do mock request instead. Create payload as described in Request Payload section above but add `ssn` field to the person with following values: | SSN | Buydown Type | Mock Scenario | | --- | --- | --- | | 000000001 | ThreeTwoOne | ThreeTwoOne Buydown Response | | 000000001 | TwoOne | TwoOne Buydown Response | | 000000001 | OneZero | OneZero Buydown Response | | 000000001 | None | All three buydown options Response | | 999000011 | None | Error Scenario | #### API Response - Once `Best Execution` results are available, the results will be returned on the Webhook URL with the status and response_data, below are the details of the `response_data` from the `best_execution` API Pricing Schemas - `pricing_schema_identifier` - (string) - The pricing schema class identifier. - `apr` - (number) - The pricing schemas annual percentage rate. - `rebate` - (number) - The pricing schemas rebate. - `discount` - (number) - The pricing schemas discount. - `closing_cost` - (number) - The pricing schemas closing cost. - `monthly_insurance` - (number) - The pricing schemas monthly insurance value. - `total_monthly_payment` - (number) - The pricing schemas total monthly payment amount. - `rate` - (number) - The pricing schemas rate. - `price` - (number) - The pricing schemas price. - `principal_and_interest` - (number) - The pricing schemas principal and interest amount. - `first_year_monthly_payment` - (number) - The pricing schemas first year monthly payment amount. Calculated based on the buy down option provided in the request. - `second_year_monthly_payment` - (number) - The pricing schemas second year monthly payment amount. Calculated based on the buy down option provided in the request. - `third_year_monthly_payment` - (number) - The pricing schemas third year monthly payment amount. Calculated based on the buy down option provided in the request. - `piti` - (number) - The pricing schemas principal, interest, taxes and insurance amount. Calculated based on the values in the response. Loans - `loan_identifier` - (string) - The loan class identifier. - `buydown_type` - (string) - The loan buy down option. One of `['ThreeTwoOne', 'TwoOne', 'OneZero' or 'None']`. - `ltv_value` - (number) - The loan to value ratio. - `dti_value` - (number) - The loan debt to income ratio. Mortgage Plans - `plan_identifier` - (string) - The mortgage plan class identifier. - `amortization_term` - (string) - The mortgage plan amortization term in years. - `name` - (string) - The mortgage plan name. - `code` - (string) - The mortgage plan code. Relationships - `has_pricing_schema` - (string) - The pricing schema class identifier. - `has_loan` - (string) - The loan class identifier. - `has_mortgage_plan` - (string) - The mortgage plan class identifier. Moreover, the system provides an API to get the status, you can use it using this link to get the data at any time. ##### Request Mock Request ThreeTwoOneMock Request TwoOneMock Request OneZeroMock Request Three BuydownsMock Request Error ScenarioPrice Request Single ApplicantPrice Request Multiple ApplicantsPrice Request With `Optional` FieldsPrice Request With callback URL application/json Copy ``` { "partner_name": "optimalBlue", "callback_url": "callback.url", "request_data": { "people": [ { "first_name": "John", "last_name": "Smith", "ssn": "000000001", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 10000000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Main Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "20191" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 200000, "downpayment_percentage": 10, "buydown_type": "ThreeTwoOne" } ], "incomes": [ { "annual_income": 120000, "monthly_rent": 800, "monthly_debt_payment": 400, "monthly_car_payment": 200, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 700, "credit_identifier": "credit_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_income": "income_1", "has_person": "person_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "optimalBlue", "request_data": { "people": [ { "first_name": "John", "last_name": "Smith", "ssn": "000000001", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 10000000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Main Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "20191" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 200000, "downpayment_percentage": 10, "buydown_type": "TwoOne" } ], "incomes": [ { "annual_income": 120000, "monthly_rent": 800, "monthly_debt_payment": 400, "monthly_car_payment": 200, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 700, "credit_identifier": "credit_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_income": "income_1", "has_person": "person_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "optimalBlue", "request_data": { "people": [ { "first_name": "John", "last_name": "Smith", "ssn": "000000001", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 10000000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Main Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "20191" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 200000, "downpayment_percentage": 10, "buydown_type": "OneZero" } ], "incomes": [ { "annual_income": 120000, "monthly_rent": 800, "monthly_debt_payment": 400, "monthly_car_payment": 200, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 700, "credit_identifier": "credit_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_income": "income_1", "has_person": "person_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "optimalBlue", "request_data": { "people": [ { "first_name": "John", "last_name": "Smith", "ssn": "000000001", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 10000000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Main Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "20191" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 200000, "downpayment_percentage": 10, "buydown_type": "None" } ], "incomes": [ { "annual_income": 120000, "monthly_rent": 800, "monthly_debt_payment": 400, "monthly_car_payment": 200, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 700, "credit_identifier": "credit_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_income": "income_1", "has_person": "person_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "optimalBlue", "request_data": { "people": [ { "first_name": "John", "last_name": "Smith", "ssn": "999000011", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 10000000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Main Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "20191" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 200000, "downpayment_percentage": 10, "buydown_type": "ThreeTwoOne" } ], "incomes": [ { "annual_income": 120000, "monthly_rent": 800, "monthly_debt_payment": 400, "monthly_car_payment": 200, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 700, "credit_identifier": "credit_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_income": "income_1", "has_person": "person_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "partner_name", "request_data": { "people": [ { "first_name": "Andy", "last_name": "America", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 150000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Made Up Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "12345" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 20000, "downpayment_percentage": 14, "buydown_type": "ThreeTwoOne", "loan_role_type": "subject_loan" } ], "incomes": [ { "annual_income": 75000, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 750, "credit_identifier": "credit_1" } ], "rents": [ { "rent_identifier": "rent_1", "monthly_rate": 1000 } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_person": "person_1", "has_income": "income_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "partner_name", "request_data": { "people": [ { "first_name": "Andy", "last_name": "America", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true }, { "first_name": "Amy", "last_name": "America", "person_identifier": "person_2" } ], "properties": [ { "purchase_price": 250000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Made Up Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "12345" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 20000, "downpayment_percentage": 8, "buydown_type": "OneZero", "loan_role_type": "subject_loan" } ], "incomes": [ { "annual_income": 150000, "income_identifier": "income_1" }, { "annual_income": 75000, "income_identifier": "income_2" } ], "credits": [ { "credit_score": 750, "credit_identifier": "credit_1" }, { "credit_score": 625, "credit_identifier": "credit_2" } ], "lease": [ { "monthly_rate": 7500, "lease_identifier": "lease_1" } ], "automobile": [ { "automobile_identifier": "automobile_1" } ], "rent": [ { "monthly_rate": 2500, "rent_identifier": "rent_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "finance_relation", "has_person": "person_2", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": false }, { "@type": "finance_relation", "has_person": "person_1", "has_leas": "lease_1", "has_property": "automobile_1" }, { "@type": "person_income", "has_person": "person_1", "has_income": "income_1" }, { "@type": "person_income", "has_person": "person_2", "has_income": "income_2" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" }, { "@type": "person_credit", "has_credit": "credit_2", "has_person": "person_2" } ] } } ``` application/json Copy ``` { "partner_name": "partner_name", "request_data": { "people": [ { "first_name": "Andy", "last_name": "America", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 150000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Made Up Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "12345", "lien_type": "First", "numberOfUnits": "OneUnit", "numberOfStories": 1, "propertyType": "SingleFamily" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 20000, "downpayment_percentage": 14, "buydown_type": "ThreeTwoOne", "loan_role_type": "subject_loan", "loan_type": "Conventional", "loan_purpose": "Purchase", "interest_only": false, "prepayment_penalty": "None", "borrower_paid_mi": true, "amortization_type": "Fixed", "loan_terms": "FifteenYear" } ], "incomes": [ { "annual_income": 75000, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 750, "credit_identifier": "credit_1" } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_person": "person_1", "has_income": "income_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` application/json Copy ``` { "partner_name": "partner_name", "callback_url": "callback.url", "request_data": { "people": [ { "first_name": "Andy", "last_name": "America", "us_citizenship_status": true, "person_identifier": "person_1", "first_time_home_owner": true } ], "properties": [ { "purchase_price": 150000, "property_type": "PrimaryResidence", "property_identifier": "property_1", "full_address_txt": "123 Made Up Street", "county_name": "FAIRFAX", "state_name": "VA", "postal_code": "12345" } ], "loans": [ { "loan_identifier": "loan_1", "downpayment_amount": 20000, "downpayment_percentage": 14, "buydown_type": "ThreeTwoOne", "loan_role_type": "subject_loan" } ], "incomes": [ { "annual_income": 75000, "income_identifier": "income_1" } ], "credits": [ { "credit_score": 750, "credit_identifier": "credit_1" } ], "rents": [ { "rent_identifier": "rent_1", "monthly_rate": 1000 } ], "relationships": [ { "@type": "finance_relation", "has_person": "person_1", "has_loan": "loan_1", "has_property": "property_1", "main_applicant": true }, { "@type": "person_income", "has_person": "person_1", "has_income": "income_1" }, { "@type": "person_credit", "has_credit": "credit_1", "has_person": "person_1" } ] } } ``` ##### Response 201400403404500 application/json Copy Successfully started flow invocation. ``` { "response_id": "01F6NAQ4894HPMCBGB4P0G78HG" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `partner_name`required | `string` | Partner name.Example `optimalBlue` | | `callback_url` | `string` | Callback urlExample `callback.url` | | `request_data`required | `object` | Request data for Pricing. | | `people`required | `object[]` | List of persons. | | `first_name`required | `string` | Persons first name. | | `last_name`required | `string` | Persons last name. | | `ssn` | `string` | Persons taxpayer number identifier. | | `us_citizenship_status`required | `boolean` | Whether person is US citizen. | | `person_identifier`required | `string` | Person class identifier. | | `first_time_home_owner`required | `boolean` | Whether person is a first time homeowner. | | `properties`required | `object[]` | List of properties. | | `purchase_price`required | `integer` | Property purchase price. | | `property_type`required | `string` | Property type. | | `property_identifier`required | `string` | Property class identifier. | | `full_address_txt`required | `string` | Property full address. | | `county_name`required | `string` | Property county name. | | `state_name`required | `string` | Property state name. | | `postal_code`required | `string` | Property state code. | | `lien_type` | `string` | Property lien type. | | `loans`required | `object[]` | List of loans. | | `loan_identifier`required | `string` | Loan class identifier. | | `downpayment_amount`required | `integer` | Loan down payment amount. | | `downpayment_percentage`required | `integer` | Loan down payment percentage. | | `buydown_type`required | `string` | Loan buydown. | | `amortization_type` | `string` | Loan amortization type. | | `borrower_paid_mi` | `boolean` | Whether the borrower paid mortgage insurance. | | `buydown_amount` | `integer` | Loan buydown amount. | | `loan_amount` | `integer` | Loan amount. | | `loan_purpose` | `string` | Loan purpose. | | `loan_type` | `string` | Loan type. | | `monthly_payment` | `number` | Loan monthly payment. | | `incomes`required | `object[]` | List of incomes. | | `annual_income`required | `integer` | Annual Income amount. | | `income_identifier`required | `string` | Income class identifier. | | `credits`required | `object[]` | List of credits. | | `credit_score`required | `integer` | Credit score value. | | `credit_identifier`required | `string` | Credit class identifier. | | `lease` | `object[]` | List of leases. | | `lease_identifier`required | `string` | Lease class identifier. | | `monthly_rate`required | `number` | The monthly rate of the lease. | | `automobiles` | `object[]` | List of automobiles | | `automobile_identifier`required | `string` | Automobile class identifier. | | `automobile_type` | `string` | Automobile type. | | `rents` | `object[]` | List of rents | | `rent_identifier`required | `string` | Rent class identifier. | | `monthly_rate`required | `number` | Monthly rate of the rent. | | `relationships`required | `object[]` | List of financial relations. | | `@type` | `string` | The relationship types. Can be one of finance_relation, person_income, person_credit. | | `has_income` | `string` | Income class identifier. | | `has_person` | `string` | Person class identifier. | | `has_credit` | `string` | Credit class identifier. | | `has_loan` | `string` | Loan class identifier. | | `has_property` | `string` | Property class identifier. | | `has_rent` | `string` | Rent class identifier | | `has_lease` | `string` | Lease class identifier | | `has_automobile` | `string` | Automobile class identifier | | `has_mortgage` | `string` | Mortgage class identifier | | `main_applicant` | `boolean` | Whether the person is the main applicant. | ##### Response `201``application/json` 1 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `response_id`required | `string` | Response collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/bestexsearch/{id}` #### Retrieve Status `RetrievePricingFlowStatus` Retrieve Pricing Status Retrieves the result of running Pricing process. The status of the process can be found in `metadata` `invocation_status` once the status is `COMPLETED` the Pricing data will be stored in the `data` object. If something fails an error message with further details will be stored in the `data` object. #### Response Payload This endpoint returns the following response object: Show the rest Pricing Schemas - `pricing_schema_identifier` - (string) - The pricing schema class identifier. - `apr` - (number) - The pricing schemas annual percentage rate. - `rebate` - (number) - The pricing schemas rebate. - `discount` - (number) - The pricing schemas discount. - `closing_cost` - (number) - The pricing schemas closing cost. - `monthly_insurance` - (number) - The pricing schemas monthly insurance value. - `total_monthly_payment` - (number) - The pricing schemas total monthly payment amount. - `rate` - (number) - The pricing schemas rate. - `price` - (number) - The pricing schemas price. - `principal_and_interest` - (number) - The pricing schemas principal and interest amount. - `first_year_monthly_payment` - (number) - The pricing schemas first year monthly payment amount. Calculated based on the buy down option provided in the request. - `second_year_monthly_payment` - (number) - The pricing schemas second year monthly payment amount. Calculated based on the buy down option provided in the request. - `third_year_monthly_payment` - (number) - The pricing schemas third year monthly payment amount. Calculated based on the buy down option provided in the request. - `piti` - (number) - The pricing schemas principal, interest, taxes and insurance amount. Calculated based on the values in the response. Loans - `loan_identifier` - (string) - The loan class identifier. - `buydown_type` - (string) - The loan buy down option. One of 'ThreeTwoOne', 'TwoOne' or 'OneZero'. - `ltv_value` - (number) - The loan to value ratio. - `dti_value` - (number) - The loan debt to income ratio. Mortgage Plans - `plan_identifier` - (string) - The mortgage plan class identifier. - `amortization_term` - (string) - The mortgage plan amortization term in years. - `name` - (string) - The mortgage plan name. - `code` - (string) - The mortgage plan code. Relationships - `has_pricing_schema` - (string) - The pricing schema class identifier. - `has_loan` - (string) - The loan class identifier. - `has_mortgage_plan` - (string) - The mortgage plan class identifier. Any warning, errors or unwanted behavior will be shown in the error objects: Errors - `error_id` - (string) - The error class identifier. - `error_message` - (string) - The error message. - `error_timestamp` - (string) - The error timestamp. - `error_type` - (string) - The error type. Enum `["AuthenticationError" , "AuthorizationError" , "ConfigurationError" , "DependencyError" , "LogicError" , "NetworkError" , "ResourceError" , "RuntimeError" , "SyntaxError" , "TimeoutError" , "ValidationError"]` - `severity_level` - (string) - The error severity level. Enum `["Critical", "High", "Low", "Medium", "Warning"]` ##### Response 200 Success Status Example200 Error Status Example200 Failed Status Examlpe400403404500 application/json Copy Successfully returned result of the Asset Verification. ``` { "transaction_id": "01GT91JJRFRV60T4TTEMXFZMWE", "collection_id": "01GT91JJZRZ5ZNP7Y6V63527T7", "metadata": { "validation": false, "serialise_to_graph": false, "created_at": "2023-03-27T11:14:48.118327-04:00", "invocation_status": "COMPLETED", "last_updated_at": "2023-03-27T11:14:51.943421-04:00", "partner_name": "optimalBlue", "product_invocation_id": "01GWHT5PNPJA3JE0BT1DY3H24H", "product_name": "Price" }, "data": { "relationships": [ { "@id": "mortgage_application_1", "@type": "mortgage_application", "has_pricing_schema": "pricing_schema_1", "has_loan": "loan_1", "has_mortgage_plan": "plan_1" } ], "mortgage_plans": [ { "@id": "mortgage_plan_1", "@type": "mortgage_plan", "code": "53040066", "name": "Fixed 30 years", "plan_identifier": "plan_1", "amortization_term": "30" } ], "loans": [ { "@id": "loan_1", "@type": "loan", "loan_identifier": "loan_1", "ltv_value": 80, "dti_value": 54 } ], "pricing_schemas": [ { "@id": "pricing_schema_1", "@type": "pricing_schema", "rebate": 0, "discount": 0, "first_year_monthly_payment": 1104.93, "second_year_monthly_payment": 1029.61, "third_year_monthly_payment": 957.59, "closing_cost": 0, "monthly_insurance": 0, "total_monthly_payment": 1719.37, "rate": 10, "price": 100, "principal_and_interest": 1719, "piti": 1430.22, "apr": 10.24, "pricing_schema_identifier": "pricing_schema_1" } ] } } ``` application/json Copy Successfully returned result of the Asset Verification. ``` { "transaction_id": "01GT91JJRFRV60T4TTEMXFZMWE", "collection_id": "01GT91JJZRZ5ZNP7Y6V63527T7", "metadata": { "validation": false, "serialise_to_graph": false, "created_at": "2023-03-27T11:14:48.118327-04:00", "invocation_status": "COMPLETED", "last_updated_at": "2023-03-27T11:14:51.943421-04:00", "partner_name": "optimalBlue", "product_invocation_id": "01GWHT5PNPJA3JE0BT1DY3H24H", "product_name": "Price" }, "data": { "errors": [ { "@id": "error_1", "@type": "error", "error_id": "error_1", "error_message": "Error message", "error_timestamp": "2023-03-30T11:57:17.670361-04:00", "error_type": "ValidationError", "severity_level": "Warning" }, { "@id": "error_2", "@type": "error", "error_id": "error_2", "error_message": "Error message", "error_timestamp": "2023-03-30T11:57:17.670361-04:00", "error_type": "ValidationError", "severity_level": "Warning" } ] } } ``` application/json Copy Successfully returned result of the Asset Verification. ``` { "transaction_id": "01GT91JJRFRV60T4TTEMXFZMWE", "collection_id": "01GT91JJZRZ5ZNP7Y6V63527T7", "metadata": { "validation": false, "serialise_to_graph": false, "created_at": "2023-03-27T11:14:48.118327-04:00", "invocation_status": "FAILED", "last_updated_at": "2023-03-27T11:14:51.943421-04:00", "partner_name": "optimalBlue", "product_invocation_id": "01GWHT5PNPJA3JE0BT1DY3H24H", "product_name": "Price" }, "data": { "errors": [ { "@id": "error_1", "@type": "error", "error_id": "error_1", "error_message": "Something went wrong!", "error_timestamp": "2023-03-30T11:57:17.670361-04:00", "error_type": "ProducError", "severity_level": "Critical" } ] } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` 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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` 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" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `id` required | `string (Staircase Response Collection Identifier)` path | `01FFMHWSS346W9V6HZVGSEZPQ` | Pricing ID | ##### Response `200``application/json` 4 fields Successfully returned result of the Asset Verification. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Pricing Data in Staircase lexicon schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `product_name` | `string` | Product nameExample `asset` | | `partner_name` | `string` | Partner nameExample `equifax` | | `created_at` | `string` | Time of creation | | `last_updated_at` | `string` | Time of last update | | `invocation_status` | `string` | Status of the Asset Verification.`COMPLETED``FAILED``RUNNING``STARTED` | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Workflow `POST` `/products/pricing/invocations` #### Invoke Product Flow `InvokeSpecificProductFlow` This product receives all detailed pricing information for a product. The response will return all price, rate, lock period combinations for the requested product. Note: Pricing product has a dependency to the Options Product. You need to invoke Options to search for possible loan options and then using the `mortgage_products` and one of the `loan_products` fields returned by the Options, you can retrieve pricing details of a Loan Product. Note: If you're using OptimalBlue as Partner, and invoke Pricing without invoking Options, you will not be able to retrieve `has_amortization_term_months_count` and `has_loan_amortization_type` fields. This is due to a limitation in the OptimalBlue API. ##### Request Flow Invocation with Collection IDPricing Details ExamplePricing Search ExamplePricing Search With Cash Out FilterPricing Search With Term FilterPricing Search With Discount Point Filter application/json Copy ``` { "product_flow_name": "OptimalBlue", "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4", "request_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN" } ``` application/json Copy ``` { "product_flow_name": "OptimalBlue", "request_data": { "loan_products": [ { "@type": "loan_product", "has_product_name": { "has_value": "NEW - 30 Year Fixed Conventional" }, "has_product_description_text": { "has_value": "" }, "has_product_identifier": { "has_value": "20290727" } } ], "mortgage_products": [ { "has_partner_product_name": { "has_value": "Product Detail" }, "has_partner_transaction_identifier": { "has_value": null }, "has_service_response_date": { "has_value": "2021-09-14T07:07:38.1847142Z" }, "has_partner_name": { "has_value": "Optimal Blue" }, "@type": "pricing" } ] } } ``` application/json Copy ``` { "product_flow_name": "OptimalBlue-BestSearch", "request_data": { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declarations", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_ballon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "string" }, "has_project_usage_type": { "has_value": "string" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } ``` application/json Copy ``` { "product_flow_name": "OptimalBlue-BestSearch", "request_data": { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": "01FDTQ5PKBF5JHM46TQQEE3SAE", "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "refinance" }, "has_refinance_type": { "has_value": "cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_rice_quote_request", "has_discount_points_percent": { "has_value": 0 }, "has_cash_out_amount": { "has_value": 10000 }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "false" }, "has_project_usage_type": { "has_value": "false" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "subject_property", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } ``` application/json Copy ``` { "product_flow_name": "OptimalBlue-BestSearch", "request_data": { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": "01FDTQ5PKBF5JHM46TQQEE3SAE", "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_rice_quote_request", "has_discount_points_percent": { "has_value": 0 }, "has_cash_out_amount": { "has_value": 0 }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "false" }, "has_project_usage_type": { "has_value": "false" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "subject_property", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ], "mortgage_products": [ { "@id": "01FDTQGB9JWTYPBP9NNEDC7F9M", "@type": "Options", "has_partner_name": { "has_value": "Optimal Blue" } } ] } } ``` application/json Copy ``` { "product_flow_name": "OptimalBlue-BestSearch", "request_data": { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": "01FDTQ5PKBF5JHM46TQQEE3SAE", "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_rice_quote_request", "has_discount_points_percent": { "has_value": 1 }, "has_cash_out_amount": { "has_value": 0 }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "false" }, "has_project_usage_type": { "has_value": "false" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "subject_property", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ], "mortgage_products": [ { "@id": "01FDTQGB9JWTYPBP9NNEDC7F9M", "@type": "Options", "has_partner_name": { "has_value": "Optimal Blue" } } ] } } ``` ##### Response 201400403404500 application/json Copy Successfully started flow invocation. ``` { "product_flow_name": "OptimalBlue", "metadata": {}, "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "STARTED", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD" } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `product_flow_name` | `string` | 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.`OptimalBlue``OptimalBlue-BestSearch``OptimalBlue-ProductDetails` | | `vendor_name` | `string` | Vendor name. Cannot be specified together with product_flow_name.`optimalBlue` | | `transaction_id` | `string` | Transaction ID used for invocation. | | `response_collection_id` | `string` | Response Collection ID. | | `callback_url` | `string (uri)` | Callback URL. | | `request_data` | `one of` | — | ##### Response `201``application/json` 7 fields Successfully started flow invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_id`required | `string` | Invocation ID. | | `invocation_status`required | `string` | The status of the invocation.`STARTED` | | `transaction_id`required | `string` | Transaction ID. | | `product_flow_name` | `string` | Product flow name.`OptimalBlue``OptimalBlue-BestSearch``OptimalBlue-ProductDetails` | | `metadata` | `object` | The metadata of the invoked product flow. | | `callback_url` | `string` | Callback URL. | | `request_data` | `object` | The data for the request collection. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/pricing/invocations/{invocation_id}` #### Retrieve Invocation Status `RetrieveProductFlowInvocationStatus` Retrieve status of a Product Flow Invocation Retrieves the status of running Product flow invocation. ##### Response 200400403404500 application/json Copy Successfully returned status of the Product flow Invocation. ``` { "request_collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "response_collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "metadata": {}, "invocation_id": "08f0f7bd-0158-4ab8-845c-f94eafa3859c", "invocation_status": "RUNNING", "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "product_flow_name": "OptimalBlue", "request_collection": { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": { "vendor_name": "optimalBlue", "request_data": { "people": [ { "@id": "01FDTQ5PJSKC94HHZGYZDSTXCT", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declaration": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ] } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ] } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_terms", "has_mortgage_type": { "has_value": "conventional" }, "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_discount_points_percent": { "has_value": 0 }, "has_include_balloon_loans_indicator": { "has_value": false }, "has_cash_out_amount": { "has_value": 0 }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "string" }, "has_financed_unit_count": { "has_value": 1 }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_stories_count": { "has_value": 1 }, "has_construction_method_type": { "has_value": "site_built" }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } }, "response_collection": { "metadata": { "created_at": "2021-09-14T03:36:45.193268-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHKS6W9J0JDTGTQJB9Y2RWB", "data": { "loans": [ { "@id": "01FT3Z7W06MJTDW8RY2ZKT48RY", "@type": "loan", "has_conforming_loan_indicator": { "has_value": true }, "has_borrower_requested_loan_amount": { "has_value": 150000 }, "has_loan_to_value_ltv_ratio_percent": { "has_value": 66.67 }, "has_combined_loan_to_value_cltv_ratio_percent": { "has_value": 0 }, "has_home_equity_combined_loan_to_value_hcltv_ratio_percent": { "has_value": 0 }, "with_closing_information": [ "01FT3Z7W84Z4G2P5XV66YT608A" ], "with_housing_expenses_deprecated": [ "01FT3Z7W9C9M8HXJ3Y7GZN71Y1" ], "with_fees": [ "01FT3Z7WAKRDFH04ZYH5VQY1NR" ], "with_arm_adjustment": [ "01FT3Z7WBAGCKPPS5ZDQFMVN69" ], "with_loan_terms": [ "01FT3Z7WCKCERY65RVCZGM9M02" ], "with_quote": [ "01FT3Z7WD9VSBBV7DVPPA8TEYK" ], "with_product": [ "01FT3Z7WEBGKEHFGB9S0JZTV30" ], "with_loan_product": [ "01FT3Z7WEBGKEHFGB9S0JZTV30" ] }, { "@id": "01FT3Z7W06421XRYA43QVBDYY9", "@type": "loan", "has_conforming_loan_indicator": { "has_value": true }, "has_borrower_requested_loan_amount": { "has_value": 150000 }, "has_loan_to_value_ltv_ratio_percent": { "has_value": 66.67 }, "has_combined_loan_to_value_cltv_ratio_percent": { "has_value": 0 }, "has_home_equity_combined_loan_to_value_hcltv_ratio_percent": { "has_value": 0 }, "with_closing_information": [ "01FT3Z7W843F0PCKCH1B51HWKX" ], "with_housing_expenses_deprecated": [ "01FT3Z7W9CF9G7FHZ3VM2CFYBQ" ], "with_fees": [ "01FT3Z7WAK4HRSPR7FPCX4Z2TG" ], "with_arm_adjustment": [ "01FT3Z7WBAR92NAQ6X929CHV5E" ], "with_loan_terms": [ "01FT3Z7WCKSFD5FEVY4SF2T1AE" ], "with_quote": [ "01FT3Z7WDACNHY76KECAXZ7J50" ], "with_product": [ "01FT3Z7WEBGKEHFGB9S0JZTV30" ], "with_loan_product": [ "01FT3Z7WEBGKEHFGB9S0JZTV30" ] } ], "closing_information": [ { "@id": "01FT3Z7W84Z4G2P5XV66YT608A", "@type": "closing_information", "has_total_closing_costs_amount": { "has_value": 14340 } }, { "@id": "01FT3Z7W843F0PCKCH1B51HWKX", "@type": "closing_information", "has_total_closing_costs_amount": { "has_value": 12840 } } ], "housing_expenses_deprecated": [ { "@id": "01FT3Z7W9C9M8HXJ3Y7GZN71Y1", "@type": "housing_expenses_deprecated", "has_proposed_first_mortgage_principal_and_interest_monthly_amount": { "has_value": 536 }, "has_proposed_mortgage_insurance_monthly_amount": { "has_value": 0 }, "has_proposed_first_mortgage_principal_interest_taxes_and_insurance_piti_monthly_amount": { "has_value": 535.87 } }, { "@id": "01FT3Z7W9CF9G7FHZ3VM2CFYBQ", "@type": "housing_expenses_deprecated", "has_proposed_first_mortgage_principal_and_interest_monthly_amount": { "has_value": 545 }, "has_proposed_mortgage_insurance_monthly_amount": { "has_value": 0 }, "has_proposed_first_mortgage_principal_interest_taxes_and_insurance_piti_monthly_amount": { "has_value": 545.1 } } ], "arm_adjustments": [ { "@id": "01FT3Z7WBAGCKPPS5ZDQFMVN69", "@type": "arm_adjustment", "has_margin_rate_percent": { "has_value": 0 } }, { "@id": "01FT3Z7WBAR92NAQ6X929CHV5E", "@type": "arm_adjustment", "has_margin_rate_percent": { "has_value": 0 } } ], "loan_terms": [ { "@id": "01FT3Z7WCKCERY65RVCZGM9M02", "@type": "loan_terms", "has_note_rate_percent": { "has_value": 1.75 }, "has_loan_amortization_term_type": { "has_value": "monthly" }, "has_loan_amortization_type": { "has_value": "fixed_rate" } }, { "@id": "01FT3Z7WCKSFD5FEVY4SF2T1AE", "@type": "loan_terms", "has_note_rate_percent": { "has_value": 1.875 }, "has_loan_amortization_term_type": { "has_value": "monthly" }, "has_loan_amortization_type": { "has_value": "fixed_rate" } } ], "quotes": [ { "@id": "01FT3Z7WD9VSBBV7DVPPA8TEYK", "@type": "loan_price_quote", "has_loan_price_lock_duration_days_count": { "has_value": 30 }, "has_loan_price_lock_expiration_date": { "has_value": "2022-02-22 00:00:00" }, "has_loan_price_percent": { "has_value": 91.625 }, "has_discount_points_amount": { "has_value": 12563 }, "has_discount_points_percent": { "has_value": 8.375 }, "has_rebate_amount": { "has_value": 0 }, "has_rebate_percent": { "has_value": 0 }, "has_total_credit_amount": { "has_value": 0 } }, { "@id": "01FT3Z7WDACNHY76KECAXZ7J50", "@type": "loan_price_quote", "has_loan_price_lock_duration_days_count": { "has_value": 30 }, "has_loan_price_lock_expiration_date": { "has_value": "2022-02-22 00:00:00" }, "has_loan_price_percent": { "has_value": 92.625 }, "has_discount_points_amount": { "has_value": 11063 }, "has_discount_points_percent": { "has_value": 7.375 }, "has_rebate_amount": { "has_value": 0 }, "has_rebate_percent": { "has_value": 0 }, "has_total_credit_amount": { "has_value": 0 } } ], "loan_products": [ { "@id": "01FT3Z7WEBGKEHFGB9S0JZTV30", "@type": "loan_product", "has_product_identifier": { "has_value": "20290727" }, "has_product_name": { "has_value": "NEW - 30 Year Fixed Conventional" }, "has_total_loan_price_adjustment_percent": { "has_value": -0.25 }, "has_total_rate_adjustment_percent": { "has_value": 0 }, "has_total_margin_adjustment_percent": { "has_value": 0 }, "has_total_service_release_premium_srp_adjustment_percent": { "has_value": 3.72 }, "offered_by": [ "01FT3Z7XNTTFNMKYCW2A67DW32" ], "with_adjustment": [ "01FT3Z7XNWGT8N92SNKVNRF5ZH", "01FT3Z7XNWT625ENNXE4NVMM1V" ], "with_notes": [ "01FT3Z7XNYBNBPVQWZJG2X0F5E", "01FT3Z7XNYYNSK04SMVAWVCQK9", "01FT3Z7XNZMPHWEDYB2RSP987X" ], "with_price": [ "01FT3Z7XPEBMPC0MREMP90QMNV", "01FT3Z7XPE63BT5HJAN81FY51P", "01FT3Z7XPEBQ9WF9Q34EQMBVJY", "01FT3Z7XPEYHJR07CRKNZ0HK8E" ] } ], "organizations": [ { "@id": "01FT3Z7XNTTFNMKYCW2A67DW32", "@type": "investor", "has_organization_identifier": { "has_value": "43946" }, "has_organization_name": { "has_value": "Homeside Financial - " } } ], "price_adjustments": [ { "@id": "01FT3Z7XNWGT8N92SNKVNRF5ZH", "@type": "loan_product_price_adjustment", "has_loan_price_adjustment_percent": { "has_value": -0.25 }, "has_loan_adjustment_reason_text": { "has_value": "LTV is 60.01 - 70%, And FICO is >=740" }, "has_loan_adjustment_type": { "has_value": "Adjust Price" } }, { "@id": "01FT3Z7XNWT625ENNXE4NVMM1V", "@type": "loan_product_price_adjustment", "has_loan_price_adjustment_percent": { "has_value": 3.72 }, "has_loan_adjustment_reason_text": { "has_value": "State is TX, And 1st Mtg Loan Amt (Total) is 110000.01-150000.00" }, "has_loan_adjustment_type": { "has_value": "Adjust SRP" } } ], "notes": [ { "@id": "01FT3Z7XNYBNBPVQWZJG2X0F5E", "@type": "notes", "has_notes_comment": { "has_value": "The borrower's credit history related to bankruptcy and derogatory housing events, including mortgage late payments, has not been evaluated to determine eligibility for this program. Contact the Lender for related requirements." } }, { "@id": "01FT3Z7XNYYNSK04SMVAWVCQK9", "@type": "notes", "has_notes_comment": { "has_value": "Please note that you must complete the \"Self Employed\" field as \"Yes\" if self-employment income for any borrower is used to qualify as this may impact eligibility and/or pricing. " } }, { "@id": "01FT3Z7XNZMPHWEDYB2RSP987X", "@type": "notes", "has_notes_comment": { "has_value": "Please note that you must complete the \"First-Time Home Buyer\" field as \"Yes\" if any borrower is a first-time home buyer, as this may impact eligibility and/or pricing. " } } ], "prices": [ { "@id": "01FT3Z7XPEBMPC0MREMP90QMNV", "@type": "loan_price_at_par", "has_loan_price_at_par_percent": { "has_value": 100.5 }, "has_note_rate_at_par_percent": { "has_value": 3.125 }, "has_loan_price_lock_duration_days_at_par_count": { "has_value": 15 } }, { "@id": "01FT3Z7XPE63BT5HJAN81FY51P", "@type": "loan_price_at_par", "has_loan_price_at_par_percent": { "has_value": 100.25 }, "has_note_rate_at_par_percent": { "has_value": 3.125 }, "has_loan_price_lock_duration_days_at_par_count": { "has_value": 30 } }, { "@id": "01FT3Z7XPEBQ9WF9Q34EQMBVJY", "@type": "loan_price_at_par", "has_loan_price_at_par_percent": { "has_value": 100.25 }, "has_note_rate_at_par_percent": { "has_value": 3.125 }, "has_loan_price_lock_duration_days_at_par_count": { "has_value": 45 } }, { "@id": "01FT3Z7XPEYHJR07CRKNZ0HK8E", "@type": "loan_price_at_par", "has_loan_price_at_par_percent": { "has_value": 100.125 }, "has_note_rate_at_par_percent": { "has_value": 3.125 }, "has_loan_price_lock_duration_days_at_par_count": { "has_value": 60 } } ] } } } ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `invocation_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Product flow invocation identifier | ##### Response `200``application/json` 9 fields Successfully returned status of the Product flow Invocation. | Field | Type | Description | | --- | --- | --- | | `invocation_status`required | `string` | Invocation Status.`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` | | `transaction_id`required | `string` | Transaction ID used for invocation. | | `request_collection_id` | `string` | Request Collection ID. | | `request_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `response_collection_id` | `string` | Response Collection ID. | | `response_collection` | `object` | Collection. | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | — | | `loans` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_conforming_loan_indicator` | `object` | — | | `has_loan_to_value_ltv_ratio_percent` | `object` | — | | `has_combined_loan_to_value_cltv_ratio_percent` | `object` | — | | `has_home_equity_combined_loan_to_value_hcltv_ratio_percent` | `object` | — | | `with_closing_information` | `string[]` | — | | `with_housing_expenses_deprecated` | `string[]` | — | | `with_fees` | `string[]` | — | | `with_arm_adjustment` | `string[]` | — | | `with_loan_terms` | `string[]` | — | | `with_quote` | `string[]` | — | | `with_product` | `string[]` | — | | `with_load_product` | `string[]` | — | | `closing_information` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_total_closing_costs_amount` | `object` | — | | `housing_expenses_deprecated` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_proposed_first_mortgage_principal_and_interest_monthly_amount` | `object` | — | | `has_proposed_mortgage_insurance_monthly_amount` | `object` | — | | `has_proposed_first_mortgage_principal_interest_taxes_and_insurance_piti_monthly_amount` | `object` | — | | `arm_adjustments` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_margin_rate_percent` | `object` | — | | `loan_terms` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_margin_rate_percent` | `object` | — | | `has_loan_amortization_term_type` | `object` | — | | `has_loan_amortization_type` | `object` | — | | `quotes` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_loan_price_lock_duration_days_count` | `object` | — | | `has_loan_price_lock_expiration_date` | `object` | — | | `has_loan_price_percent` | `object` | — | | `has_discount_points_amount` | `object` | — | | `has_discount_points_percent` | `object` | — | | `has_rebate_amount` | `object` | — | | `has_rebate_percent` | `object` | — | | `has_total_credit_amount` | `object` | — | | `loan_products` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_product_identifier` | `object` | — | | `has_product_name` | `object` | — | | `has_total_loan_price_adjustment_percent` | `object` | — | | `has_total_rate_adjustment_percent` | `object` | — | | `has_total_service_release_premium_srp_adjustment_percent` | `object` | — | | `offered_by` | `string[]` | — | | `with_adjustment` | `string[]` | — | | `with_notes` | `string[]` | — | | `with_price` | `string[]` | — | | `organizations` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_organization_identifier` | `object` | — | | `price_adjustments` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_loan_price_adjustment_percent` | `object` | — | | `has_loan_adjustment_reason_text` | `object` | — | | `has_loan_adjustment_type` | `object` | — | | `notes` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_notes_comment` | `object` | — | | `prices` | `object[]` | — | | `@id` | `string` | — | | `@type` | `string` | — | | `has_loan_price_at_par_percent` | `object` | — | | `has_note_rate_at_par_percent` | `object` | — | | `has_loan_price_lock_duration_days_at_par_count` | `object` | — | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | | `callback_url` | `string` | URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished. | | `widget_url` | `string (uri)` | URL of the widget. | | `metadata` | `object` | Response Collection ID. | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/pricing/request-schema` #### Retrieve Request Schema `retrieveRequestSchema` 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. ##### Response 200 Schema200 Schema with Examples400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "oneOf": [ { "type": "object", "properties": { "loan_products": { "type": "array", "items": { "type": "object", "properties": { "@type": { "type": "string" }, "has_product_identifier": { "type": "object", "additionalProperties": false, "properties": { "has_value": { "type": "string" } }, "required": [ "has_value" ] } }, "required": [ "has_product_identifier" ] } }, "mortgage_products": { "type": "array", "items": { "type": "object", "properties": { "has_partner_transaction_identifier": { "type": "object", "additionalProperties": false, "properties": { "has_value": { "type": "string" } }, "required": [ "has_value" ] }, "@type": { "type": "string" } }, "required": [ "has_partner_transaction_identifier" ] } } }, "required": [ "loan_products", "mortgage_products" ] }, { "type": "object", "properties": { "addresses": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_county_name", "has_state_code" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "people": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_first_name", "has_last_name", "has_debt_expense_to_income_dti_ratio" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_first_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_last_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_debt_expense_to_income_dti_ratio": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "loan_terms": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_loan_purpose_type", "has_refinance_type", "has_lien_position_type", "has_base_loan_amount", "has_interest_only_indicator", "has_prepayment_penalty_indicator", "has_prepayment_penalty_term_months_count", "has_buydown_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_pledged_assets_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_escrow_required_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_loan_purpose_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "other", "purchase", "refinance" ] } } }, "has_refinance_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "cash_out", "limited_cash_out", "no_cash_out" ] } } }, "has_lien_position_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "first_lien", "second_lien", "subordinate_lien" ] } } }, "has_base_loan_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_interest_only_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_prepayment_penalty_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_prepayment_penalty_term_months_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_construction_loan_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_buydown_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "loans": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_mortgage_type", "has_relocation_loan_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_mortgage_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "conventional", "fha", "local_agency", "other", "public_and_indian_housing", "state_agency", "usda-rd", "va" ] } } }, "has_relocation_loan_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "properties": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_property_usage_type", "has_number_of_units_type", "has_project_type", "has_project_design_type", "has_planned_unit_development_pud_indicator", "has_manufactured_home_indicator", "has_manufactured_home_width_type", "has_project_usage_type", "has_stories_count" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_property_usage_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "investment", "other", "primary_residence", "second_home" ] } } }, "has_number_of_units_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "four", "one", "three", "two", "two_to_four" ] } } }, "has_project_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "common_interest_apartment", "condominium", "cooperative", "other" ] } } }, "has_project_design_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "highrise", "midrise", "townhouse" ] } } }, "has_planned_unit_development_pud_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_manufactured_home_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_manufactured_home_width_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_project_usage_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_stories_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "loan_payment_information": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_number_of_payments_30_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_60_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_90_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_120_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_rolling_12_months_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "loan_documentation": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_asset_documentation_level_type", "has_employment_documentation_level_type", "has_income_documentation_level_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_asset_documentation_level_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "neither_stated_nor_verified", "not_required", "stated_and_verified", "stated_only" ] } } }, "has_employment_documentation_level_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "neither_stated_nor_verified", "not_required", "stated_and_verified", "stated_only" ] } } }, "has_income_documentation_level_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "neither_stated_nor_verified", "not_required", "stated_and_verified", "stated_only" ] } } } } } }, "loan_summaries": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_total_debt_expense_to_income_dti_ratio", "has_representative_credit_score" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_total_debt_expense_to_income_dti_ratio": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_total_monthly_income_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_projected_reserves_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_representative_credit_score": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "declarations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_citizenship_residency_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_citizenship_residency_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "non_permanent_resident_alien", "non_resident_alien", "permanent_resident_alien", "us_citizen" ] } } }, "has_borrower_first_time_homebuyer_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_age_of_bankruptcy_years_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_age_of_prior_property_foreclosure_years_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "quote_requests": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_loan_officer_compensation_type", "has_calculate_borrower_requested_loan_amount_indicator", "has_include_fixed_rate_amortization_loans_indicator", "has_include_adjustable_rate_amortization_loans_indicator", "has_include_payment_option_adjustable_rate_amortization_loans_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_loan_officer_compensation_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "no_buyer_paid", "no_lender_paid", "yes_lender_paid" ] } } }, "has_calculate_borrower_requested_loan_amount_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_fixed_rate_amortization_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_adjustable_rate_amortization_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_balloon_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "employment": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_self_employment_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_self_employment_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "credit_score_information": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_credit_score" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_credit_score": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "arm_adjustments": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_first_rate_adjustment_months_count" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_first_rate_adjustment_months_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "automated_underwriting": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_desktop_underwriter_recommendation_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_desktop_underwriter_recommendation_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "approve_eligible", "approve_ineligible", "error", "expanded_approval_1_eligible", "expanded_approval_1_ineligible", "expanded_approval_2_eligible", "expanded_approval_2_ineligible", "expanded_approval_3_eligible", "expanded_approval_3_ineligible", "out_of_scope", "refer_eligible", "refer_ineligible", "refer_with_caution", "unknown" ] } } } } } }, "insurance": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_mortgage_insurance_premium_source_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_mortgage_insurance_premium_source_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "borrower", "lender" ] } } } } } }, "organizations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "quote_amortization_terms": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_amortization_term_months_count" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_amortization_term_months_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "sales_contracts": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_sales_contract_amount" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_sales_contract_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_property_valuation_amount" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_property_valuation_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "buydowns": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_buydown_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_buydown_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "one_one", "one_zero", "three", "two_one" ] } } } } } } }, "required": [ "addresses", "loan_terms", "loans", "properties", "loan_documentation", "loan_summaries", "declarations", "quote_requests", "automated_underwriting", "insurance", "quote_amortization_terms", "sales_contracts", "property_valuations", "buydowns" ] } ] } } ``` application/json Copy Request schema (possibly with examples) is successfully returned. ``` { "schema": { "oneOf": [ { "type": "object", "properties": { "loan_products": { "type": "array", "items": { "type": "object", "properties": { "@type": { "type": "string" }, "has_product_identifier": { "type": "object", "additionalProperties": false, "properties": { "has_value": { "type": "string" } }, "required": [ "has_value" ] } }, "required": [ "has_product_identifier" ] } }, "mortgage_products": { "type": "array", "items": { "type": "object", "properties": { "has_partner_transaction_identifier": { "type": "object", "additionalProperties": false, "properties": { "has_value": { "type": "string" } }, "required": [ "has_value" ] }, "@type": { "type": "string" } }, "required": [ "has_partner_transaction_identifier" ] } } }, "required": [ "loan_products", "mortgage_products" ] }, { "type": "object", "properties": { "addresses": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_county_name", "has_state_code" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_county_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_state_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_city_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_postal_code": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_address_line_1_text": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "people": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_first_name", "has_last_name", "has_debt_expense_to_income_dti_ratio" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_first_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_last_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_debt_expense_to_income_dti_ratio": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "loan_terms": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_loan_purpose_type", "has_refinance_type", "has_lien_position_type", "has_base_loan_amount", "has_interest_only_indicator", "has_prepayment_penalty_indicator", "has_prepayment_penalty_term_months_count", "has_buydown_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_pledged_assets_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_escrow_required_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_loan_purpose_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "other", "purchase", "refinance" ] } } }, "has_refinance_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "cash_out", "limited_cash_out", "no_cash_out" ] } } }, "has_lien_position_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "first_lien", "second_lien", "subordinate_lien" ] } } }, "has_base_loan_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_interest_only_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_prepayment_penalty_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_prepayment_penalty_term_months_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_construction_loan_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_buydown_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "loans": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_mortgage_type", "has_relocation_loan_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_mortgage_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "conventional", "fha", "local_agency", "other", "public_and_indian_housing", "state_agency", "usda-rd", "va" ] } } }, "has_relocation_loan_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "properties": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_property_usage_type", "has_number_of_units_type", "has_project_type", "has_project_design_type", "has_planned_unit_development_pud_indicator", "has_manufactured_home_indicator", "has_manufactured_home_width_type", "has_project_usage_type", "has_stories_count" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_property_usage_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "investment", "other", "primary_residence", "second_home" ] } } }, "has_number_of_units_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "four", "one", "three", "two", "two_to_four" ] } } }, "has_project_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "common_interest_apartment", "condominium", "cooperative", "other" ] } } }, "has_project_design_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "highrise", "midrise", "townhouse" ] } } }, "has_planned_unit_development_pud_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_manufactured_home_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_manufactured_home_width_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_project_usage_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } }, "has_stories_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "loan_payment_information": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_number_of_payments_30_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_60_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_90_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_120_days_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_number_of_payments_rolling_12_months_late_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "loan_documentation": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_asset_documentation_level_type", "has_employment_documentation_level_type", "has_income_documentation_level_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_asset_documentation_level_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "neither_stated_nor_verified", "not_required", "stated_and_verified", "stated_only" ] } } }, "has_employment_documentation_level_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "neither_stated_nor_verified", "not_required", "stated_and_verified", "stated_only" ] } } }, "has_income_documentation_level_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "neither_stated_nor_verified", "not_required", "stated_and_verified", "stated_only" ] } } } } } }, "loan_summaries": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_total_debt_expense_to_income_dti_ratio", "has_representative_credit_score" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_total_debt_expense_to_income_dti_ratio": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_total_monthly_income_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_projected_reserves_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } }, "has_representative_credit_score": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "declarations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_citizenship_residency_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_citizenship_residency_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "non_permanent_resident_alien", "non_resident_alien", "permanent_resident_alien", "us_citizen" ] } } }, "has_borrower_first_time_homebuyer_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_age_of_bankruptcy_years_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } }, "has_age_of_prior_property_foreclosure_years_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "quote_requests": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_loan_officer_compensation_type", "has_calculate_borrower_requested_loan_amount_indicator", "has_include_fixed_rate_amortization_loans_indicator", "has_include_adjustable_rate_amortization_loans_indicator", "has_include_payment_option_adjustable_rate_amortization_loans_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_loan_officer_compensation_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "no_buyer_paid", "no_lender_paid", "yes_lender_paid" ] } } }, "has_calculate_borrower_requested_loan_amount_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_fixed_rate_amortization_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_adjustable_rate_amortization_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } }, "has_include_balloon_loans_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "employment": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_self_employment_indicator" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_self_employment_indicator": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "boolean" } } } } } }, "credit_score_information": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_credit_score" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_credit_score": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "arm_adjustments": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_first_rate_adjustment_months_count" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_first_rate_adjustment_months_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "automated_underwriting": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_desktop_underwriter_recommendation_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_desktop_underwriter_recommendation_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "approve_eligible", "approve_ineligible", "error", "expanded_approval_1_eligible", "expanded_approval_1_ineligible", "expanded_approval_2_eligible", "expanded_approval_2_ineligible", "expanded_approval_3_eligible", "expanded_approval_3_ineligible", "out_of_scope", "refer_eligible", "refer_ineligible", "refer_with_caution", "unknown" ] } } } } } }, "insurance": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_mortgage_insurance_premium_source_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_mortgage_insurance_premium_source_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "borrower", "lender" ] } } } } } }, "organizations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_organization_name": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string" } } } } } }, "quote_amortization_terms": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_amortization_term_months_count" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_amortization_term_months_count": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "integer" } } } } } }, "sales_contracts": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_sales_contract_amount" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_sales_contract_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "property_valuations": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_property_valuation_amount" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_property_valuation_amount": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "number" } } } } } }, "buydowns": { "type": "array", "items": { "type": "object", "required": [ "@type", "@id", "has_buydown_type" ], "properties": { "@type": { "type": "string" }, "@id": { "type": "string" }, "has_buydown_type": { "type": "object", "required": [ "has_value" ], "properties": { "has_value": { "type": "string", "enum": [ "one_one", "one_zero", "three", "two_one" ] } } } } } } }, "required": [ "addresses", "loan_terms", "loans", "properties", "loan_documentation", "loan_summaries", "declarations", "quote_requests", "automated_underwriting", "insurance", "quote_amortization_terms", "sales_contracts", "property_valuations", "buydowns" ] } ] }, "examples": [ { "loan_products": [ { "@type": "loan_product", "has_product_name": { "has_value": "NEW - 30 Year Fixed Conventional" }, "has_product_description_text": { "has_value": "" }, "has_product_identifier": { "has_value": "20290727" } } ], "mortgage_products": [ { "has_partner_product_name": { "has_value": "Product Detail" }, "has_partner_transaction_identifier": { "has_value": null }, "has_service_response_date": { "has_value": "2021-09-14T07:07:38.1847142Z" }, "has_partner_name": { "has_value": "Optimal Blue" }, "@type": "pricing" } ] }, { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declarations", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_ballon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "string" }, "has_project_usage_type": { "has_value": "string" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] }, { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": "01FDTQ5PKBF5JHM46TQQEE3SAE", "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "refinance" }, "has_refinance_type": { "has_value": "cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_rice_quote_request", "has_discount_points_percent": { "has_value": 0 }, "has_cash_out_amount": { "has_value": 10000 }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "false" }, "has_project_usage_type": { "has_value": "false" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "subject_property", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] }, { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": "01FDTQ5PKBF5JHM46TQQEE3SAE", "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_rice_quote_request", "has_discount_points_percent": { "has_value": 0 }, "has_cash_out_amount": { "has_value": 0 }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "false" }, "has_project_usage_type": { "has_value": "false" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "subject_property", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ], "mortgage_products": [ { "@id": "01FDTQGB9JWTYPBP9NNEDC7F9M", "@type": "Options", "has_partner_name": { "has_value": "Optimal Blue" } } ] }, { "people": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYQ", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declarations": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_risk": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ], "has_debt_expense_to_income_dti_ratio": { "has_value": 15 } } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_mortgage_type": { "has_value": "conventional" }, "has_relocation_loan_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_automated_underwriting": [ "01FDTQ5PJYAP2V6RT2ZJND1KC4" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": "01FDTQ5PKBF5JHM46TQQEE3SAE", "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_term", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": false }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "automated_underwriting": [ { "@id": "01FDTQ5PJYAP2V6RT2ZJND1KC4", "@type": "NotSpecified", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_rice_quote_request", "has_discount_points_percent": { "has_value": 1 }, "has_cash_out_amount": { "has_value": 0 }, "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_type": { "has_value": "condominium" }, "has_project_design_type": { "has_value": "midrise" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "false" }, "has_project_usage_type": { "has_value": "false" }, "has_stories_count": { "has_value": 1 }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "subject_property", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ], "mortgage_products": [ { "@id": "01FDTQGB9JWTYPBP9NNEDC7F9M", "@type": "Options", "has_partner_name": { "has_value": "Optimal Blue" } } ] } ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Request schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | Schema for the Request Collection | | `examples` | `object` | Each item in the dictionary corresponds to the name of the example and dictionary content is the sample response. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `GET` `/products/pricing/response-schema` #### Retrieve Response Schema `retrieveResponseSchema` Retrieve Response Schema returns the JSON schema for the response collection, created by an invocation. If you would like to retrieve examples along with the schema, you can provide `return_examples=True` query parameter. ##### Response 200 Schema200 Schema with Examples Response400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500 application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": {} } ``` application/json Copy Response schema (possibly with examples) is successfully returned. ``` { "schema": {}, "examples": [ {} ] } ``` application/json Copy Error ``` { "message": "Please provide one of valid return examples values:\ntrue, false" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | | `return_examples` | `boolean` query | If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false` | ##### Response `200``application/json` 2 fields Response schema (possibly with examples) is successfully returned. | Field | Type | Description | | --- | --- | --- | | `schema`required | `object` | JSON-Schema as a single object | | `examples` | `object` | A key-value pair for the examples. Keys are the example names, while values correspond to the example values for the response collections you can retrieve. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Partners `GET` `/products/pricing/partners` #### Retrieve Product Partners `getVendors` Retrieve Partners retrieves: -All the Partners (vendors) configured in the Product Flows configurations. -The Order of the partner in the Product Waterfall Settings or default order in Product Flows if Product Waterfall was not configured. -The status of the partners as active/upcoming according to the configurations of the product flows of these partners (partner will be active if at least one flow is active).' ##### Response 200 Example1200 Example2400403404 GetProduct404 text/html500 application/json Copy Successfully retrieved product partners. ``` [ { "Partner": "partner_name", "order": 1, "active": true, "status": "active", "verification_type": "borrower", "byoc": true } ] ``` application/json Copy Successfully retrieved product partners. ``` [ { "Partner": "partner_name", "order": 1, "active": false, "status": "upcoming", "verification_type": "borrower", "byoc": true } ] ``` application/json Copy Request data failed validation ``` { "message": "{'data': ['Missing data for required field.']}" } ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `active` | `boolean` query | `false` | Include vendors with active product flows | ##### Response `200``application/json` 6 fields Successfully retrieved product partners. | Field | Type | Description | | --- | --- | --- | | `partner` | `string` | Partner name | | `order` | `number` | Order of the product flows associated with this partner | | `active` | `boolean` | Partner has active flows | | `status` | `string` | Status of the partner | | `verification_type` | `string` | Type of verification | | `byoc` | `boolean` | Specify whether customer should add its own partner credentials or not | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `PATCH` `/products/pricing/partners/{partner}/status` #### Update Partner Status `updatePartnerStatus` Update Partner Status updates the active value of a specific partner to value true or false. This shall activate or deactivate the flows configured for this partner in Product Flows. ##### Request application/json Copy ``` { "active": true, "verification_type": "borrower", "byoc": true, "status": "active" } ``` ##### Response 200400 application/json400 text/html403404 GetProduct404 text/html500 application/json Copy Successfully updated active parameter for the partner. ``` { "message": "Partner status updated." } ``` application/json Copy Failed to update the partner from one of the reasons. ``` { "message": "Partner doesn't exist in database." } ``` text/html Copy Failed to update the partner from one of the reasons. ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "type": "string", "description": "Error Message." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `partner` required | `string` path | `partner_name` | Name of the partner for which we wan't to update status. | ##### Request body`application/json` 4 fields | Field | Type | Description | | --- | --- | --- | | `active`required | `boolean` | Example `true` | | `byoc` | `boolean` | Specify whether customer should add its own partner credentials or not | | `status` | `string` | Status of the vendor | | `verification_type` | `string` | Type of verification | ##### Response `200``application/json` 1 fields Successfully updated active parameter for the partner. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Partner status updated. | ##### Response `400``application/json` 1 fields Failed to update the partner from one of the reasons. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Partner doesn't exist in database. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error Message. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ### Setup `POST` `/setup/optimalBlue/credentials` #### Set OptimalBlue Credentials `setOptimalBlueCredentials` By using Set OptimalBlue Credentials API we allow our customers to configure OptimalBlue in customer environment. If you want to use your own OptimalBlue contract for Price operations, run Set OptimalBlue Credentials API. You can check the partner status by calling the Retrieve Partners endpoint ##### Request application/json Copy ``` { "client_id": "--------", "client_secret": "", "originator_id": "--------", "business_channel_id": "-------", "environment": "staging" } ``` ##### Response 200400403404422500 application/json Copy Setup API Triggered Successfully ``` { "message": "Credentials are saved and verified" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` 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" } ``` 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" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 5 fields | Field | Type | Description | | --- | --- | --- | | `client_id`required | `string` | OptimalBlue client ID | | `client_secret`required | `string` | OptimalBlue client secret | | `originator_id` | `string` | OptimalBlue originator id | | `business_channel_id` | `string` | OptimalBlue business channel id | | `environment` | `string` | OptimalBlue environment selection`production``staging` | ##### Response `200``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `POST` `/setup/polly/credentials` #### Set polly Credentials `setPollyCredentials` Set Polly Credentials By using Set Polly Credentials API we allow our customers to configure Poly in customer environment. If you want to use your own Polly contract for Price operations, run Set Polly Credentials API. You can check the partner status by calling the Retrieve Partners endpoint ##### Request application/json Copy ``` { "user_name": "--------", "password": "", "domain": "https://api.stage.polly.io/", "client_id": "", "client_secret": "", "audienceId": "" } ``` ##### Response 200400403404422500 application/json Copy Setup API Triggered Successfully ``` { "message": "Credentials are saved and verified" } ``` application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` 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" } ``` 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" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | ##### Request body`application/json` 6 fields | Field | Type | Description | | --- | --- | --- | | `user_name`required | `string` | Polly username | | `password`required | `string` | Polly password | | `domain`required | `string` | Polly API domain | | `client_id`required | `string` | Polly client ID | | `client_secret`required | `string` | Polly API client secret | | `audienceId`required | `string` | Polly audience ID | ##### Response `200``application/json` 1 fields Setup API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | `GET` `/setup/{partner_name}/credentials` #### Retrieve Partner Credentials Schema `getCredentials` Get Credentials Schema Get credentials schema for specific partner. You can use retrieved schema for updating the partner credentials. ##### Response 400403404422500 application/json Copy Request data failed validation ``` { "code": 400, "message": "Bad Request" } ``` 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" } ``` 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" } ``` application/json Copy Unprocessed Entity ``` { "code": 422, "message": "Unprocessed Entity." } ``` application/json Copy The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. ``` { "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." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Environment API Key. | | `partner_name` required | `string` path | `optimalblue` | Partner name | ##### Response `200``application/json` 2 fields Create Adapter API Triggered Successfully | Field | Type | Description | | --- | --- | --- | | `code` | `number` | Status code | | `message` | `object` | Message | ##### Response `400``application/json` 1 fields Request data failed validation | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `403``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `404``application/json` 2 fields Invalid key for service | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | | `url` | `string` | — | ##### Response `422``application/json` 1 fields Unprocessed Entity | Field | Type | Description | | --- | --- | --- | | `error` | `object` | Unprocessed entity error. | | `code`required | `string` | Error name. | | `message`required | `string` | Error description. | ##### Response `500``application/json` 1 fields The product has encountered an internal server error. If possible, please contact Staircase support with the transaction_id you used. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | — | ### Platform `POST` `/transactions` #### Create Transaction `createTransaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called `transaction_id`. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all the outputs to the same transaction. A `transaction_id`, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. To access all collections associated with a given transaction_id, try out /transactions/{transaction_id}/collections ##### Response 201403500 application/json Copy Transaction created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "created_at": "03/04/2021, 1:04:05 PM EST" } ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 1 | Parameter | Type | Description | | --- | --- | --- | | `x-api-key` required | `string` header | Environment API Key. | ##### Response `201``application/json` 2 fields Transaction created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Staircase Transaction IdentifierExample `01F0KHK7DN3H5JZ4QJKMYAM6GB` | | `created_at` | `string` | Staircase time string.Example `03/03/2021, 8:24:04 AM EST` | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `createCollection` Create Collection creates a collection of data points required for product invocation. A collection contains a digital representation of the input or output data for the product and is identified by `collection_id`. The Example below contains a sample collection that you can use to make the product invocation in /products/pricing/invocations ##### Request Request ExamplePreapproval Example application/json Copy ``` { "data": { "vendor_name": "optimalBlue", "request_data": { "people": [ { "@id": "01FDTQ5PJSKC94HHZGYZDSTXCT", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declaration": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ] } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ] } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_terms", "has_mortgage_type": { "has_value": "conventional" }, "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_discount_points_percent": { "has_value": 0 }, "has_include_balloon_loans_indicator": { "has_value": false }, "has_cash_out_amount": { "has_value": 0 }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "string" }, "has_financed_unit_count": { "has_value": 1 }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_stories_count": { "has_value": 1 }, "has_construction_method_type": { "has_value": "site_built" }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } } ``` application/json Copy ``` { "data": { "underwritings": [ { "@id": "1", "@type": "underwriting", "with_automated_underwriting": [ "01G0F46DMPX9DA9SYW9MD469S1" ] } ], "loans": [ { "@id": "01G0F46DMPHNWM8TWMGJQRJW5Y", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "has_originator_loan_identifier": { "has_value": "01G0F436Y4B8Z97ZZCX4PDENMF" }, "with_payment_information": [ "loan_payment_information" ], "has_loan_status_type": { "has_value": "prequalification" }, "has_loan_role_type": { "has_value": "subject_loan" }, "with_underwriting": [ "1" ], "with_arm_adjustment": [ "01G0F46DMPRTYR25HZZCWH0EMX" ], "with_documentation": [ "01G0F46DMPWS3BHQZM14C8KFVH" ], "with_insurance": [ "01G0F46DMP72CMBWKC10X0PPDC" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "with_loan_terms": [ "01G0F46DMPQ9680F59JE7QETN1" ], "serviced_by": [ "01G0F46DMPNP1Z0PD6B98BN92S" ], "with_summary": [ "01G0F46DMP778HBQW874FV3RFR" ], "with_quote_request": [ "01G0F46DMP1A0WN0T89KDRKF5A" ], "with_buydown": [ "01G0F46DMPWPA5VM805MXSH2KG" ], "secured_by_property": [ "01G0F46DMPE0NJZ7XGRSZJEPM0" ], "with_borrower": [ "01G0F43BRK1SAPR67KC0J1NVQB" ] } ], "loan_payment_information": [ { "@id": "loan_payment_information", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "loan_summaries": [ { "@id": "01G0F46DMP778HBQW874FV3RFR", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 27 }, "has_total_monthly_income_amount": { "has_value": 7500 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 743 } } ], "arm_adjustments": [ { "@id": "01G0F46DMPRTYR25HZZCWH0EMX", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "insurance": [ { "@id": "01G0F46DMP72CMBWKC10X0PPDC", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01G0F46DMPWS3BHQZM14C8KFVH", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "automated_underwritings": [ { "@id": "01G0F46DMPX9DA9SYW9MD469S1", "@type": "automated_underwriting", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "loan_terms": [ { "@id": "01G0F46DMPQ9680F59JE7QETN1", "@type": "loan_terms", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 50000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": false }, "has_mortgage_type": { "has_value": "conventional" } } ], "buydowns": [ { "@id": "01G0F46DMPWPA5VM805MXSH2KG", "@type": "buydown", "has_buydown_type": { "has_value": "one_zero" } } ], "mortgage_products": [ { "@id": "01G0F46DMQZZHDGDN4X8GMTKET", "@type": "pricing", "has_partner_name": { "has_value": "Optimal Blue" } }, { "@id": "01G0F46DMQ6NBC8PC4FPKP5QE7", "@type": "automated_underwriting_system", "has_credit_report_vendor_identifier": { "has_value": "" } }, { "@id": "01G0F456JR9HV6FFQ38NG63W8T", "@type": "credit" } ], "organizations": [ { "@id": "01G0F46DMPNP1Z0PD6B98BN92S", "@type": "servicer" }, { "@id": "01G0F43BRKFYQ6J0K5GJRYF2JB", "@type": "organization", "has_organization_name": { "has_value": "Amazon" } }, { "@id": "01G0F43BRK89FAZDRJZDC5DX0K", "@type": "customer", "has_transaction_identifier": { "has_value": "01G0F436Y4B8Z97ZZCX4PDENMF" } } ], "quote_requests": [ { "@id": "01G0F46DMP1A0WN0T89KDRKF5A", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01G0F46DMQRJJ7VVS4Y038BKNX" ] } ], "quote_amortization_terms": [ { "@id": "01G0F46DMQRJJ7VVS4Y038BKNX", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01G0F46DMPE0NJZ7XGRSZJEPM0", "@type": "subject_property", "has_construction_method_type": { "has_value": "site_built" }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "other" }, "has_stories_count": { "has_value": 1 }, "has_financed_unit_count": { "has_value": 1 }, "has_property_in_project_indicator": { "has_value": false }, "with_address": [ "01G0F46DMPB9Y8YNQN8BY1AZ1F" ], "with_sales_contract": [ "01G0F46DMQYRE9H69KXTEFW8KK" ], "with_value": [ "01G0F46DMQ917ABYDMNHH8BR61" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01G0F46DMPB9Y8YNQN8BY1AZ1F", "@type": "residential_address", "has_county_name": { "has_value": "Fort Bend" }, "has_state_code": { "has_value": "TX" } }, { "@id": "01G0F43BRJB7S9ZSS0Q4AXN357", "@type": "address", "has_address_line_1_text": { "has_value": "126 4th St" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Atlanta" }, "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } }, { "@id": "01G0F456PEEXG5XWXDFNW8H5XY", "@type": "residential_address", "has_address_line_1_text": { "has_value": "126 4TH ST" }, "has_city_name": { "has_value": "ATLANTA" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } } ], "sales_contracts": [ { "@id": "01G0F46DMQYRE9H69KXTEFW8KK", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 500000 } } ], "property_valuations": [ { "@id": "01G0F46DMQ917ABYDMNHH8BR61", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 500000 } } ], "assets": [ { "@id": "01G0F43ERM91FT0DTAQ1J8FME3", "@type": "checking_account", "has_market_value_amount": { "has_value": 10000 }, "owned_by": [ "01G0F43BRK1SAPR67KC0J1NVQB" ] } ], "contact_information": [ { "@id": "01G0F43BRKGVC0X90BH7S6E8S0", "@type": "contact_information", "has_email_address": { "has_value": "test@email.com" }, "has_phone_number": { "has_value": "1231231232" } } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01G0F456QKHJP096X9CH9H0QAZ" ] } ], "credit_score_factors": [ { "@id": "01G0F45MHVRFPK6245AJ68T9MZ", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": "00030" }, "has_credit_score_factor_text": { "has_value": "TIME SINCE MOST RECENT ACCOUNT OPENING IS TOO SHORT" } }, { "@id": "01G0F45MHW2W46K8E0TTE3CC86", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": "00014" }, "has_credit_score_factor_text": { "has_value": "LENGTH OF TIME ACCOUNTS HAVE BEEN ESTABLISHED" } }, { "@id": "01G0F45MHWNRX3YABMXWX8QHE1", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": 8 }, "has_credit_score_factor_text": { "has_value": "TOO MANY INQUIRIES LAST 12 MONTHS" } }, { "@id": "01G0F45MHW9J9AR4T56XX2B6HK", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": "00012" }, "has_credit_score_factor_text": { "has_value": "LENGTH OF TIME REVOLVING ACCOUNTS HAVE BEEN ESTABLISHED" } } ], "credit_score_information": [ { "@id": "01G0F456QKHJP096X9CH9H0QAZ", "@type": "credit_score_information", "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_score": { "has_value": "00743" } } ], "declarations": [ { "@id": "01G0F43BRKNQKR7P36ZT59T2YX", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_intent_to_occupy_indicator": { "has_value": true }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false } } ], "documents": [ { "@id": "01G0F45MHWAWZKFCZHT7RCFR5B", "@type": "credit_report", "has_staircase_blob_identifier": { "has_value": "01G0F450M9J09JRC2G6CFAVMX8" } } ], "employment": [ { "@id": "01G0F43BRMG882TMY5F8S50GY8", "@type": "employment", "has_self_employment_indicator": { "has_value": false }, "provided_by": [ "01G0F43BRKFYQ6J0K5GJRYF2JB" ] } ], "housing_expenses_deprecated": [ { "@id": "01G0F43BRK4Z2GDQPHBJNSZS1M", "@type": "housing_expenses_deprecated", "has_present_first_mortgage_principal_and_interest_monthly_amount": { "has_value": 0 }, "has_present_first_mortgage_principal_interest_taxes_and_insurance_piti_monthly_amount": { "has_value": 0 }, "has_present_flood_insurance_monthly_amount": { "has_value": 0 }, "has_present_homeowners_association_dues_and_condominium_fees_monthly_amount": { "has_value": 0 }, "has_present_homeowners_insurance_monthly_amount": { "has_value": 0 }, "has_present_mortgage_insurance_monthly_amount": { "has_value": 0 }, "has_present_other_mortgage_loan_principal_and_interest_monthly_amount": { "has_value": 0 }, "has_present_other_mortgage_loan_principal_interest_taxes_and_insurance_monthly_amount": { "has_value": 0 }, "has_present_property_tax_monthly_amount": { "has_value": 0 }, "has_present_supplemental_property_insurance_monthly_amount": { "has_value": 0 }, "has_present_total_monthly_payment_amount": { "has_value": 0 } } ], "income": [ { "@id": "01G0F43DJT2A15SH870HJ2K5EX", "@type": "employment_income", "has_income_amount": { "has_value": 7500 }, "has_income_pay_frequency_type": { "has_value": "monthly" } }, { "@id": "01G0F43DJTH8BHZGVS31GBFSKV", "@type": "employment_income", "has_income_amount": { "has_value": 90000 }, "has_income_year": { "has_value": "2022" } } ], "liabilities": [ { "@id": "01G0F43BRK7WTG1SSEEJG143CF", "@type": "liability", "has_liability_payment_amount": { "has_value": 2000 }, "has_liability_unpaid_balance_amount": { "has_value": 2000 } } ], "people": [ { "@id": "01G0F43BRK1SAPR67KC0J1NVQB", "@type": "borrower", "contact_at": [ "01G0F43BRKGVC0X90BH7S6E8S0" ], "earns": [ "01G0F43DJTH8BHZGVS31GBFSKV", "01G0F43DJT2A15SH870HJ2K5EX" ], "has_birth_date": { "has_value": "1958-12-12" }, "has_first_name": { "has_value": "DAD" }, "has_last_name": { "has_value": "FIRSTIMER" }, "has_marital_status_type": { "has_value": "unmarried" }, "has_taxpayer_identifier_type": { "has_value": "individual_taxpayer_identification_number" }, "has_taxpayer_identifier_value": { "has_value": "000-000-001" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 25 }, "lives_at": [ "01G0F43BRKGDPCT3N1BHVVXPJ1" ], "owes_liability": [ "01G0F43BRK7WTG1SSEEJG143CF" ], "owns_asset": [ "01G0F43ERM91FT0DTAQ1J8FME3" ], "with_address": [ "01G0F43BRJB7S9ZSS0Q4AXN357" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ], "with_declaration": [ "01G0F43BRKNQKR7P36ZT59T2YX" ], "works_for": [ "01G0F43BRKFYQ6J0K5GJRYF2JB" ], "employed_as": [ "01G0F43BRMG882TMY5F8S50GY8" ] } ], "residences": [ { "@id": "01G0F43BRKGDPCT3N1BHVVXPJ1", "@type": "residence", "has_borrower_residency_type": { "has_value": "current" }, "has_residency_basis_type": { "has_value": "living_rent_free" }, "has_residency_duration_months_count": { "has_value": 30 }, "with_address": [ "01G0F43BRJB7S9ZSS0Q4AXN357" ] } ] } } ``` ##### Response 201400 CreateCollectionError400 text/html403404 CreateCollectionError404 text/html500 application/json Copy Collection created successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "vendor_name": "optimalBlue", "request_data": { "people": [ { "@id": "01FDTQ5PJSKC94HHZGYZDSTXCT", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declaration": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ] } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ] } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_terms", "has_mortgage_type": { "has_value": "conventional" }, "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_discount_points_percent": { "has_value": 0 }, "has_include_balloon_loans_indicator": { "has_value": false }, "has_cash_out_amount": { "has_value": 0 }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "string" }, "has_financed_unit_count": { "has_value": 1 }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_stories_count": { "has_value": 1 }, "has_construction_method_type": { "has_value": "site_built" }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } } ``` application/json Copy Error ``` { "message": "Unable to create collection. Please check the collectionchr\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to create collection. Please check the transaction\nID." } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data that is needed for invocation. It should follow the request schema | | `people` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_first_name`required | `object` | — | | `has_value`required | `string` | — | | `has_last_name`required | `object` | — | | `has_value`required | `string` | — | | `has_debt_expense_to_income_dti_ratio`required | `object` | — | | `has_value`required | `number` | — | | `employed_as`required | `string[]` | — | | `with_declaration`required | `string[]` | — | | `with_credit_information`required | `string[]` | — | | `employment` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_self_employment_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `declarations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_citizenship_residency_type`required | `object` | — | | `has_value`required | `string` | `non_permanent_resident_alien``non_resident_alien``permanent_resident_alien``us_citizen` | | `has_borrower_first_time_homebuyer_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_bankruptcy_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_age_of_bankruptcy_years_count` | `object` | — | | `has_value`required | `integer` | — | | `has_prior_property_foreclosure_completed_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_age_of_prior_property_foreclosure_years_count` | `object` | — | | `has_value`required | `integer` | — | | `credit_score_information` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_credit_score`required | `object` | — | | `has_value`required | `string` | — | | `loans`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_relocation_loan_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `with_borrower`required | `string[]` | — | | `with_loan_terms`required | `string[]` | — | | `with_documentation`required | `string[]` | — | | `with_summary`required | `string[]` | — | | `with_payment_information`required | `string[]` | — | | `with_arm_adjustment`required | `string[]` | — | | `with_insurance`required | `string[]` | — | | `with_project`required | `string[]` | — | | `serviced_by`required | `string[]` | — | | `with_buydown`required | `string[]` | — | | `with_quote_request`required | `string[]` | — | | `secured_by_property`required | `string[]` | — | | `has_heloc_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `loan_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_pledged_assets_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_mortgage_type`required | `object` | — | | `has_value`required | `string` | `conventional``fha``local_agency``other``public_and_indian_housing``state_agency``usda-rd``va` | | `has_escrow_required_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_loan_purpose_type`required | `object` | — | | `has_value`required | `string` | `other``purchase``refinance` | | `has_refinance_type`required | `object` | — | | `has_value`required | `string` | `cash_out``limited_cash_out``no_cash_out` | | `has_lien_position_type`required | `object` | — | | `has_value`required | `string` | `first_lien``second_lien``subordinate_lien` | | `has_base_loan_amount`required | `object` | — | | `has_value`required | `number` | — | | `has_interest_only_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_prepayment_penalty_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_prepayment_penalty_term_months_count`required | `object` | — | | `has_value`required | `integer` | — | | `has_construction_loan_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_buydown_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `arm_adjustments` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_first_rate_adjustment_months_count`required | `object` | — | | `has_value`required | `integer` | — | | `buydowns`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_buydown_type`required | `object` | — | | `has_value`required | `string` | `one_one``one_zero``three``two_one` | | `insurance`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_mortgage_insurance_premium_source_type`required | `object` | — | | `has_value`required | `string` | `borrower``lender` | | `loan_documentation`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_asset_documentation_level_type`required | `object` | — | | `has_value`required | `string` | `neither_stated_nor_verified``not_required``stated_and_verified``stated_only` | | `has_employment_documentation_level_type`required | `object` | — | | `has_value`required | `string` | `neither_stated_nor_verified``not_required``stated_and_verified``stated_only` | | `has_income_documentation_level_type`required | `object` | — | | `has_value`required | `string` | `neither_stated_nor_verified``not_required``stated_and_verified``stated_only` | | `loan_summaries`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_total_debt_expense_to_income_dti_ratio`required | `object` | — | | `has_value`required | `number` | — | | `has_total_monthly_income_amount` | `object` | — | | `has_value`required | `number` | — | | `has_projected_reserves_amount` | `object` | — | | `has_value`required | `number` | — | | `has_representative_credit_score`required | `object` | — | | `has_value`required | `integer` | — | | `loan_payment_information` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_number_of_payments_30_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_60_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_90_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_120_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_rolling_12_months_late_count` | `object` | — | | `has_value`required | `integer` | — | | `organizations` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_organization_name` | `object` | — | | `has_value`required | `string` | — | | `quote_requests`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_loan_officer_compensation_type`required | `object` | — | | `has_value`required | `string` | `no_buyer_paid``no_lender_paid``yes_lender_paid` | | `has_calculate_borrower_requested_loan_amount_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_include_fixed_rate_amortization_loans_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_include_adjustable_rate_amortization_loans_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_include_payment_option_adjustable_rate_amortization_loans_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_discount_points_percent` | `object` | — | | `has_value`required | `number` | — | | `has_include_balloon_loans_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_cash_out_amount` | `object` | — | | `has_value`required | `number` | — | | `include_loans_with_amortization_term` | `string[]` | — | | `quote_amortization_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_amortization_term_months_count`required | `object` | — | | `has_value`required | `integer` | — | | `properties`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_property_usage_type`required | `object` | — | | `has_value`required | `string` | `investment``other``primary_residence``second_home` | | `has_number_of_units_type`required | `object` | — | | `has_value`required | `string` | `four``one``three``two``two_to_four` | | `has_project_design_type`required | `object` | — | | `has_value`required | `string` | `garden_project``highrise_project``midrise_project``other``townhouse_rowhouse` | | `has_planned_unit_development_pud_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_manufactured_home_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_manufactured_home_width_type`required | `object` | — | | `has_value`required | `string` | — | | `has_project_usage_type`required | `object` | — | | `has_value`required | `string` | — | | `has_stories_count`required | `object` | — | | `has_value`required | `integer` | — | | `has_construction_method_type`required | `object` | — | | `has_value`required | `string` | `manufactured``mobile_home``modular``on_frame_modular``other``site_built` | | `has_financed_unit_count`required | `object` | — | | `has_value`required | `integer` | — | | `has_non_warrantable_project_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `with_address`required | `string[]` | — | | `with_sales_contract`required | `string[]` | — | | `with_value`required | `string[]` | — | | `projects` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_project_legal_structure_type`required | `object` | — | | `has_value`required | `string` | `common_interest_apartment``condominium``cooperative``unknown` | | `addresses`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_county_name` | `object` | Required if the address is for the subject property | | `has_value`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name` | `object` | — | | `has_value`required | `string` | — | | `has_postal_code` | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `sales_contracts`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_sales_contract_amount`required | `object` | — | | `has_value`required | `number` | — | | `property_valuations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | ##### Response `201``application/json` 4 fields Collection created successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `retrieveCollection` Retrieve Collection returns the content of a given `collection_id` associated with a `transaction_id`. ##### Response 403404 GetCollectionError404 GetCollectionsError500 application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collection. Please check the given ids" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Response `200``application/json` 4 fields Successfully Retrieved Collection | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | — | | `collection_id`required | `string` | — | | `metadata`required | `object` | — | | `created_at`required | `string` | — | | `validation`required | `boolean` | — | | `data`required | `object` | — | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `400` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `RetrieveTransactionCollections` Retrieve Transaction Collections returns the content of a given `collection_id` associated with a specific `transaction_id`. ##### Response 200400403404500 application/json Copy Transaction collection retrieved successfully ``` { "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "transaction_id": "01FFHJ2ZVS4P7N4AV5W0993QMD", "collection_id": "01FFHJ4JCWGHV38SC1NJ8TVNFY", "data": {} } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to get collections of given transaction. Please\ncheck the transaction id" } ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | ##### Response `200``application/json` 4 fields Transaction collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `updateCollection` Update Collection allows you to update the content of a given `collection_id` associated with a `transaction_id`. ##### Request Request ExamplePreapproval Example application/json Copy ``` { "data": { "vendor_name": "optimalBlue", "request_data": { "people": [ { "@id": "01FDTQ5PJSKC94HHZGYZDSTXCT", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declaration": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ] } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ] } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_terms", "has_mortgage_type": { "has_value": "conventional" }, "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_discount_points_percent": { "has_value": 0 }, "has_include_balloon_loans_indicator": { "has_value": false }, "has_cash_out_amount": { "has_value": 0 }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "string" }, "has_financed_unit_count": { "has_value": 1 }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_stories_count": { "has_value": 1 }, "has_construction_method_type": { "has_value": "site_built" }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } } ``` application/json Copy ``` { "data": { "underwritings": [ { "@id": "1", "@type": "underwriting", "with_automated_underwriting": [ "01G0F46DMPX9DA9SYW9MD469S1" ] } ], "loans": [ { "@id": "01G0F46DMPHNWM8TWMGJQRJW5Y", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "has_originator_loan_identifier": { "has_value": "01G0F436Y4B8Z97ZZCX4PDENMF" }, "with_payment_information": [ "loan_payment_information" ], "has_loan_status_type": { "has_value": "prequalification" }, "has_loan_role_type": { "has_value": "subject_loan" }, "with_underwriting": [ "1" ], "with_arm_adjustment": [ "01G0F46DMPRTYR25HZZCWH0EMX" ], "with_documentation": [ "01G0F46DMPWS3BHQZM14C8KFVH" ], "with_insurance": [ "01G0F46DMP72CMBWKC10X0PPDC" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "with_loan_terms": [ "01G0F46DMPQ9680F59JE7QETN1" ], "serviced_by": [ "01G0F46DMPNP1Z0PD6B98BN92S" ], "with_summary": [ "01G0F46DMP778HBQW874FV3RFR" ], "with_quote_request": [ "01G0F46DMP1A0WN0T89KDRKF5A" ], "with_buydown": [ "01G0F46DMPWPA5VM805MXSH2KG" ], "secured_by_property": [ "01G0F46DMPE0NJZ7XGRSZJEPM0" ], "with_borrower": [ "01G0F43BRK1SAPR67KC0J1NVQB" ] } ], "loan_payment_information": [ { "@id": "loan_payment_information", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "loan_summaries": [ { "@id": "01G0F46DMP778HBQW874FV3RFR", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 27 }, "has_total_monthly_income_amount": { "has_value": 7500 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 743 } } ], "arm_adjustments": [ { "@id": "01G0F46DMPRTYR25HZZCWH0EMX", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "insurance": [ { "@id": "01G0F46DMP72CMBWKC10X0PPDC", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01G0F46DMPWS3BHQZM14C8KFVH", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "automated_underwritings": [ { "@id": "01G0F46DMPX9DA9SYW9MD469S1", "@type": "automated_underwriting", "has_desktop_underwriter_recommendation_type": { "has_value": "out_of_scope" } } ], "loan_terms": [ { "@id": "01G0F46DMPQ9680F59JE7QETN1", "@type": "loan_terms", "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 50000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": false }, "has_mortgage_type": { "has_value": "conventional" } } ], "buydowns": [ { "@id": "01G0F46DMPWPA5VM805MXSH2KG", "@type": "buydown", "has_buydown_type": { "has_value": "one_zero" } } ], "mortgage_products": [ { "@id": "01G0F46DMQZZHDGDN4X8GMTKET", "@type": "pricing", "has_partner_name": { "has_value": "Optimal Blue" } }, { "@id": "01G0F46DMQ6NBC8PC4FPKP5QE7", "@type": "automated_underwriting_system", "has_credit_report_vendor_identifier": { "has_value": "" } }, { "@id": "01G0F456JR9HV6FFQ38NG63W8T", "@type": "credit" } ], "organizations": [ { "@id": "01G0F46DMPNP1Z0PD6B98BN92S", "@type": "servicer" }, { "@id": "01G0F43BRKFYQ6J0K5GJRYF2JB", "@type": "organization", "has_organization_name": { "has_value": "Amazon" } }, { "@id": "01G0F43BRK89FAZDRJZDC5DX0K", "@type": "customer", "has_transaction_identifier": { "has_value": "01G0F436Y4B8Z97ZZCX4PDENMF" } } ], "quote_requests": [ { "@id": "01G0F46DMP1A0WN0T89KDRKF5A", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_balloon_loans_indicator": { "has_value": false }, "include_loans_with_amortization_term": [ "01G0F46DMQRJJ7VVS4Y038BKNX" ] } ], "quote_amortization_terms": [ { "@id": "01G0F46DMQRJJ7VVS4Y038BKNX", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01G0F46DMPE0NJZ7XGRSZJEPM0", "@type": "subject_property", "has_construction_method_type": { "has_value": "site_built" }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "other" }, "has_stories_count": { "has_value": 1 }, "has_financed_unit_count": { "has_value": 1 }, "has_property_in_project_indicator": { "has_value": false }, "with_address": [ "01G0F46DMPB9Y8YNQN8BY1AZ1F" ], "with_sales_contract": [ "01G0F46DMQYRE9H69KXTEFW8KK" ], "with_value": [ "01G0F46DMQ917ABYDMNHH8BR61" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01G0F46DMPB9Y8YNQN8BY1AZ1F", "@type": "residential_address", "has_county_name": { "has_value": "Fort Bend" }, "has_state_code": { "has_value": "TX" } }, { "@id": "01G0F43BRJB7S9ZSS0Q4AXN357", "@type": "address", "has_address_line_1_text": { "has_value": "126 4th St" }, "has_address_line_2_text": { "has_value": "" }, "has_city_name": { "has_value": "Atlanta" }, "has_country_name": { "has_value": "US" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } }, { "@id": "01G0F456PEEXG5XWXDFNW8H5XY", "@type": "residential_address", "has_address_line_1_text": { "has_value": "126 4TH ST" }, "has_city_name": { "has_value": "ATLANTA" }, "has_postal_code": { "has_value": "30014" }, "has_state_code": { "has_value": "GA" } } ], "sales_contracts": [ { "@id": "01G0F46DMQYRE9H69KXTEFW8KK", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 500000 } } ], "property_valuations": [ { "@id": "01G0F46DMQ917ABYDMNHH8BR61", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 500000 } } ], "assets": [ { "@id": "01G0F43ERM91FT0DTAQ1J8FME3", "@type": "checking_account", "has_market_value_amount": { "has_value": 10000 }, "owned_by": [ "01G0F43BRK1SAPR67KC0J1NVQB" ] } ], "contact_information": [ { "@id": "01G0F43BRKGVC0X90BH7S6E8S0", "@type": "contact_information", "has_email_address": { "has_value": "test@email.com" }, "has_phone_number": { "has_value": "1231231232" } } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01G0F456QKHJP096X9CH9H0QAZ" ] } ], "credit_score_factors": [ { "@id": "01G0F45MHVRFPK6245AJ68T9MZ", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": "00030" }, "has_credit_score_factor_text": { "has_value": "TIME SINCE MOST RECENT ACCOUNT OPENING IS TOO SHORT" } }, { "@id": "01G0F45MHW2W46K8E0TTE3CC86", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": "00014" }, "has_credit_score_factor_text": { "has_value": "LENGTH OF TIME ACCOUNTS HAVE BEEN ESTABLISHED" } }, { "@id": "01G0F45MHWNRX3YABMXWX8QHE1", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": 8 }, "has_credit_score_factor_text": { "has_value": "TOO MANY INQUIRIES LAST 12 MONTHS" } }, { "@id": "01G0F45MHW9J9AR4T56XX2B6HK", "@type": "credit_score_factor", "has_credit_score_factor_code": { "has_value": "00012" }, "has_credit_score_factor_text": { "has_value": "LENGTH OF TIME REVOLVING ACCOUNTS HAVE BEEN ESTABLISHED" } } ], "credit_score_information": [ { "@id": "01G0F456QKHJP096X9CH9H0QAZ", "@type": "credit_score_information", "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_score": { "has_value": "00743" } } ], "declarations": [ { "@id": "01G0F43BRKNQKR7P36ZT59T2YX", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_intent_to_occupy_indicator": { "has_value": true }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false } } ], "documents": [ { "@id": "01G0F45MHWAWZKFCZHT7RCFR5B", "@type": "credit_report", "has_staircase_blob_identifier": { "has_value": "01G0F450M9J09JRC2G6CFAVMX8" } } ], "employment": [ { "@id": "01G0F43BRMG882TMY5F8S50GY8", "@type": "employment", "has_self_employment_indicator": { "has_value": false }, "provided_by": [ "01G0F43BRKFYQ6J0K5GJRYF2JB" ] } ], "housing_expenses_deprecated": [ { "@id": "01G0F43BRK4Z2GDQPHBJNSZS1M", "@type": "housing_expenses_deprecated", "has_present_first_mortgage_principal_and_interest_monthly_amount": { "has_value": 0 }, "has_present_first_mortgage_principal_interest_taxes_and_insurance_piti_monthly_amount": { "has_value": 0 }, "has_present_flood_insurance_monthly_amount": { "has_value": 0 }, "has_present_homeowners_association_dues_and_condominium_fees_monthly_amount": { "has_value": 0 }, "has_present_homeowners_insurance_monthly_amount": { "has_value": 0 }, "has_present_mortgage_insurance_monthly_amount": { "has_value": 0 }, "has_present_other_mortgage_loan_principal_and_interest_monthly_amount": { "has_value": 0 }, "has_present_other_mortgage_loan_principal_interest_taxes_and_insurance_monthly_amount": { "has_value": 0 }, "has_present_property_tax_monthly_amount": { "has_value": 0 }, "has_present_supplemental_property_insurance_monthly_amount": { "has_value": 0 }, "has_present_total_monthly_payment_amount": { "has_value": 0 } } ], "income": [ { "@id": "01G0F43DJT2A15SH870HJ2K5EX", "@type": "employment_income", "has_income_amount": { "has_value": 7500 }, "has_income_pay_frequency_type": { "has_value": "monthly" } }, { "@id": "01G0F43DJTH8BHZGVS31GBFSKV", "@type": "employment_income", "has_income_amount": { "has_value": 90000 }, "has_income_year": { "has_value": "2022" } } ], "liabilities": [ { "@id": "01G0F43BRK7WTG1SSEEJG143CF", "@type": "liability", "has_liability_payment_amount": { "has_value": 2000 }, "has_liability_unpaid_balance_amount": { "has_value": 2000 } } ], "people": [ { "@id": "01G0F43BRK1SAPR67KC0J1NVQB", "@type": "borrower", "contact_at": [ "01G0F43BRKGVC0X90BH7S6E8S0" ], "earns": [ "01G0F43DJTH8BHZGVS31GBFSKV", "01G0F43DJT2A15SH870HJ2K5EX" ], "has_birth_date": { "has_value": "1958-12-12" }, "has_first_name": { "has_value": "DAD" }, "has_last_name": { "has_value": "FIRSTIMER" }, "has_marital_status_type": { "has_value": "unmarried" }, "has_taxpayer_identifier_type": { "has_value": "individual_taxpayer_identification_number" }, "has_taxpayer_identifier_value": { "has_value": "000-000-001" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 25 }, "lives_at": [ "01G0F43BRKGDPCT3N1BHVVXPJ1" ], "owes_liability": [ "01G0F43BRK7WTG1SSEEJG143CF" ], "owns_asset": [ "01G0F43ERM91FT0DTAQ1J8FME3" ], "with_address": [ "01G0F43BRJB7S9ZSS0Q4AXN357" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ], "with_declaration": [ "01G0F43BRKNQKR7P36ZT59T2YX" ], "works_for": [ "01G0F43BRKFYQ6J0K5GJRYF2JB" ], "employed_as": [ "01G0F43BRMG882TMY5F8S50GY8" ] } ], "residences": [ { "@id": "01G0F43BRKGDPCT3N1BHVVXPJ1", "@type": "residence", "has_borrower_residency_type": { "has_value": "current" }, "has_residency_basis_type": { "has_value": "living_rent_free" }, "has_residency_duration_months_count": { "has_value": 30 }, "with_address": [ "01G0F43BRJB7S9ZSS0Q4AXN357" ] } ] } } ``` ##### Response 200400 UpdateCollectionError400 text/html403404 UpdateCollectionError404 text/html500 application/json Copy Collection updated successfully ``` { "transaction_id": "01F0KHK7DN3H5JZ4QJKMYAM6GB", "collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN", "metadata": { "created_at": "2021-09-14T03:08:00.284090-04:00", "validation": false }, "data": { "vendor_name": "optimalBlue", "request_data": { "people": [ { "@id": "01FDTQ5PJSKC94HHZGYZDSTXCT", "@type": "borrower", "has_first_name": { "has_value": "test" }, "has_last_name": { "has_value": "test1" }, "has_debt_expense_to_income_dti_ratio": { "has_value": 15 }, "employed_as": [ "01FDTQ5PGZWEG4M8PSR5T6TSYH" ], "with_declaration": [ "01FDTQ5PH0KQ21KE0DR3FV16SW" ], "with_credit_information": [ "01G0F456KV2YVD0N168SD8QTGD" ] } ], "credit_information": [ { "@id": "01G0F456KV2YVD0N168SD8QTGD", "@type": "credit_information", "has_credit_rating_code_type": { "has_value": "experian" }, "has_credit_report_action_type": { "has_value": "submit" }, "has_credit_report_first_issued_date": { "has_value": "2022-04-12" }, "has_credit_report_identifier": { "has_value": "DF6VM5" }, "has_credit_report_last_updated_date": { "has_value": "2022-04-12" }, "has_credit_report_merge_type": { "has_value": "blend" }, "has_credit_report_type": { "has_value": "merge" }, "has_credit_request_type": { "has_value": "individual" }, "with_credit_score_information": [ "01FDTQ5PH1J05ESN8F3M8X03MD" ] } ], "employment": [ { "@id": "01FDTQ5PGZWEG4M8PSR5T6TSYH", "@type": "employment", "has_self_employment_indicator": { "has_value": true } } ], "declarations": [ { "@id": "01FDTQ5PH0KQ21KE0DR3FV16SW", "@type": "declaration", "has_citizenship_residency_type": { "has_value": "us_citizen" }, "has_borrower_first_time_homebuyer_indicator": { "has_value": false }, "has_bankruptcy_indicator": { "has_value": false }, "has_age_of_bankruptcy_years_count": { "has_value": 0 }, "has_prior_property_foreclosure_completed_indicator": { "has_value": false }, "has_age_of_prior_property_foreclosure_years_count": { "has_value": 0 } } ], "credit_score_information": [ { "@id": "01FDTQ5PH1J05ESN8F3M8X03MD", "@type": "credit_score_information", "has_credit_score": { "has_value": "850" } } ], "loans": [ { "@id": "01FDTQ5PJQ6XNBSS84F65B3ZNZ", "@type": "loan", "has_relocation_loan_indicator": { "has_value": false }, "has_heloc_indicator": { "has_value": false }, "with_borrower": [ "01FDTQ5PJSKC94HHZGYZDSTXCT" ], "with_loan_terms": [ "01FDTQ5PJTJBJZ777RCH7TDF5J" ], "with_documentation": [ "01FDTQ5PJTMCWMQW9WYKSDT3FE" ], "with_summary": [ "01FDTQ5PJVWPHV0MBGEMS6QHZZ" ], "with_payment_information": [ "01FDTQ5PJXBVSW37ZTESFQWN4Y" ], "with_arm_adjustment": [ "01FDTQ5PJXSBQYT5X7EAS4H31S" ], "with_insurance": [ "01FDTQ5PJYNRA67MQEVTBZCRZ7" ], "with_project": [ "01FKTQ5PKC2ZFKXBEH170VG0BJ" ], "serviced_by": [ "01FDTQ5PKA5DVQ7F39HZK84H2R" ], "with_buydown": [ "01FDTQ5PKBF5JHM46TQQEE3SAE" ], "with_quote_request": [ "01FDTQ5PKBHV90N3GJ0PEK9TWD" ], "secured_by_property": [ "01FDTQ5PKC4ZFKXBET140VG0BJ" ] } ], "loan_terms": [ { "@id": "01FDTQ5PJTJBJZ777RCH7TDF5J", "@type": "loan_terms", "has_mortgage_type": { "has_value": "conventional" }, "has_pledged_assets_indicator": { "has_value": false }, "has_escrow_required_indicator": { "has_value": true }, "has_loan_purpose_type": { "has_value": "purchase" }, "has_refinance_type": { "has_value": "no_cash_out" }, "has_lien_position_type": { "has_value": "first_lien" }, "has_base_loan_amount": { "has_value": 150000 }, "has_interest_only_indicator": { "has_value": false }, "has_prepayment_penalty_indicator": { "has_value": false }, "has_prepayment_penalty_term_months_count": { "has_value": 0 }, "has_construction_loan_indicator": { "has_value": false }, "has_buydown_indicator": { "has_value": true } } ], "arm_adjustments": [ { "@id": "01FDTQ5PJXSBQYT5X7EAS4H31S", "@type": "arm_adjustment", "has_first_rate_adjustment_months_count": { "has_value": 60 } } ], "buydowns": [ { "@id": "01FDTQ5PKBF5JHM46TQQEE3SAE", "@type": "buydown", "has_buydown_type": { "has_value": "one_one" } } ], "insurance": [ { "@id": "01FDTQ5PJYNRA67MQEVTBZCRZ7", "@type": "mortgage_insurance", "has_mortgage_insurance_premium_source_type": { "has_value": "borrower" } } ], "loan_documentation": [ { "@id": "01FDTQ5PJTMCWMQW9WYKSDT3FE", "@type": "loan_documentation", "has_asset_documentation_level_type": { "has_value": "stated_and_verified" }, "has_employment_documentation_level_type": { "has_value": "stated_and_verified" }, "has_income_documentation_level_type": { "has_value": "stated_and_verified" } } ], "loan_summaries": [ { "@id": "01FDTQ5PJVWPHV0MBGEMS6QHZZ", "@type": "loan_summary", "has_total_debt_expense_to_income_dti_ratio": { "has_value": 18 }, "has_total_monthly_income_amount": { "has_value": 0 }, "has_projected_reserves_amount": { "has_value": 24 }, "has_representative_credit_score": { "has_value": 850 } } ], "loan_payment_information": [ { "@id": "01FDTQ5PJXBVSW37ZTESFQWN4Y", "@type": "loan_payment_information", "has_number_of_payments_30_days_late_count": { "has_value": 0 }, "has_number_of_payments_60_days_late_count": { "has_value": 0 }, "has_number_of_payments_90_days_late_count": { "has_value": 0 }, "has_number_of_payments_120_days_late_count": { "has_value": 0 }, "has_number_of_payments_rolling_12_months_late_count": { "has_value": 0 } } ], "organizations": [ { "@id": "01FDTQ5PKA5DVQ7F39HZK84H2R", "@type": "servicer" } ], "quote_requests": [ { "@id": "01FDTQ5PKBHV90N3GJ0PEK9TWD", "@type": "loan_price_quote_request", "has_loan_officer_compensation_type": { "has_value": "yes_lender_paid" }, "has_calculate_borrower_requested_loan_amount_indicator": { "has_value": true }, "has_include_fixed_rate_amortization_loans_indicator": { "has_value": true }, "has_include_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_include_payment_option_adjustable_rate_amortization_loans_indicator": { "has_value": false }, "has_discount_points_percent": { "has_value": 0 }, "has_include_balloon_loans_indicator": { "has_value": false }, "has_cash_out_amount": { "has_value": 0 }, "include_loans_with_amortization_term": [ "01FDTQGB8WJHJC9YT32CQ1ESCC" ] } ], "quote_amortization_terms": [ { "@id": "01FDTQGB8WJHJC9YT32CQ1ESCC", "@type": "quote_amortization_term", "has_amortization_term_months_count": { "has_value": 360 } } ], "properties": [ { "@id": "01FDTQ5PKC4ZFKXBET140VG0BJ", "@type": "subject_property", "has_property_usage_type": { "has_value": "primary_residence" }, "has_number_of_units_type": { "has_value": "one" }, "has_project_design_type": { "has_value": "midrise_project" }, "has_manufactured_home_indicator": { "has_value": false }, "has_planned_unit_development_pud_indicator": { "has_value": false }, "has_manufactured_home_width_type": { "has_value": "single_wide" }, "has_project_usage_type": { "has_value": "string" }, "has_financed_unit_count": { "has_value": 1 }, "has_non_warrantable_project_indicator": { "has_value": false }, "has_stories_count": { "has_value": 1 }, "has_construction_method_type": { "has_value": "site_built" }, "with_address": [ "01FDTQGB9EV6FKWGZ2CY35971G" ], "with_sales_contract": [ "01FDTQGB9EPKV6EJXZMTW0CGV0" ], "with_value": [ "01FDTQGB9FVMF9YTFBTX95D2KH" ] } ], "projects": [ { "@id": "01FKTQ5PKC2ZFKXBEH170VG0BJ", "@type": "project", "has_project_legal_structure_type": { "has_value": "condominium" } } ], "addresses": [ { "@id": "01FDTQGB9EV6FKWGZ2CY35971G", "@type": "residential_address", "has_address_line_1_text": { "has_value": "string" }, "has_county_name": { "has_value": "Collin" }, "has_state_code": { "has_value": "TX" }, "has_postal_code": { "has_value": "75024" } } ], "sales_contracts": [ { "@id": "01FDTQGB9EPKV6EJXZMTW0CGV0", "@type": "property_sales_contract", "has_sales_contract_amount": { "has_value": 225000 } } ], "property_valuations": [ { "@id": "01FDTQGB9FVMF9YTFBTX95D2KH", "@type": "property_valuation", "has_property_valuation_amount": { "has_value": 225000 } } ] } } } ``` application/json Copy Error ``` { "description": "Error details.", "message": "Unable to update collection. Please check the collection\ndata" } ``` text/html Copy Error ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy 403 invalid error ``` { "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" } ``` application/json Copy Resource not found ``` { "message": "Unable to update collection. Please check the given ids" } ``` text/html Copy Resource not found ``` \r\n400 Bad Request\r\n\r\n

400 Bad Request

\r\n\r\n\r\n ``` application/json Copy Internal server error ``` { "message": "The product has encountered an internal server error. If you\nhave used a transaction_id to call our services, please submit it to\nStaircase support" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | — | Environment API Key. | | `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | Staircase Transaction Identifier | | `collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | Staircase collection_id | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data` | `object` | The data that is needed for invocation. It should follow the request schema | | `people` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_first_name`required | `object` | — | | `has_value`required | `string` | — | | `has_last_name`required | `object` | — | | `has_value`required | `string` | — | | `has_debt_expense_to_income_dti_ratio`required | `object` | — | | `has_value`required | `number` | — | | `employed_as`required | `string[]` | — | | `with_declaration`required | `string[]` | — | | `with_credit_information`required | `string[]` | — | | `employment` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_self_employment_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `declarations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_citizenship_residency_type`required | `object` | — | | `has_value`required | `string` | `non_permanent_resident_alien``non_resident_alien``permanent_resident_alien``us_citizen` | | `has_borrower_first_time_homebuyer_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_bankruptcy_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_age_of_bankruptcy_years_count` | `object` | — | | `has_value`required | `integer` | — | | `has_prior_property_foreclosure_completed_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_age_of_prior_property_foreclosure_years_count` | `object` | — | | `has_value`required | `integer` | — | | `credit_score_information` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_credit_score`required | `object` | — | | `has_value`required | `string` | — | | `loans`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_relocation_loan_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `with_borrower`required | `string[]` | — | | `with_loan_terms`required | `string[]` | — | | `with_documentation`required | `string[]` | — | | `with_summary`required | `string[]` | — | | `with_payment_information`required | `string[]` | — | | `with_arm_adjustment`required | `string[]` | — | | `with_insurance`required | `string[]` | — | | `with_project`required | `string[]` | — | | `serviced_by`required | `string[]` | — | | `with_buydown`required | `string[]` | — | | `with_quote_request`required | `string[]` | — | | `secured_by_property`required | `string[]` | — | | `has_heloc_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `loan_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_pledged_assets_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_mortgage_type`required | `object` | — | | `has_value`required | `string` | `conventional``fha``local_agency``other``public_and_indian_housing``state_agency``usda-rd``va` | | `has_escrow_required_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_loan_purpose_type`required | `object` | — | | `has_value`required | `string` | `other``purchase``refinance` | | `has_refinance_type`required | `object` | — | | `has_value`required | `string` | `cash_out``limited_cash_out``no_cash_out` | | `has_lien_position_type`required | `object` | — | | `has_value`required | `string` | `first_lien``second_lien``subordinate_lien` | | `has_base_loan_amount`required | `object` | — | | `has_value`required | `number` | — | | `has_interest_only_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_prepayment_penalty_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_prepayment_penalty_term_months_count`required | `object` | — | | `has_value`required | `integer` | — | | `has_construction_loan_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_buydown_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `arm_adjustments` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_first_rate_adjustment_months_count`required | `object` | — | | `has_value`required | `integer` | — | | `buydowns`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_buydown_type`required | `object` | — | | `has_value`required | `string` | `one_one``one_zero``three``two_one` | | `insurance`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_mortgage_insurance_premium_source_type`required | `object` | — | | `has_value`required | `string` | `borrower``lender` | | `loan_documentation`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_asset_documentation_level_type`required | `object` | — | | `has_value`required | `string` | `neither_stated_nor_verified``not_required``stated_and_verified``stated_only` | | `has_employment_documentation_level_type`required | `object` | — | | `has_value`required | `string` | `neither_stated_nor_verified``not_required``stated_and_verified``stated_only` | | `has_income_documentation_level_type`required | `object` | — | | `has_value`required | `string` | `neither_stated_nor_verified``not_required``stated_and_verified``stated_only` | | `loan_summaries`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_total_debt_expense_to_income_dti_ratio`required | `object` | — | | `has_value`required | `number` | — | | `has_total_monthly_income_amount` | `object` | — | | `has_value`required | `number` | — | | `has_projected_reserves_amount` | `object` | — | | `has_value`required | `number` | — | | `has_representative_credit_score`required | `object` | — | | `has_value`required | `integer` | — | | `loan_payment_information` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_number_of_payments_30_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_60_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_90_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_120_days_late_count` | `object` | — | | `has_value`required | `integer` | — | | `has_number_of_payments_rolling_12_months_late_count` | `object` | — | | `has_value`required | `integer` | — | | `organizations` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_organization_name` | `object` | — | | `has_value`required | `string` | — | | `quote_requests`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_loan_officer_compensation_type`required | `object` | — | | `has_value`required | `string` | `no_buyer_paid``no_lender_paid``yes_lender_paid` | | `has_calculate_borrower_requested_loan_amount_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_include_fixed_rate_amortization_loans_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_include_adjustable_rate_amortization_loans_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_include_payment_option_adjustable_rate_amortization_loans_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_discount_points_percent` | `object` | — | | `has_value`required | `number` | — | | `has_include_balloon_loans_indicator` | `object` | — | | `has_value`required | `boolean` | — | | `has_cash_out_amount` | `object` | — | | `has_value`required | `number` | — | | `include_loans_with_amortization_term` | `string[]` | — | | `quote_amortization_terms`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_amortization_term_months_count`required | `object` | — | | `has_value`required | `integer` | — | | `properties`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_property_usage_type`required | `object` | — | | `has_value`required | `string` | `investment``other``primary_residence``second_home` | | `has_number_of_units_type`required | `object` | — | | `has_value`required | `string` | `four``one``three``two``two_to_four` | | `has_project_design_type`required | `object` | — | | `has_value`required | `string` | `garden_project``highrise_project``midrise_project``other``townhouse_rowhouse` | | `has_planned_unit_development_pud_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_manufactured_home_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `has_manufactured_home_width_type`required | `object` | — | | `has_value`required | `string` | — | | `has_project_usage_type`required | `object` | — | | `has_value`required | `string` | — | | `has_stories_count`required | `object` | — | | `has_value`required | `integer` | — | | `has_construction_method_type`required | `object` | — | | `has_value`required | `string` | `manufactured``mobile_home``modular``on_frame_modular``other``site_built` | | `has_financed_unit_count`required | `object` | — | | `has_value`required | `integer` | — | | `has_non_warrantable_project_indicator`required | `object` | — | | `has_value`required | `boolean` | — | | `with_address`required | `string[]` | — | | `with_sales_contract`required | `string[]` | — | | `with_value`required | `string[]` | — | | `projects` | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_project_legal_structure_type`required | `object` | — | | `has_value`required | `string` | `common_interest_apartment``condominium``cooperative``unknown` | | `addresses`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_county_name` | `object` | Required if the address is for the subject property | | `has_value`required | `string` | — | | `has_state_code`required | `object` | — | | `has_value`required | `string` | — | | `has_city_name` | `object` | — | | `has_value`required | `string` | — | | `has_postal_code` | `object` | — | | `has_value`required | `string` | — | | `has_address_line_1_text` | `object` | — | | `has_value`required | `string` | — | | `sales_contracts`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_sales_contract_amount`required | `object` | — | | `has_value`required | `number` | — | | `property_valuations`required | `object[]` | — | | `@id`required | `string` | — | | `@type`required | `string` | — | | `has_property_valuation_amount`required | `object` | — | | `has_value`required | `number` | — | ##### Response `200``application/json` 4 fields Collection updated successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string (ulid)` | Transaction ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `collection_id` | `string (ulid)` | Collection ID.Example `01EZQ32PJQGKRA6HR8D72Q9FFF` | | `data` | `object` | Data in Staircase language schema. | | `metadata` | `object` | Metadata about collection, f.e version of used Staircase schema. | ##### Response `400``application/json` 1 fields Error | Field | Type | Description | | --- | --- | --- | | `message` | `one of` | Either message object with more properties. | ##### Response `403``application/json` 2 fields 403 invalid error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | | `url` | `string` | Error additional URL. | ##### Response `404``application/json` 1 fields Resource not found | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `500``application/json` 1 fields Internal server error | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message. | ##### Other responses `405` ### Operations `POST` `/pricing` #### Create Pricing `post-pricing` Create Pricing creates views of scenario-specific pricing, best pricing alternatives, and side-by-side price comparisons from various products and partners. ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Pricing request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Pricing request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ## Providers - Optimal Blue ## Errors `400``403``404``405``422``500` ## More in Contract - Previous product: Notary - Next product: Signature --- # Signature # Signature Electronic signature ceremonies over the closing package: who signs what, in what order, and what comes back. A caller sends the documents and the signer set. The product creates the ceremony, tracks each signer's progress, and returns the executed package with its certificate. Signing order matters and is declared rather than inferred. Some documents require a specific sequence between borrower, coborrower and settlement agent, and a ceremony that lets them sign in any order produces a package a closer has to reject. ## Operations ### Operations `POST` `/` #### Create eSign `post-esign` Create eSign invokes a data partner to electronically sign a document. To invoke Create eSign, you will need: - a transaction_id, and - a collection_id. Once you have a transaction_id and collection_id, simply invoke Create eSign with your transaction_id, collection_id and a data partner name. Create eSign returns, as a synchronous acknowledgement, a new collection_id. The new collection_id represents an empty container which will hold the data partner's response once processing has completed. Data partners: HelloSign, Notarize, HelloFax, DocuSign, NotaryCam, eOriginal, Escrow Tab, Nexsys, OneSpan ##### Request Exampleapplication/json application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "hellosign" } ``` application/json Copy ``` { "transaction_id": "", "collection_id": "", "partner_name": "hellosign" } ``` ##### Response application/json Copy eSign request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | | `Content-Type` required | `string` header | — | — | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields eSign request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | ##### Other responses `400``404` `POST` `/blobs` #### Create Blob `post-esign-blob` Create Blob creates a blob in Staircase. A Binary Large Object (blob) is a collection of binary data stored as a single entity. Typically it represents a document, image or other multimedia object. To invoke a partner product for eSign, you must first create a blob for your document. The presigned URL, which is returned as a response, represents a container in Staircase for your document. A presigned URL expires one hour after creation. ##### Request application/json Copy ``` { "extension": ".pdf" } ``` ##### Response application/json Copy Blob created successfully ``` { "blob_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3", "extension": ".pdf", "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/a34c40a6-3c02-44f9-a696-cd7388f506d3" } } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | | `Content-Type` required | `string` header | — | — | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `extension`required | `string` | Document extension | ##### Response `201``application/json` 3 fields Blob created successfully | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string` | Blob ID | | `extension` | `string` | File extension | | `presigned_urls` | `object` | Presigned URL | ##### Other responses `400` `GET` `/blobs/{blob_id}` #### Retrieve Blob `get-esign-blob` Retrieve Blob retrieves, for a given blob_id, presigned URLs for uploading and downloading the blob to and from Staircase. ##### Response application/json Copy Blob retrieved successfully ``` { "blob_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3", "extension": ".pdf", "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/8u7z6t5r-3c02-44f9-a696-cd7388f506d3" } } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (uuid)` path | `7b95d83e-205b-4610-b199-a4843fcb7027` | Blob ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 3 fields Blob retrieved successfully | Field | Type | Description | | --- | --- | --- | | `blob_id` | `string` | Blob ID | | `extension` | `string` | File extension | | `presigned_urls` | `object` | Presigned URL | ##### Other responses `400``404` `GET` `/blobs/{blob_id}/presigned-urls` #### Retrieve Presigned URLs `post-esign-presigned-urls` Retrieve Presigned URLs retrieves, for a given blob_id, presigned URLs for uploading and downloading the blob to and from Staircase. ##### Response application/json Copy Presigned urls retrieved successfully ``` { "presigned_urls": { "download": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/a34c40a6-3c02-44f9-a696-cd7388f506d3" }, "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/8u7z6t5r-3c02-44f9-a696-cd7388f506d3" } } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (uuid)` path | `7b95d83e-205b-4610-b199-a4843fcb7027` | Blob ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Presigned urls retrieved successfully | Field | Type | Description | | --- | --- | --- | | `presigned_urls` | `object` | — | ##### Other responses `400``404` `GET` `/blobs/{blob_id}/presigned-urls/{action}` #### Retrieve Presigned URL for Action `get-esign-presigned-url-for-action` Retrieve Presigned URL for Action retrieves a presigned url for a specific action. An action can be download or upload. ##### Response application/json Copy Presigned url retrieved successfully ``` { "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/a34c40a6-3c02-44f9-a696-cd7388f506d3" } } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (uuid)` path | `9aa12c27-4a36-4ea9-91d0-6342aaa18a05` | Blob ID | | `action` required | `string` path | `upload` | Possible actions: - upload - download | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Presigned url retrieved successfully | Field | Type | Description | | --- | --- | --- | | `presigned_urls` | `object` | — | ##### Other responses `400``404` `PUT` `/blobs/{blob_id}/presigned-urls/{action}` #### Create Presigned URL `put-esign-presigned-url-for-action` Create Presigned URL creates a presigned URL in Staircase. The presigned URL is used to upload or download a blob (document). It expires one hour after creation. ##### Response application/json Copy Presigned URL successfully created. ``` { "presigned_urls": { "upload": { "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/8u7z6t5r-3c02-44f9-a696-cd7388f506d3" } } } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (uuid)` path | `a34c40a6-3c02-44f9-a696-cd7388f506d3` | Blob identifier | | `action` required | `string` path | `upload` | Possible actions: - upload - download | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Response `200``application/json` 1 fields Presigned URL successfully created. | Field | Type | Description | | --- | --- | --- | | `presigned_urls` | `object` | — | ##### Other responses `400``404` `POST` `/blobs/upload/{blob_id}` #### Upload Blob `post-esign-upload-blob` Upload Blob uploads a document (blob) to a presigned URL via the HTML Request Maker Try It Out. Paste your Authorization Key into the request header, change the request body content type to binary, and browse to your document. This endpoint should be used in the HTML Request Maker Try it Out only. To upload a document within code, you need to use upload presigned URL returned in the Create Blob response body. ``` import requests # Create Blob endpoint returns blob_id and upload presigned url presigned_url = "" payload = request.get_data headers = { 'Content-Type': 'application/pdf' } response = requests.put(url=presigned_url, headers=headers, data=payload) print(response.text.encode('utf8')) ``` ##### Request application/octet-stream Copy ``` Select option 'binary' in order to upload file ``` ##### Response 200400 application/json Copy Upload blob success message ``` { "message": "Document has been uploaded successfully!" } ``` application/json Copy Blob upload failed ``` { "message": "Error uploading a document!" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `blob_id` required | `string (uuid)` path | `7c95d83e-215b-4610-b199-a4843fcb7027` | Blob ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Upload blob success message | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Response `400``application/json` 1 fields Blob upload failed | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Message | ##### Other responses `403``404` `POST` `/build-payload` #### Retrieve Product Elements Structure `get-esign-translate-elements` Retrieve Product Elements Structure retrieves a json schema for either: - a collection used as part of a request for eSign, or - a collection returned as part of response containing an electronically signed document. To retrieve the schema needed for a collection that is part of a request for eSign: Show the rest 1. Invoke Retrieve Request Elements to get an array of eSign request elements. 1. Place the output from Retrieve Request Elements into the Retrieve Product Elements Structure request body. 1. Place your api_key into the Retrieve Product Elements Structure header. 1. Send the request to Retrieve Product Elements Structure. You will receive a well-formed json schema in response, with null values that must be replaced with your own. To review the response schema that contains the electronic signature provided by an eSign data partner: 1. Invoke Retrieve Response Elements to get an array of eSign response elements. 1. Place the output from Retrieve Response Elements into the Retrieve Product Elements Structure request body. 1. Place your api_key into the Retrieve Product Elements Structure header. 1. Send the request to Retrieve Product Elements Structure. You will receive a well-formed json schema in response, with null values that will be replaced by the data partner upon return of the electronically signed document. ##### Request Exampleapplication/json application/json Copy ``` { "$.document_sets.document_set[0].documents.document[0].content.foreign_object.reference.location_label_value": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea", "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].allow_decline": true, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].name": "John", "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].email": "Doe" } ``` application/json Copy ``` { "$.document_sets.document_set[0].documents.document[0].content.foreign_object.reference.location_label_value": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].name": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].email": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].allow_decline": null } ``` ##### Response application/json Copy Elements retrieved successfully. ``` { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "" } } }, "signatories": { "signatory": [ { "allow_decline": "", "signees": { "signee": [ { "name": "", "email": "" } ] } } ] } } ] } } ] } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | | `Content-Type` required | `string` header | — | — | ##### Other responses `200``400``403` `POST` `/embedded-document-urls` #### Create eSign Embedded Document Urls `post-esign-embedded-document-urls` Initiate process for generating embedded document urls ##### Request Exampleapplication/json application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35" } ``` application/json Copy ``` { "transaction_id": "", "collection_id": "" } ``` ##### Response application/json Copy eSign embedded document urls request created successfully. ``` { "request_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | | `Content-Type` required | `string` header | — | — | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | ##### Response `202``application/json` 1 fields eSign embedded document urls request created successfully. | Field | Type | Description | | --- | --- | --- | | `request_id` | `string` | Request ID | ##### Other responses `404``406` `GET` `/embedded-document-urls/{request_id}` #### Retrieve eSign Embedded Document URLs `get-esign-embedded-document-urls` Retireve embedded document URLs ##### Response application/json Copy Embedded document urls retrieved successfully. ``` { "signatures": [ { "signer_name": "name1", "signer_email_address": "name1@test.com", "sign_url_data": { "sign_url": "https://sign_url_name1_example.com", "expires_at": 1605023817 } }, { "signer_name": "name2", "signer_email_address": "name2@test.com", "sign_url_data": { "sign_url": "https://sign_url_name2_example.com", "expires_at": 1605023817 } } ] } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `request_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Embedded document urls retrieved successfully. | Field | Type | Description | | --- | --- | --- | | `signatures` | `array` | signatures | ##### Other responses `202``400``404` `GET` `/request-elements` #### Retrieve Request Elements `get-esign-request-elements` Retrieve Request Elements retrieves a list of elements needed to invoke a data partner for eSign. ##### Response application/json Copy Elements needed for request. ``` { "$.document_sets.document_set[0].documents.document[0].content.foreign_object.reference.location_label_value": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].allow_decline": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].name": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].email": null } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Other responses `200``400` `POST` `/request-elements/complete` #### Validate Collection `post-esign-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a data partner for eSign. ##### Request Exampleapplication/json application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "7f7703df-5653-4697-beb3-d716c185fc25" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "Jon Snow", "email": "jon.snow@hbo.com" } ] } } ] } } ] } } ] } } } ``` application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": null } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": null, "email": null } ] } } ] } } ] } } ] } } } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | | `Content-Type` required | `string` header | — | — | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | ##### Response `400``application/json` 2 fields Missing elements | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/response-elements` #### Retrieve Response Elements `get-esign-response-elements` Retrieve Response Elements retrieves a list of the electronic signature elements returned by an eSign data partner. ##### Response application/json Copy Elements needed for request. ``` { "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].electronic_signature.foreign_object.location_label_value": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].is_complete": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].is_rejected": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].name": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].email": null, "$.document_sets.document_set[0].documents.document[0].signatories.signatory[0].signees.signee[0].status": null } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Other responses `200``400` `GET` `/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-esign-status` Retrieve Status determines if a data partner has executed an eSignature for a document. ##### Response 200404 application/json Copy Statuses include: * REQUEST_MADE

* WAITING_FOR_SIGNATURES

* COMPLETED

* ERROR ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (uuid)` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string (uuid)` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* WAITING_FOR_SIGNATURES

* COMPLETED

* ERROR | Field | Type | Description | | --- | --- | --- | | `status` | `string` | Current execution status`WAITING_FOR_SIGNATURES``COMPLETED``ERROR``REQUEST_MADE` | ##### Response `404``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | ##### Other responses `400``403` `POST` `/transactions` #### Create Transaction `post-esign-transaction` Create Transaction creates a transaction in Staircase. Transactions in Staircase are containers for all of the data related to an instance of a transaction type. They enable you to correlate the output of various products to a single transaction type, where the transaction type depends on your line of business. Transactions are identified by a unique key called transaction_id. As you use different Staircase products to gather the data needed for a specific instance of your transaction type, and receive different sets of output from each product, use the same transaction_id to correlate all of the outputs to the same transaction. A transaction_id, when used properly, gives you a holistic view of the data related to the transaction you’ve assembled. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `201``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | ##### Other responses `400` `GET` `/transactions/{transaction_id}/collections` #### Retrieve Transaction Collections `get-esign-transactions-collections` Retrieve Transaction Collections retrieves a list of all collections associated with a transaction. ##### Response 200400 application/json Copy Transaction's list of collections successfully retrieved. ``` { "collections": [ { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "7f7703df-5653-4697-beb3-d716c185fc25" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "Jon Snow", "email": "jon.snow@hbo.com" } ] } } ] } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" }, { "collection_id": "b441470e-007c-4221-83c6-88db7e7594e0", "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "John Doe", "email": "john.doe@example.com" } ] } } ] } } ] }, "metadata": {} } ] } }, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ] } ``` application/json Copy Data validation request failed ``` { "error": "Error creating collection.", "status_code": 400, "status_message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (uuid)` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Response `200``application/json` 1 fields Transaction's list of collections successfully retrieved. | Field | Type | Description | | --- | --- | --- | | `collections` | `array` | Data object | ##### Response `400``application/json` 3 fields Data validation request failed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | | `status_code` | `integer` | Status code | | `status_message` | `string` | Status message | ##### Other responses `404` `POST` `/transactions/{transaction_id}/collections` #### Create Collection `post-esign-collection` Create Collection creates a collection of elements required for eSign. A collection contains a digital representation of a document and is identified by collection_id. The collection, rather than a document, is passed to a data partner when requesting an electronic signature. Before you can create a document collection, make sure you have: - an api_key (authorization key), received via email when you signed up for Staircase. - a transaction_id,created by invoking Create Transaction. To create a document collection and receive a collection_id in response, you first need to complete 2 tasks: Show the rest 1. Upload your document to Staircase, and 1. Create a json schema that describes a document. To upload a document to Staircase: 1. Create a blob by invoking Create Blob. The blob is a container for your document, and is represented by a blob_id, which is returned by the service. 1. Upload your document (blob) to Staircase, using your blob_id. See Upload Blob for more detail. There are a couple of ways you can create a json schema that describes a document: 1. Copy the example json schema given below for the request body, and insert your blob_id into the location_label_value schema element, or 1. Invoke Retrieve Product Elements Structure to get an example json schema. Insert your blob_id into the location_label_value schema element. Once you have created a collection, you can send it, along with your api_key and transaction_id, to as many eSign data partners as you want. ##### Request Exampleapplication/json application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "a7b098f5-e2d4-4c97-901c-e2abefcbc5dc" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "Jon Snow", "email": "jon.snow@hbo.com" } ] } } ] } } ] } } ] } } } ``` application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "", "email": "" } ] } } ] } } ] } } ] } } } ``` ##### Response application/json Copy Data validation request failed ``` { "error": "Error creating collection.", "status_code": 400, "status_message": "{'data': ['Missing data for required field.']}" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (uuid)` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | | `Content-Type` required | `string` header | — | — | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `201``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | | `collection_id` | `string` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | ##### Response `400``application/json` 3 fields Data validation request failed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | | `status_code` | `integer` | Status code | | `status_message` | `string` | Status message | ##### Other responses `403``404` `GET` `/transactions/{transaction_id}/collections/{collection_id}` #### Retrieve Collection `get-esign-collection` Retrieve Collection retrieves a collection containing a document that has been electronically signed. ##### Response application/json Copy Collection retrieved successfully ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "Jon Snow", "email": "jon.snow@hbo.com" } ] } } ] } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (uuid)` path | `7b95d83e-105b-4610-c199-a4843fcb7027` | Transaction ID | | `collection_id` required | `string (uuid)` path | `9aad2227-4a36-5ea9-91d0-6342aaa18a05` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 4 fields Collection retrieved successfully | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | | `collection_id` | `string` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | ##### Response `400``application/json` 3 fields Data validation request failed | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | | `status_code` | `integer` | Status code | | `status_message` | `string` | Status message | ##### Other responses `403``404` `PUT` `/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-esign-collection` Update Collection updates a collection of elements required for an electronic signature. ##### Request Exampleapplication/json application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "a7b098f5-e2d4-4c97-901c-e2abefcbc5dc" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "Jon Snow", "email": "jon.snow@hbo.com" } ] } } ] } } ] } } ] } } } ``` application/json Copy ``` { "data": { "document_sets": { "document_set": [ { "documents": { "document": [ { "content": { "foreign_object": { "reference": { "location_label_value": "" } } }, "signatories": { "signatory": [ { "allow_decline": true, "signees": { "signee": [ { "name": "", "email": "" } ] } } ] } } ] } } ] } } } ``` ##### Parameters 4 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string (uuid)` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string (uuid)` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | | `Content-Type` required | `string` header | — | — | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | | `collection_id` | `string` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | ##### Other responses `400``403``404` ## Errors `400``403``404``406` ## More in Contract - Previous product: Price - Next product: Title --- # Title # Title Title search, insurance ordering, underwriting normalisation, and transfer coordination. The title question splits into an ordering step and a reading step. Ordering places the search and the insurance commitment with an underwriter; reading turns the returned commitment into structured requirements and exceptions the rest of the file can act on. Field-level checking of the returned commitment is the dual-listed slot, Title under Validation. The operations below come from a service that routes several closing-side products under one contract, which is why title search, title insurance and the document set sit next to each other in one namespace rather than in three. ## Dual listing Title is filed under two categories. The other listing is Title under Validation, and neither listing carries a recorded specification. ## Operations ### Operations `POST` `/title` #### Create Title `post-title` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Title request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Title request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `POST` `/title-insurance` #### Create Title Insurance `post-title-insurance` ##### Request application/json Copy ``` { "transaction_id": "uhz6t54e-9d74-g17e-99ca-a36b30vdfd35", "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "partner_name": "PartnerName" } ``` ##### Response application/json Copy Title Insurance request created successfully. ``` { "collection_id": "e4502ed2-8df8-4b8f-84bd-a1097e999a77", "message": "When ready, data will be available under the following collection_id. Use this new collection_id to get the execution status." } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 3 fields | Field | Type | Description | | --- | --- | --- | | `transaction_id`required | `string` | Transaction ID | | `collection_id`required | `string` | Collection ID | | `partner_name`required | `string` | — | ##### Response `200``application/json` 2 fields Title Insurance request created successfully. | Field | Type | Description | | --- | --- | --- | | `collection_id` | `string` | Collection ID | | `message` | `string` | Message | `GET` `/title-insurance/elements` #### Retrieve Elements `get-title-insurance-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request. | Field | Type | Description | | --- | --- | --- | | `elements` | `object` | List of elements | `POST` `/title-insurance/elements/complete` #### Validate Collection `post-title-insurance-collection-complete` Validate Collection validates that a collection contains all of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 1 fields | Field | Type | Description | | --- | --- | --- | | `collection`required | `object` | — | ##### Response `400``application/json` 2 fields Collection is invalid. | Field | Type | Description | | --- | --- | --- | | `message` | `string` | Error message | | `errors` | `object` | List of elements that are missing | ##### Other responses `200` `GET` `/title-insurance/status/{transaction_id}/{collection_id}` #### Retrieve Status `get-title-insurance-status` Retrieve Status checks status of your request. Possible statuses: - REQUEST_MADE - REQUEST_ACCEPTED - WAITING_FOR_RESPONSE - COMPLETED ##### Response 200400 application/json Copy Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED ``` { "status": "COMPLETED" } ``` application/json Copy Status is unavailable ``` { "error": "Request for specified transaction_id and collection_id was not found!" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `9u8z7t65-cb71-4f20-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `e4502ed2-8df8-4b8f-84bd-a1097e999a77` | Collection ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Statuses include: * REQUEST_MADE

* REQUEST_ACCEPTED

* WAITING_FOR_RESPONSE

* COMPLETED | Field | Type | Description | | --- | --- | --- | | `status` | `object` | Current execution status | ##### Response `400``application/json` 1 fields Status is unavailable | Field | Type | Description | | --- | --- | --- | | `error` | `string` | Error message | `POST` `/title-insurance/transactions` #### Create Transaction `post-title-insurance-transaction` Create Transaction creates a transaction in Staircase. A transaction in Staircase is an acknowledgement that you want to call a Staircase product. It's a container for everything associated with that product invocation, and is correlated with a collection related to the product (e.g. a document). You need to create a new transaction every time you want to connect with a Staircase product. Staircase then associates everything, from a data and API execution standpoint, to that transaction. ##### Response application/json Copy Transaction successfully created. ``` { "transaction_id": "a34c40a6-3c02-44f9-a696-cd7388f506d3" } ``` ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Transaction successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `string` | Transaction ID | `POST` `/title-insurance/transactions/{transaction_id}/collections` #### Create Collection `post-title-insurance-collection` Create Collection creates a collection of elements . The elements within the collection are required. ##### Request application/json Copy ``` { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully created. ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "elements": { "element": [ { "property_entry": { "property_entries": { "datetime": "2020-08-25", "description": "Description of property", "event_type": "TestType" } }, "property_class": { "property_clases": { "type": "STATEMENT" }, "name": "Test", "period_start_date": "2020-07-01", "period_end_date": "2020-07-31" }, "content": { "foreign_object": "7e62ce76-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 2 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully created. | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `PUT` `/title-insurance/transactions/{transaction_id}/collections/{collection_id}` #### Update Collection `put-title-insurance-collection` Update Collection updates a collection of elements by new elements. ##### Request application/json Copy ``` { "sets": { "set": [ { "properties": { "property": [ { "propety_entry": { "propety_entries": { "datetime": "2020-05-05", "description": "Test Description", "event_type": "TestType" } }, "propety_class": { "propety_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } } ``` ##### Response application/json Copy Collection successfully updated ``` { "collection_id": "hg62e49f-9d74-g17e-99ca-a36b30vdfd35", "data": { "sets": { "set": [ { "properties": { "property": [ { "property_data": { "property_class": { "datetime": "2020-05-05", "description": "Info", "event_type": "TestEvent" } }, "document_classification": { "document_classes": { "type": "TestType" }, "name": "TestName", "period_start_date": "2019-01-01", "period_end_date": "2019-12-31" }, "content": { "foreign_object": "7z6t5r4e-d93d-4f31-92d3-45c2cb8255ea" } } ] } } ] } }, "metadata": {}, "transaction_id": "6t5r4wq1-9d74-g17e-99ca-a36b30vdfd35" } ``` ##### Parameters 3 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `transaction_id` required | `string` path | `3wet53r4-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `collection_id` required | `string` path | `9u8z7t65-cb71-8u74-8e40-7a829b52e91e` | Transaction ID | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | API Key | ##### Request body`application/json` 2 fields | Field | Type | Description | | --- | --- | --- | | `data`required | `object` | — | | `metadata` | `object` | — | ##### Response `200``application/json` 4 fields Collection successfully updated | Field | Type | Description | | --- | --- | --- | | `transaction_id` | `object` | Transaction ID | | `collection_id` | `object` | Collection ID | | `data` | `object` | Data object | | `metadata` | `object` | Metadata object | `GET` `/title/elements` #### Retrieve Elements `get-title-elements` Retrieve Elements provides a list of the elements needed to invoke a partner product. ##### Parameters 1 | Parameter | Type | Example | Description | | --- | --- | --- | --- | | `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | Authorization key | ##### Response `200``application/json` 1 fields Elements needed for request.