API
v1 — REST APICreate legally-binding agreements programmatically. Loans, leases, service contracts, fidelity agreements, and more.
Quick Start
Get up and running in three steps.
Get your API key
Open the Faithfully app, go to Settings > API Access, and generate your API key. Keys start with fai_.
Set the authorization header
Include your key in every request using the X-API-Key header.
X-API-Key: fai_your_api_key_here
Make your first request
Fetch your profile to verify everything works.
curl -X GET https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/me \
-H "X-API-Key: fai_your_api_key_here"
Authentication
All API requests require a valid API key.
API Key Format
Keys are prefixed with fai_ followed by a unique token. Manage your keys in the Faithfully app under Settings > API Access.
curl https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/me \
-H "X-API-Key: fai_abc123def456"
Rate Limits
| Tier | Requests / Hour | Requests / Day |
|---|---|---|
| Pro | 100 | 1,000 |
| Business | 1,000 | 10,000 |
| Enterprise | Unlimited | Unlimited |
Rate limit headers are included in every response: X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset.
Endpoints Reference
Base URL: https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi
Query Parameters
pending, active, completed, cancelled
Example
curl -X GET "https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements?limit=10&status=active" \
-H "X-API-Key: fai_your_key"
const response = await fetch(
'https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements?limit=10&status=active',
{
headers: { 'X-API-Key': 'fai_your_key' }
}
);
const data = await response.json();
console.log(data.agreements);
import requests
response = requests.get(
'https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements',
headers={'X-API-Key': 'fai_your_key'},
params={'limit': 10, 'status': 'active'}
)
data = response.json()
print(data['agreements'])
Response
{
"agreements": [
{
"id": "abc123",
"agreement_type": "loan",
"title": "Personal Loan Agreement",
"status": "active",
"user_a": "user_id_1",
"user_b": "user_id_2",
"created_at": "2026-01-15T10:30:00Z"
}
],
"total": 1,
"limit": 10,
"offset": 0
}
Request Body
loan, lease, item_borrow, service, shared_expense, promissory_note
Example
curl -X POST https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements \
-H "X-API-Key: fai_your_key" \
-H "Content-Type: application/json" \
-d '{
"agreement_type": "loan",
"title": "Personal Loan to Jane",
"counterparty_email": "jane@example.com",
"terms": {
"principal_amount": 5000,
"interest_rate": 5.0,
"duration_months": 12,
"payment_frequency": "monthly"
}
}'
const response = await fetch(
'https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements',
{
method: 'POST',
headers: {
'X-API-Key': 'fai_your_key',
'Content-Type': 'application/json'
},
body: JSON.stringify({
agreement_type: 'loan',
title: 'Personal Loan to Jane',
counterparty_email: 'jane@example.com',
terms: {
principal_amount: 5000,
interest_rate: 5.0,
duration_months: 12,
payment_frequency: 'monthly'
}
})
}
);
const data = await response.json();
console.log(data);
import requests
response = requests.post(
'https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements',
headers={
'X-API-Key': 'fai_your_key',
'Content-Type': 'application/json'
},
json={
'agreement_type': 'loan',
'title': 'Personal Loan to Jane',
'counterparty_email': 'jane@example.com',
'terms': {
'principal_amount': 5000,
'interest_rate': 5.0,
'duration_months': 12,
'payment_frequency': 'monthly'
}
}
)
data = response.json()
print(data)
Response
{
"id": "new_agreement_id",
"agreement_type": "loan",
"title": "Personal Loan to Jane",
"status": "draft",
"counterparty_email": "jane@example.com",
"terms": {
"principal_amount": 5000,
"interest_rate": 5.0,
"duration_months": 12,
"payment_frequency": "monthly"
},
"created_at": "2026-02-24T15:00:00Z"
}
Path Parameters
Example
curl -X GET https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements/abc123 \
-H "X-API-Key: fai_your_key"
Response
{
"id": "abc123",
"agreement_type": "loan",
"title": "Personal Loan to Jane",
"status": "active",
"user_a": "lender_user_id",
"user_b": "borrower_user_id",
"terms": {
"principal_amount": 5000,
"interest_rate": 5.0,
"duration_months": 12,
"payment_frequency": "monthly"
},
"balance": {
"principal_remaining": 3500,
"total_paid": 1500,
"next_payment_date": "2026-03-01"
},
"created_at": "2026-01-15T10:30:00Z",
"activated_at": "2026-01-16T08:00:00Z"
}
Description
Sends the agreement to the counterparty for review and signature. The agreement must be in draft status. An invitation email will be sent to the counterparty.
Path Parameters
Example
curl -X POST https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/agreements/abc123/send \
-H "X-API-Key: fai_your_key"
Response
{
"success": true,
"message": "Agreement sent for review",
"agreement_id": "abc123",
"status": "pending"
}
Description
Returns the authenticated user's profile information. Useful for verifying API key validity and retrieving account details.
Example
curl -X GET https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/me \
-H "X-API-Key: fai_your_key"
Response
{
"id": "user_id",
"email": "you@example.com",
"display_name": "John Doe",
"subscription_tier": "pro",
"stripe_connected": true,
"created_at": "2025-06-01T12:00:00Z"
}
Description
Returns the status of the user's Stripe Connect account. A connected Stripe account is required to send or receive payments through agreements.
Example
curl -X GET https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/stripe/status \
-H "X-API-Key: fai_your_key"
Response
{
"connected": true,
"payouts_enabled": true,
"charges_enabled": true,
"account_id": "acct_..."
}
Description
Initiates the Stripe Connect onboarding flow. Returns a URL that the user should visit to complete Stripe account setup.
Example
curl -X POST https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/stripe/setup \
-H "X-API-Key: fai_your_key"
Response
{
"url": "https://connect.stripe.com/setup/...",
"expires_at": "2026-02-24T16:00:00Z"
}
Description
Returns the full OpenAPI 3.1 specification for the Faithfully API. Use this to auto-generate client libraries, import into Postman, or configure ChatGPT Actions and Claude MCP.
Example
curl -X GET https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/openapi.json
Agreement Types
Faithfully supports 8 agreement types across personal agreements and fidelity contracts.
Personal Agreements
Loan
loanPersonal loans with interest, scheduled payments, and full amortization tracking.
principal_amount, interest_rate, duration_months, payment_frequency
Lease
leaseResidential or commercial lease agreements with rent tracking and security deposits.
monthly_rent, security_deposit, lease_start_date, lease_end_date
Item Borrow
item_borrowLend or borrow items with optional rental fees, due dates, and damage deposit tracking.
item_name, item_value, return_date
Service
serviceService contracts for freelance work, consulting, or recurring services with flexible payment schedules.
service_description, payment_amount, payment_type, schedule_type
Shared Expense
shared_expenseSplit costs between parties with equal, percentage, or fixed-amount splits.
total_amount, split_type, expense_description
Promissory Note
promissory_noteFormal promise to pay a specified sum, with lump sum or installment options.
principal_amount, interest_rate, payment_type, maturity_date
Fidelity Contracts
Long-Term Relationship
fidelity_ltrFidelity agreements for long-term committed relationships with customizable terms and penalties.
partner_email, contract_terms, penalty_amount
Short-Term Relationship
fidelity_strFidelity agreements for shorter-term relationships with defined boundaries and accountability.
partner_email, contract_terms, duration
ChatGPT Actions Guide
Integrate Faithfully into a custom GPT using Actions.
Open your GPT settings
Go to ChatGPT > My GPTs > Create/Edit GPT and navigate to the Configure tab.
Add a new Action
Scroll down to Actions and click Create new action.
Import the OpenAPI spec
Click Import from URL and paste the following URL:
https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/openapi.json
Configure authentication
Set the authentication type to API Key, header name to X-API-Key, and enter your fai_ key.
Test it out
Save the GPT and try asking it to "list my agreements" or "create a new loan agreement."
Claude MCP Integration
Connect Faithfully to Claude using the Model Context Protocol.
MCP Server Configuration
Add the following to your Claude MCP configuration file:
{
"mcpServers": {
"faithfully": {
"type": "openapi",
"url": "https://us-central1-faithfully-app.cloudfunctions.net/faithfullyApi/v1/openapi.json",
"headers": {
"X-API-Key": "fai_your_api_key_here"
}
}
}
}
Available Tools
Once connected, Claude can use the following tools:
| Tool | Description |
|---|---|
listAgreements |
List and filter your agreements |
createAgreement |
Create a new agreement of any type |
getAgreement |
Get full details of a specific agreement |
sendAgreement |
Send an agreement for counterparty review |
getProfile |
Get your account profile and subscription info |
checkStripeStatus |
Check if Stripe Connect is set up |
setupStripe |
Start the Stripe Connect onboarding flow |
Example Usage
Once configured, you can ask Claude things like:
"Create a loan agreement for $2,000 with 3% interest over 6 months
to jane@example.com and send it for review."
Pricing
API access is free for all users. Create agreements from ChatGPT, Claude, Gemini, or any AI assistant at no cost.
- Create agreements
- API access (50 req/day)
- ChatGPT, Claude & Gemini integration
- Payment tracking
SDKs & Libraries
Official client libraries for the Faithfully API.
Node.js / npm
@faithfully/sdk
Python / pip
faithfully-sdk
Go
go-faithfully
Ruby / gem
faithfully
openapi-generator.Download Faithfully
Create and manage legally-binding agreements from your phone.