API Reference

Complete reference for the Solstice Accrue REST API.

Base URL https://api.solsticeaccrue.com/v1

Authentication

All API requests require authentication via Bearer token. Include your API key in the Authorization header.

Authorization Header

Include this header with every request:

Authorization: Bearer YOUR_API_KEY
curl https://api.solsticeaccrue.com/v1/transactions \
  -H "Authorization: Bearer sk_live_abc123..."

Errors

The API uses conventional HTTP response codes. Errors include a JSON body with details.

200 Success
400 Bad Request — Invalid parameters
401 Unauthorized — Invalid API key
404 Not Found — Resource doesn't exist
500 Server Error — Something went wrong
{
  "error": {
    "code": "INVALID_NDC",
    "message": "NDC format is invalid. Expected 11 digits.",
    "field": "ndc"
  }
}
POST /transactions

Submit a transparent pharmacy transaction for accumulator credit processing. The transaction will be validated, member-matched, translated to EDI, and submitted to the TPA.

Request Body

Parameter Type Required Description
source string Required Source pharmacy: costplus, amazon, goodrx, manual
source_transaction_id string Required External transaction/order ID
ndc string Required NDC in any format (will be normalized to 11-digit)
drug_name string Required Drug name
quantity number Required Quantity dispensed
days_supply integer Required Days supply
fill_date date Required Fill date (YYYY-MM-DD)
patient_paid number Required Amount patient paid
pharmacy_name string Required Pharmacy name
patient_first_name string Required Patient first name
patient_last_name string Required Patient last name
patient_dob date Required Patient date of birth (YYYY-MM-DD)
group_number string Optional Employer group number (improves matching)
member_id string Optional Member ID if known

Example Request

curl -X POST https://api.solsticeaccrue.com/v1/transactions \
  -H "Authorization: Bearer sk_live_abc123" \
  -H "Content-Type: application/json" \
  -d '{
    "source": "costplus",
    "source_transaction_id": "CP-2025-123456",
    "ndc": "00093-7212-01",
    "drug_name": "Metformin HCL 500mg",
    "quantity": 90,
    "days_supply": 90,
    "fill_date": "2025-12-20",
    "patient_paid": 12.50,
    "pharmacy_name": "Cost Plus Drugs",
    "patient_first_name": "John",
    "patient_last_name": "Doe",
    "patient_dob": "1985-03-15",
    "group_number": "GRP12345"
  }'

Response

202 Transaction accepted for processing
{
  "transaction_id": "txn_abc123def456",
  "status": "received",
  "confidence_score": 0,
  "manual_review_required": false,
  "warnings": [],
  "estimated_completion": "2025-12-20T10:35:00Z"
}
GET /transactions/{transaction_id}

Retrieve the current status and details of a transaction.

Path Parameters

ParameterTypeDescription
transaction_id string The transaction ID returned from submit

Response

{
  "transaction_id": "txn_abc123def456",
  "status": "credited",
  "source": "costplus",
  "ndc11": "00093721201",
  "drug_name": "Metformin HCL 500mg",
  "quantity": 90,
  "days_supply": 90,
  "fill_date": "2025-12-20",
  "patient_paid": 12.50,
  "member_matched": true,
  "member_id": "MEM001234",
  "confidence_score": 95,
  "deductible_credited": 12.50,
  "oop_credited": 12.50,
  "created_at": "2025-12-20T10:30:00Z",
  "updated_at": "2025-12-20T10:45:00Z"
}
GET /members/{member_id}/accumulator

Get a member's current accumulator status including deductible and out-of-pocket maximum progress.

Query Parameters

ParameterTypeRequiredDescription
plan_year integer Optional Plan year (defaults to current year)

Response

{
  "member_id": "MEM001234",
  "plan_year": 2025,
  "deductible_limit": 3000.00,
  "deductible_met": 1560.00,
  "deductible_remaining": 1440.00,
  "oop_limit": 6000.00,
  "oop_met": 1560.00,
  "oop_remaining": 4440.00,
  "pending_amount": 25.00,
  "last_updated": "2025-12-20T10:45:00Z"
}
GET /employers/{employer_id}/summary

Get employer-level summary statistics including transaction counts and savings estimates.

Response

{
  "employer_id": "emp_456",
  "employer_name": "Acme Corporation",
  "plan_year": 2025,
  "total_members": 500,
  "active_members": 485,
  "transactions_submitted": 1250,
  "transactions_credited": 1100,
  "transactions_pending": 100,
  "transactions_rejected": 50,
  "total_submitted_amount": 45000.00,
  "total_credited_amount": 40000.00,
  "estimated_savings_vs_pbm": 125000.00
}
GET /employers/{employer_id}/reports/savings

Generate a savings report comparing transparent pharmacy spend to PBM benchmark pricing.

Query Parameters

ParameterTypeRequiredDescription
period string Optional month, quarter, or year (default: quarter)

Response

{
  "employer_id": "emp_456",
  "period": "quarter",
  "report_date": "2025-12-20T12:00:00Z",
  "summary": {
    "transparent_spend": 45000.00,
    "pbm_benchmark": 170000.00,
    "gross_savings": 125000.00,
    "savings_percentage": 73.5
  },
  "top_savings_drugs": [
    {
      "ndc": "00093721201",
      "drug_name": "Metformin HCL 500mg",
      "transparent_price": 12.50,
      "pbm_price": 85.00,
      "savings": 72.50
    }
  ]
}

Webhook Events

Subscribe to real-time notifications when transaction status changes.

Event Types

EventDescription
transaction.normalized Transaction validated and member matched
transaction.submitted EDI claim sent to TPA
transaction.accepted Claim accepted by TPA
transaction.rejected Claim rejected by TPA
accumulator.credited Accumulator credit confirmed

Webhook Payload

{
  "event": "accumulator.credited",
  "timestamp": "2025-12-20T10:45:00Z",
  "data": {
    "transaction_id": "txn_abc123def456",
    "member_id": "MEM001234",
    "deductible_credited": 12.50,
    "oop_credited": 12.50
  }
}