Skip to content
Open
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
40 changes: 38 additions & 2 deletions ReadMe.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,38 @@
- [PiRC1: Pi Ecosystem Token Design](./PiRC1/ReadMe.md)
- [PiRC2: Subscription Contract API](./PiRC2/ReadMe.md)
# 📘 Subscription Contract API

## Overview
The **Subscription Contract API** enables applications to manage recurring billing agreements between service providers and customers. It supports creating, updating, retrieving, and canceling subscription contracts.

---

## Authentication
- **API Key**: Include in request headers (`Authorization: Bearer <token>`).
- **OAuth 2.0**: For secure delegated access.

---

## Endpoints

| Endpoint | Method | Description |
|---------------------|--------|------------------------------|
| `/contracts` | POST | Create a new subscription |
| `/contracts/{id}` | GET | Retrieve contract details |
| `/contracts/{id}` | PUT | Update contract terms |
| `/contracts/{id}` | DELETE | Cancel a subscription |

---

## Data Models

### Contract Object
```json
{
"id": "sub_12345",
"customer_id": "cust_67890",
"plan_id": "plan_basic",
"status": "active",
"start_date": "2026-04-27",
"renewal_date": "2026-05-27",
"billing_cycle": "monthly"
}- [PiRC1: Pi Ecosystem Token Design](./PiRC1/ReadMe.md)
- [PiRC2: Subscription Contract API](./PiRC2/ReadMe.md)