version90 DEVELOPERS

Recipes · the flagship use case

The archive is a database wearing a folder costume.

Every document you file gets counterparty, agreement type, dates, key clauses and risk flags extracted automatically. These recipes turn that into working systems.

1 · Bulk import the back catalog

Point a loop at the folder (Drive export, S3 bucket, the shared drive of shame). Each file gets one POST; extraction is a background job, so fire away and read back later.

import.sh — idempotent by content hash (duplicates are rejected cleanly)
for f in ./contracts/*.{pdf,docx}; do
  curl -s -X POST https://app.version90.com/api/v1/archive \
    -H "Authorization: Bearer $V90_TOKEN" \
    -F "file=@$f" | jq -r '"\(.id)  \(.original_filename // .detail.message)"'
done

2 · Renewal calendar (the invoice should never be the notification)

Extracted expiration_date plus the risk flags on auto-renewal clauses make renewal tracking a nightly cron, not a memory test.

renewals.sh — everything expiring in the next quarter
curl -s "https://app.version90.com/api/v1/archive?date_to=$(date -v+90d +%Y-%m-%d)" \
  -H "Authorization: Bearer $V90_TOKEN" \
| jq -r '.items[] | select(.expiration_date != null)
    | "\(.expiration_date)  \(.counterparty)  \(.title)"' | sort
# pipe into Slack, a calendar API, or your task tracker

3 · Warehouse export (contract terms next to revenue data)

Pull the whole structured catalog into your warehouse and suddenly "average payment terms by customer segment" is a SQL query.

export.py — extracted terms → rows
import requests

rows = requests.get(
    "https://app.version90.com/api/v1/archive",
    headers={"Authorization": f"Bearer {TOKEN}"},
).json()["items"]

for r in rows:
    detail = requests.get(
        f"https://app.version90.com/api/v1/archive/{r['id']}",
        headers={"Authorization": f"Bearer {TOKEN}"},
    ).json()
    warehouse.insert("contracts", {
        "counterparty": detail["counterparty"],
        "type": detail["agreement_type"],
        "effective": detail["effective_date"],
        "expires": detail["expiration_date"],
        "governing_law": detail["governing_law"],
        "terms": detail["key_terms"],     # structured field/value pairs
        "risks": detail["risks"],
    })

4 · Agent Q&A over the archive (MCP)

Connect the MCP server and the archive becomes something your team can interrogate in plain English — with answers grounded in extracted, cited fields:

  • "Do any customer contracts prevent us from using subprocessors?"
  • "Which agreements have exclusivity, and in which territories?"
  • "Compare the liability caps across our three biggest vendor MSAs."

5 · Auto-file from where contracts actually land

Executed copies arrive in DocuSign completions, deal-desk email, or a CRM attachment field. A ten-line webhook handler that base64s the file into upload_to_archive (MCP) or POSTs it to /archive (REST) means the archive is simply always current — no one "does filing" ever again.