Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
**Official ChittyID Foundation Implementation** - Authoritative identity management for the ChittyOS ecosystem.

[![Foundation Service](https://img.shields.io/badge/ChittyFoundation-Official-gold)](https://github.com/chittyfoundation)
[![API Version](https://img.shields.io/badge/API-v2.0-blue)](https://id.chitty.cc/api/v2)
[![API Version](https://img.shields.io/badge/API-v2.0-blue)](https://foundation.thechitty.com/api/v2)
[![Charter Compliant](https://img.shields.io/badge/Charter-Compliant-green)](https://charter.chitty.cc)

## 🏛️ Foundation Authority

This is the **authoritative ChittyID Foundation service** that defines HOW ChittyIDs are generated, validated, and managed across the entire ChittyOS ecosystem. All other services must REQUEST ChittyIDs from this Foundation service.

**Production Service**: https://id.chitty.cc
**Production Service**: https://foundation.thechitty.com

## 🎯 Architecture

Expand Down Expand Up @@ -41,7 +41,7 @@ Authorization: Bearer your_chitty_id_token

### Request a ChittyID
```javascript
const response = await fetch('https://id.chitty.cc/api/v2/chittyid/mint', {
const response = await fetch('https://foundation.thechitty.com/api/v2/chittyid/mint', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Expand All @@ -60,7 +60,7 @@ console.log(result.chitty_id); // CP-A-001-1234-P-2509-I-82

### Verify a ChittyID
```javascript
const response = await fetch('https://id.chitty.cc/api/v2/chittyid/verify', {
const response = await fetch('https://foundation.thechitty.com/api/v2/chittyid/verify', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Expand Down
4 changes: 2 additions & 2 deletions canon/api-routes-chittyid.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class ChittyIDAPI {
trustLevel,
env,
) {
// Fetch ChittyID from id.chitty.cc service
// Fetch ChittyID from foundation.thechitty.com service
if (!region || !jurisdiction || !entityType || trustLevel === undefined) {
throw new Error(
"Missing required parameters: region, jurisdiction, entityType, trustLevel",
Expand Down Expand Up @@ -754,7 +754,7 @@ export async function onRequest(context) {
status: "healthy",
endpoint: "core.chitty.cc",
},
{ name: "chittyid", status: "healthy", endpoint: "id.chitty.cc" },
{ name: "chittyid", status: "healthy", endpoint: "foundation.thechitty.com" },
{
name: "chittyrouter",
status: "healthy",
Expand Down
6 changes: 3 additions & 3 deletions chitty-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* ChittyID CLI - TypeScript Production Implementation
*
* CRITICAL: Only mints IDs from canonical service (id.chitty.cc)
* CRITICAL: Only mints IDs from canonical service (foundation.thechitty.com)
* NO LOCAL GENERATION ALLOWED
*
* Usage (as Claude slash commands):
Expand All @@ -12,7 +12,7 @@
* /chitty validate 01-1-ABC-1234-1-2025A-1-0
*
* Environment:
* CHITTY_BASE_URL - Canonical service URL (default: https://id.chitty.cc)
* CHITTY_BASE_URL - Canonical service URL (default: https://foundation.thechitty.com)
* CHITTY_API_KEY - Authentication key for API access
*
* Endpoints:
Expand All @@ -26,7 +26,7 @@ import * as path from 'path';
import * as crypto from 'crypto';

// Environment configuration
const BASE = process.env.CHITTY_BASE_URL || 'https://id.chitty.cc';
const BASE = process.env.CHITTY_BASE_URL || 'https://foundation.thechitty.com';
const KEY = process.env.CHITTY_API_KEY;
const STORAGE_DIR = process.env.CHITTY_STORAGE || path.join(process.env.HOME || '.', '.chitty');

Expand Down
14 changes: 7 additions & 7 deletions chittycontext.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ export const chittyContext = {

staging: {
name: "staging",
domain: "staging.id.chitty.cc",
url: "https://staging.id.chitty.cc",
domain: "staging.foundation.thechitty.com",
url: "https://staging.foundation.thechitty.com",
workerName: "chittyid-staging",
kvNamespaces: {
CHITTYID_KV: "ec782932b5f54c359d9aef2e28898bf9",
Expand Down Expand Up @@ -70,8 +70,8 @@ export const chittyContext = {

production: {
name: "production",
domain: "id.chitty.cc",
url: "https://id.chitty.cc",
domain: "foundation.thechitty.com",
url: "https://foundation.thechitty.com",
workerName: "chittyid-production",
kvNamespaces: {
CHITTYID_KV: "ec782932b5f54c359d9aef2e28898bf9",
Expand Down Expand Up @@ -135,10 +135,10 @@ export const chittyContext = {
*/
cloudflare: {
accountId: "0bc21e3a5a9de1a4cc843be9c3e98121", // ChittyCorp LLC
zoneName: "chitty.cc",
zoneName: "thechitty.com",
routes: {
production: "id.chitty.cc/*",
staging: "staging.id.chitty.cc/*",
production: "foundation.thechitty.com/*",
staging: "staging.foundation.thechitty.com/*",
},
},

Expand Down
2 changes: 1 addition & 1 deletion chittyid-client.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// ChittyID Service Client
const CHITTYID_SERVICE = 'https://id.chitty.cc';
const CHITTYID_SERVICE = 'https://foundation.thechitty.com';

async function mintChittyID(domain, subtype, metadata = {}) {
const response = await fetch(`${CHITTYID_SERVICE}/v1/mint`, {
Expand Down
6 changes: 3 additions & 3 deletions chittyid-service-worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ export default {
success: false,
error:
"SECURITY_VIOLATION: Local generation prohibited. All ChittyIDs must be requested from authorized servers only.",
policy: "https://id.chitty.cc - Server-only generation enforced",
policy: "https://foundation.thechitty.com - Server-only generation enforced",
violation_code: "FALLBACK_GENERATION_DISABLED",
},
corsHeaders,
Expand Down Expand Up @@ -680,14 +680,14 @@ async function generateSimpleChecksum(data) {
*
* NO LOCAL GENERATION - NO FALLBACK GENERATION - NO EXCEPTIONS
*
* Use: https://id.chitty.cc for all ChittyID requests
* Use: https://foundation.thechitty.com for all ChittyID requests
*/
// REMOVED: Local ID generation function completely removed for security

// REMOVED: All local generation functions completely removed for security compliance
// - Local official ID generation
// - Local simple ID generation
// All ChittyIDs must be requested from https://id.chitty.cc
// All ChittyIDs must be requested from https://foundation.thechitty.com

/**
* Store audit record for fallback ChittyID (Unused - kept for reference)
Expand Down
8 changes: 4 additions & 4 deletions cloudflare-mcp-portal-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -300,8 +300,8 @@
"account_id": "0bc21e3a5a9de1a4cc843be9c3e98121",
"routes": [
{
"pattern": "mcp.chitty.cc/*",
"zone_name": "chitty.cc"
"pattern": "mcp.foundation.thechitty.com/*",
"zone_name": "thechitty.com"
}
],
"environment": "production"
Expand Down Expand Up @@ -353,12 +353,12 @@
},
"deployment": {
"staging": {
"portal_url": "https://staging-mcp.chitty.cc",
"portal_url": "https://staging-mcp.foundation.thechitty.com",
"chittyauth_url": "https://chittyauth-staging.workers.dev",
"oauth_redirect": "https://portal-staging.cloudflare.com/oauth/callback/chittyauth"
},
"production": {
"portal_url": "https://mcp.chitty.cc",
"portal_url": "https://mcp.foundation.thechitty.com",
"chittyauth_url": "https://chittyauth-prod.workers.dev",
"oauth_redirect": "https://portal.cloudflare.com/oauth/callback/chittyauth"
}
Expand Down
2 changes: 1 addition & 1 deletion examples/basic-usage.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Demonstrates common usage patterns for the ChittyID API
*/

const API_BASE = 'https://id.chitty.cc';
const API_BASE = 'https://foundation.thechitty.com';

// Example 1: Check system health
async function checkHealth() {
Expand Down
4 changes: 2 additions & 2 deletions functions/api/[[route]].js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ class ChittyIDAPI {
trustLevel,
env,
) {
// Fetch ChittyID from id.chitty.cc service
// Fetch ChittyID from foundation.thechitty.com service
if (!region || !jurisdiction || !entityType || trustLevel === undefined) {
throw new Error(
"Missing required parameters: region, jurisdiction, entityType, trustLevel",
Expand Down Expand Up @@ -893,7 +893,7 @@ export async function onRequest(context) {
status: "healthy",
endpoint: "core.chitty.cc",
},
{ name: "chittyid", status: "healthy", endpoint: "id.chitty.cc" },
{ name: "chittyid", status: "healthy", endpoint: "foundation.thechitty.com" },
{
name: "chittyrouter",
status: "healthy",
Expand Down
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
],
"security": {
"note": "CRITICAL: This CLI enforces central service minting only. No local ChittyID generation is permitted.",
"canonical_service": "https://id.chitty.cc",
"canonical_service": "https://foundation.thechitty.com",
"endpoints": {
"generate": "POST /v1/identity/chitty-id",
"register": "POST /v1/evidence/items",
Expand Down
8 changes: 4 additions & 4 deletions mcp-handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class ChittyIDMCPHandler {
OPENAI_API_KEY: process.env.OPENAI_API_KEY,
ANTHROPIC_API_KEY: process.env.ANTHROPIC_API_KEY,
CHITTY_SERVER_URL:
process.env.CHITTY_SERVER_URL || "https://id.chitty.cc",
process.env.CHITTY_SERVER_URL || "https://foundation.thechitty.com",
CHITTY_API_KEY: process.env.CHITTY_API_KEY,
});

Expand All @@ -36,7 +36,7 @@ class ChittyIDMCPHandler {
OPENAI_API_KEY: process.env.OPENAI_API_KEY,
ANTHROPIC_API_KEY: process.env.ANTHROPIC_API_KEY,
CHITTY_SERVER_URL:
process.env.CHITTY_SERVER_URL || "https://id.chitty.cc",
process.env.CHITTY_SERVER_URL || "https://foundation.thechitty.com",
CHITTY_API_KEY: process.env.CHITTY_API_KEY,
});
}
Expand Down Expand Up @@ -151,7 +151,7 @@ class ChittyIDMCPHandler {
env: {
...process.env,
CHITTY_BASE_URL:
process.env.CHITTY_BASE_URL || "https://id.chitty.cc",
process.env.CHITTY_BASE_URL || "https://foundation.thechitty.com",
CHITTY_STORAGE:
process.env.CHITTY_STORAGE ||
join(process.env.HOME || ".", ".chitty"),
Expand Down Expand Up @@ -426,7 +426,7 @@ class ChittyIDMCPHandler {
api_key_configured: !!process.env.CHITTY_API_KEY,
openai_configured: !!process.env.OPENAI_API_KEY,
anthropic_configured: !!process.env.ANTHROPIC_API_KEY,
base_url: process.env.CHITTY_BASE_URL || "https://id.chitty.cc",
base_url: process.env.CHITTY_BASE_URL || "https://foundation.thechitty.com",
storage_dir:
process.env.CHITTY_STORAGE ||
join(process.env.HOME || ".", ".chitty"),
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"type": "git",
"url": "https://github.com/chittyfoundation/chittyid.git"
},
"homepage": "https://id.chitty.cc",
"homepage": "https://foundation.thechitty.com",
"bugs": {
"url": "https://github.com/chittyfoundation/chittyid/issues"
},
Expand Down Expand Up @@ -56,7 +56,7 @@
"context:validate:prod": "node scripts/chittycontext.js validate production",
"context:check-secrets": "node scripts/chittycontext.js check-secrets",
"context:export": "node scripts/chittycontext.js export-env",
"health": "curl https://id.chitty.cc/health",
"health": "curl https://foundation.thechitty.com/health",
"monitor": "wrangler tail --format=pretty"
},
"dependencies": {
Expand Down
2 changes: 1 addition & 1 deletion projectsync.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
],
"deployments": {
"production": {
"url": "https://id.chitty.cc",
"url": "https://foundation.thechitty.com",
"account": "0bc21e3a5a9de1a4cc843be9c3e98121",
"worker": "chittyid-foundation"
}
Expand Down
2 changes: 1 addition & 1 deletion wrangler-pages.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ compatibility_date = "2025-01-16"
pages_build_output_dir = "dist"

[env.production]
route = "id.chitty.cc/*"
route = "foundation.thechitty.com/*"

[[kv_namespaces]]
binding = "CHITTY_IDS"
Expand Down
24 changes: 12 additions & 12 deletions wrangler.hybrid.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ account_id = "bbf9fcd845e78035b7a135c481e88541" # ChittyCorp LLC main account

# Routes for hybrid system endpoints
[[routes]]
pattern = "id.chitty.cc/ontology/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/ontology/*"
zone_name = "thechitty.com"

[[routes]]
pattern = "id.chitty.cc/translate/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/translate/*"
zone_name = "thechitty.com"

[[routes]]
pattern = "id.chitty.cc/governance/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/governance/*"
zone_name = "thechitty.com"

# KV Namespaces - ChittyCorp MCP Portal
[[kv_namespaces]]
Expand Down Expand Up @@ -75,16 +75,16 @@ PIPELINE_ENFORCEMENT = "STRICT"
GENERATION_MODE = "SERVER_ONLY"

[[env.production.routes]]
pattern = "id.chitty.cc/ontology/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/ontology/*"
zone_name = "thechitty.com"

[[env.production.routes]]
pattern = "id.chitty.cc/translate/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/translate/*"
zone_name = "thechitty.com"

[[env.production.routes]]
pattern = "id.chitty.cc/governance/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/governance/*"
zone_name = "thechitty.com"

[[env.production.kv_namespaces]]
binding = "MCP_SESSIONS"
Expand Down
16 changes: 8 additions & 8 deletions wrangler.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ account_id = "0bc21e3a5a9de1a4cc843be9c3e98121" # ChittyCorp LLC main account
# Production environment
[env.production]

# Route configuration for id.chitty.cc
# Route configuration for foundation.thechitty.com
[[env.production.routes]]
pattern = "id.chitty.cc/*"
zone_name = "chitty.cc"
pattern = "foundation.thechitty.com/*"
zone_name = "thechitty.com"

# MCP Portal KV Storage - Using proper namespaces for production
[[env.production.kv_namespaces]]
Expand Down Expand Up @@ -146,8 +146,8 @@ binding = "AI"
[vars]
# ChittyID Foundation Configuration
CHITTYID_SERVICE_VERSION = "2.0.0"
CHITTYID_FOUNDATION_URL = "https://id.chitty.cc"
CHITTYID_FALLBACK_URL = "https://fallback.id.chitty.cc"
CHITTYID_FOUNDATION_URL = "https://foundation.thechitty.com"
CHITTYID_FALLBACK_URL = "https://fallback.foundation.thechitty.com"

# ChittyOS Gateway Integration
CHITTYOS_GATEWAY_URL = "https://gateway.chitty.cc"
Expand All @@ -161,9 +161,9 @@ DRAND_BEACON_URL = "https://api.drand.sh/public/latest"
[env.production.vars]
AI_GATEWAY = "chittyrouter-ai-gateway"
ENVIRONMENT = "production"
CHITTYID_FOUNDATION_URL = "https://id.chitty.cc"
CHITTYID_FOUNDATION_URL = "https://foundation.thechitty.com"
CHITTYID_SERVICE_VERSION = "2.0.0"
CHITTYID_FALLBACK_URL = "https://fallback.id.chitty.cc"
CHITTYID_FALLBACK_URL = "https://fallback.foundation.thechitty.com"
CHITTYOS_GATEWAY_URL = "https://gateway.chitty.cc"
CHITTYOS_REGISTRY_URL = "https://registry.chitty.cc"
CHITTYOS_SCHEMA_URL = "https://schema.chitty.cc"
Expand All @@ -172,7 +172,7 @@ DRAND_BEACON_URL = "https://api.drand.sh/public/latest"
# Staging Environment Variables
[env.staging.vars]
ENVIRONMENT = "staging"
CHITTYID_FOUNDATION_URL = "https://staging.id.chitty.cc"
CHITTYID_FOUNDATION_URL = "https://staging.foundation.thechitty.com"

# Secrets (set via wrangler secret put)
# CHITTY_ID_TOKEN = "foundation-service-token"
Expand Down