Skip to content

Integrations

Connect your application to BSP. Whether you're building a health app, integrating an EHR system, or creating a longevity AI platform, BSP provides the tools you need.

Official SDKs

TypeScript / JavaScript

bash
npm install bsp-sdk

Full reference: SDK Reference

Python

bash
pip install bsp-sdk

REST API

BSP provides a REST API for systems that cannot use an SDK directly.

POST /api/relayer/beo
GET  /api/exchange/records
POST /api/exchange/records
POST /api/relayer/consent
DELETE /api/consent/:tokenId

Integration Patterns

Pattern 1 — EHR Export

Export patient data from your EHR system to a BSP BioRecord. The patient receives cryptographic ownership.

typescript
import { BSPClient } from 'bsp-sdk'

const client = new BSPClient({ network: 'mainnet' })

const bioRecord = await client.bioRecord.create({
  beoId: patient.bspId,
  data: fhirBundle,
  sourceType: 'ehr-export',
})

await client.bioRecord.store(bioRecord) // stores on Arweave

Pattern 2 — Wearable Data

Stream continuous biomarker data from wearables and IoT devices into a patient's BEO.

typescript
const stream = client.bioRecord.stream({
  beoId: user.bspId,
  interval: '1m',
})

wearable.on('data', (reading) => {
  stream.push({
    biomarkerId: 'heart_rate',
    value: reading.hr,
    unit: 'bpm',
    timestamp: Date.now(),
  })
})

Pattern 3 — Research Access Request

Request consent to access anonymized biological data for a research study.

typescript
const request = await client.consent.request({
  ieoId: 'research_institution.bsp',
  dataFields: ['blood_glucose', 'hba1c'],
  duration: '90d',
  purpose: 'Type 2 Diabetes prevention study',
})

// Patient approves via their BSP wallet — no action needed from your side

Ecosystem Integrations

PlatformStatusNotes
Apple HealthPlannedBioRecord export adapter
Google FitPlannedBioRecord export adapter
Epic (FHIR R4)In ProgressFHIR-to-BEO bridge
Oura RingCommunityGitHub: bsp-oura-adapter
GarminCommunityGitHub: bsp-garmin-adapter
WithingsCommunityGitHub: bsp-withings-adapter

Certification

Applications that integrate BSP can apply for BSP Certified status, which verifies:

  • Correct implementation of the consent model
  • Proper data format compliance
  • Security audit

Certification Process


Getting Help


See also: Implementation Guide · Tutorials