Inspiration

Having worked in the data center industry for many years, KPIs and SLAs are a daily discussion. Also being a fan of Bitcoin and Ethereum, this ChainLink hackathon presented an opportunity to leverage my data center experience to bring KPIs and SLAs to the blockchain industry (or perhaps vice versa?) - regardless, ChainLink and managing KPIs/SLAs/Escrow is a perfect marriage of technology for supporting and enforcing data center clients' agreements because it bridges the gap between on and off chain while fostering trust.

What it does

The platform uses ChainLink Keepers that continuously monitors key performance indicators (KPIs) and other data points, ensuring adherence to agreed-upon service levels between parties. In the event of an SLA violation, TrustLink's smart contracts automatically transfer funds from an escrow account to the recipients. Both parties agree on the appropriate compensation or negotiate the amount to be released from the escrow account. Within the platform, users CRUD (Create/Read/Update/Delete) Escrows/KPIs/SLAs for one or many recipients.

By utilizing ChainLink Keepers and Solidity smart contracts, TrustLink eliminates the need for manual intervention, significantly reducing the time and effort required to manage SLAs. The platform's decentralized nature ensures data integrity and fosters trust between parties, while its user-friendly interface makes it accessible to both technical and non-technical users.

TrustLink's innovative approach to SLA enforcement has the potential to streamline processes, reduce disputes, and ultimately enhance customer satisfaction in the data center and fiber networking industry.

How we built it

TrustLink integrates several customized Solidity smart contracts and ChainLink contracts to achieve its functionality:

Escrow: The Escrow contract is the account administration part of the TrustLink platform. It's responsible for managing the creation, negotiation, fulfillment, and recipient agreement status of escrows. This contract holds funds in a secure state until certain conditions are met, as defined by the service level agreements (SLAs). When a KPI violation occurs, as detected by the KPI contract, the Escrow contract initiates the process of transferring funds from the escrow account to the designated recipient. This could be the service recipient in case of an SLA violation, or back to the service provider if the SLA is met successfully.

KPI: This is the main contract that interacts with the ChainLink Keepers network to fetch data from an external API. It manages the creation, updating, deletion, and fetching of KPI points and checks if a KPI has been violated.

Escrow Factory: The EscrowFactory contract is responsible for creating and managing multiple instances of the Escrow contract. Each instance corresponds to a unique escrow agreement between two parties.

IEscrow: This is an interface for the Escrow contract, which manages the creation, negotiation, fulfillment, and recipient agreement status of escrows.

IKPI: This is an interface for the KPI contract, which manages the creation, updating, deletion, and fetching of KPI points.

KPIFactory: This is a factory contract that manages the creation and retrieval of KPI contracts for each escrow.

Challenges we ran into

New systems, so just learning Solidity and ChainLink was a challenge and also linking the output of the Azure IOT Simulator to a format suitable for ChainLink consumption. Ensuring the security of the smart contracts and keeping track of ownership was tricky. The most difficult and "artful" challenge was understanding the Gas and Link estimation and also funding the various contracts in an automated way.

Accomplishments that we're proud of

A fully functional app that lives up to the vision of providing trust to our clients while keeping us honest in our service level agreements. Upon any violations in the SLA triggers an escrow release and instantly paying our client(s) the penalties.

What we learned

Having never used Solidity or ChainLink, this has been a crash course in learning smart contract design and administration. While the programming was straight forward, the concept of contract ownership and various funding rules has been fun to learn.

What's next for TrustLink

Integrate with the Space an Time blockchain to store the KPI values in its data archive solution. Work with various data center and other service to implement our app. Optimize Gas and Security. Integrate with ChatGPT for reading legal documents to extract the KPIs and SLAs to implement into TrustLink.

Share this project:

Updates