← Back to Docs

Identity Schema

A TIP identity is a signed JSON document that proves a user controls a profile. It contains no passwords — only public-key cryptography.

Identity Document Structure

{
  "tip_version": "1.0.0",
  "sub": "did:tip:abc123",
  "display_name": "Jane Developer",
  "avatar_url": "https://example.com/avatar.jpg",
  "public_key": "-----BEGIN PUBLIC KEY-----...",
  "provider": "threadline",
  "issued_at": "2025-01-15T00:00:00Z",
  "expires_at": "2026-01-15T00:00:00Z",
  "signature": "base64-encoded-signature..."
}

Full TIP_Identity example

Canonical portable document shape from the TIP v1.0.0 schema (identity_id, nested profile / reputation / privacy, Ed25519 key and signature):

{
  "tip_version": "1.0.0",
  "identity_id": "tip_01j9x7kabcdefghijklmnopqrs",
  "public_key": "ed25519:MCowBQYDK2VwAyEAa+example+key+here+padding==",
  "created_at": "2026-01-01T00:00:00Z",
  "profile": {
    "display_name": "alice",
    "avatar_hash": "sha256:3a1f9c8e7b6d5a4c3b2a1908f7e6d5c4b3a29180",
    "bio": "Writer and technologist",
    "website": "https://alice.example"
  },
  "reputation": {
    "score": 5500,
    "level": "trusted",
    "last_computed": "2026-05-13T00:00:00Z",
    "breakdown": {
      "comment_quality": 0.82,
      "account_age_days": 180,
      "flag_rate": 0.01,
      "upvote_ratio": 0.91
    }
  },
  "privacy": {
    "history_public": true,
    "cross_site_visible": true,
    "data_export_enabled": true
  },
  "signature": "ed25519:AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA="
}

Field Reference

FieldDescription
tip_versionProtocol version. Currently "1.0.0".
subSubject identifier. A DID-style URI unique to this identity.
display_nameThe name shown on comments. Can be changed by the user.
avatar_urlURL to an avatar image. Verified to be an image URL, not content-validated.
public_keyEd25519 public key used to verify the signature and future attestations.
providerThe identity provider that issued this document (e.g., "threadline", "self").
issued_atISO 8601 timestamp when the identity was issued.
expires_atISO 8601 timestamp when the identity expires. Max 1 year from issuance.
signatureSignature over all other fields, created by the provider's private key.

Verification Flow

  1. Client receives an identity document (from the user's provider or cached locally)
  2. Client checks expires_at is in the future
  3. Client fetches the provider's public key from a well-known URL
  4. Client verifies the signature field against all other fields using the provider's key
  5. If valid, the identity is accepted for commenting

SSO Integration (Publisher+)

If you run your own user system, you can act as a TIP identity provider. Generate identity documents server-side and pass them to the widget:

<script
  src="https://threadline.io/api/embed"
  data-site-id="YOUR_SITE_ID"
  data-api-url="https://api.threadline.io"
  data-identity-token="YOUR_SIGNED_TIP_IDENTITY_JWT"
  async></script>
<div id="threadline-comments"></div>