Middleware
In order to baseline data from a system of record, an interface must be created to interact with Provide Baseline. The integration interface serves as a bi-directional implementation layer that enables seamless interaction between the system of record and PRVD stack.
In order to successfully interact with Provide Baseline, the integration interface must support the following functions:
Interface
Code
ConfigureTenant | sets the organization parameters for baselining a record |
CreateObject | creates an object |
DeleteObject | deletes a specified object |
ListSchemas | returns a list of system schemas |
GetSchema | returns a list of fields associated with a specified Schema |
HealthCheck | returns overall status |
TenantHealthCheck | returns connectivity status of Tenant |
UpdateObject | updates a specified object |
UpdateObjectStatus | updates the status of a specified object |
// SOR defines an interface for system of record backends
type SOR interface {
ConfigureTenant(params map[string]interface{}) error
CreateObject(params map[string]interface{}) (interface{}, error)
DeleteTenant(organizationID string) error
ListSchemas(params map[string]interface{}) (interface{}, error)
GetSchema(recordType string, params map[string]interface{}) (interface{}, error)
HealthCheck() error
TenantHealthCheck(organizationID string) error
UpdateObject(id string, params map[string]interface{}) error
UpdateObjectStatus(id string, params map[string]interface{}) error
}

First, you'll need to configure the tenant with information about the middleware to facilitate a connection. The model that the system of record must ingest is contained in the request below:
post
https://example.sor.local
/tenants
Configure Tenants

A Baseline
Object
is arbitrary data containing the ProtocolMessage
. The integration middleware will need to pass this object in accordance with the domain model as agreed upon by the counter-parties and enforced by a prover. The middleware will ingest the ProtocolMessage
, return a BaselineRecord
, and output a ProtocolMessage
to participant middlewares.post
https://baseline.provide.services
api/v1/protocol_messages
Create Object
In the DevOps lifecycle, it may become necessary to delete a configured middleware on behalf of a tenant. In these cases, the system of record will need to stop sending requests to the middleware associated with the specified
organization_id
.delete
https://example.sor.local
/tenants/:id
Delete Middleware Configuration
Because the
payload
contained within the object
supports arbitrary data, it may be necessary to query the stack to retrieve the schema of the object model being used. get
https://example.sor.local
/schemas
Fetch Schemas
Once a
Schema
has been identified, the contained Field
list can be retrieved by including the Type
in the URL of the request. get
https://example.sor.local
/schemas/:schemaId
Get Schema Fields
Request to verify that the system of record is online
get
https://baseline.provide.services
/api/v1/status
Health Check - SOR
Request to verify that the system of record can communicate with the tenant
get
https://example.sor.local
/status
Health Check - Middleware
When updating an object, the
baseline_id
must be relayed with each request. The functions the middleware integration support are as follows:put
https://baseline.provide.services
/api/v1/objects/:id
Update Object
put
https://baseline.provide.services
/api/v1/business_objects/:id/status
Update Object Status
Last modified 10mo ago