Skip to content

Commit 0ae7f3b

Browse files
author
KikuAI-lab
committed
docs: fix broken links to OpenAPI and Postman in README
1 parent 0512161 commit 0ae7f3b

File tree

1 file changed

+173
-0
lines changed

1 file changed

+173
-0
lines changed

reliapi/README.md

Lines changed: 173 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,173 @@
1+
# ReliAPI
2+
3+
Reliability layer for API calls: retries, caching, dedup, circuit breakers.
4+
5+
[![npm version](https://badge.fury.io/js/reliapi-sdk.svg)](https://www.npmjs.com/package/reliapi-sdk)
6+
[![PyPI version](https://badge.fury.io/py/reliapi-sdk.svg)](https://pypi.org/project/reliapi-sdk/)
7+
[![Docker](https://img.shields.io/docker/v/kikudoc/reliapi?label=docker)](https://hub.docker.com/r/kikudoc/reliapi)
8+
9+
## Installation
10+
11+
- **RapidAPI**: [Try ReliAPI on RapidAPI](https://rapidapi.com/kikuai-lab-kikuai-lab-default/api/reliapi) - No installation required, use directly from RapidAPI
12+
- **NPM Package**: [reliapi-sdk](https://www.npmjs.com/package/reliapi-sdk) - `npm install reliapi-sdk`
13+
- **PyPI Package**: [reliapi-sdk](https://pypi.org/project/reliapi-sdk/) - `pip install reliapi-sdk`
14+
- **Docker Image**: [kikudoc/reliapi](https://hub.docker.com/r/kikudoc/reliapi) - `docker pull kikudoc/reliapi`
15+
- **CLI Package**: [reliapi-cli](https://pypi.org/project/reliapi-cli/) - `pip install reliapi-cli`
16+
17+
## Features
18+
19+
- **Retries with Backoff** - Automatic retries with exponential backoff
20+
- **Circuit Breaker** - Prevent cascading failures
21+
- **Caching** - TTL cache for GET requests and LLM responses
22+
- **Idempotency** - Request coalescing with idempotency keys
23+
- **Rate Limiting** - Built-in rate limiting per tier
24+
- **LLM Proxy** - Unified interface for OpenAI, Anthropic, Mistral
25+
- **Cost Control** - Budget caps and cost estimation
26+
27+
## Quick Start
28+
29+
### Using RapidAPI (No Installation Required)
30+
31+
Try ReliAPI directly on [RapidAPI](https://rapidapi.com/kikuai-lab-kikuai-lab-default/api/reliapi) - no SDK installation needed. Just subscribe to the API and start making requests!
32+
33+
### Using the SDK
34+
35+
**JavaScript/TypeScript:**
36+
37+
```bash
38+
npm install reliapi-sdk
39+
```
40+
41+
```typescript
42+
import { ReliAPI } from 'reliapi-sdk';
43+
44+
const client = new ReliAPI({
45+
baseUrl: 'https://api.reliapi.dev',
46+
apiKey: 'your-api-key'
47+
});
48+
49+
// HTTP proxy with retries
50+
const response = await client.proxyHttp({
51+
target: 'my-api',
52+
method: 'GET',
53+
path: '/users/123',
54+
cache: 300 // cache for 5 minutes
55+
});
56+
57+
// LLM proxy with idempotency
58+
const llmResponse = await client.proxyLlm({
59+
target: 'openai',
60+
model: 'gpt-4o-mini',
61+
messages: [{ role: 'user', content: 'Hello!' }],
62+
idempotencyKey: 'unique-key-123'
63+
});
64+
```
65+
66+
**Python:**
67+
68+
```bash
69+
pip install reliapi-sdk
70+
```
71+
72+
```python
73+
from reliapi_sdk import ReliAPI
74+
75+
client = ReliAPI(
76+
base_url="https://api.reliapi.dev",
77+
api_key="your-api-key"
78+
)
79+
80+
# HTTP proxy with retries
81+
response = client.proxy_http(
82+
target="my-api",
83+
method="GET",
84+
path="/users/123",
85+
cache=300
86+
)
87+
88+
# LLM proxy with idempotency
89+
llm_response = client.proxy_llm(
90+
target="openai",
91+
model="gpt-4o-mini",
92+
messages=[{"role": "user", "content": "Hello!"}],
93+
idempotency_key="unique-key-123"
94+
)
95+
```
96+
97+
### Using the CLI
98+
99+
```bash
100+
pip install reliapi-cli
101+
```
102+
103+
```bash
104+
# Check health
105+
reli ping
106+
107+
# Make HTTP request
108+
reli request --method GET --url https://api.example.com/users
109+
110+
# Make LLM request
111+
reli llm --target openai --message "Hello, world!"
112+
```
113+
114+
### Using the GitHub Action
115+
116+
```yaml
117+
- uses: KikuAI-Lab/reliapi@v1
118+
with:
119+
api-url: 'https://api.reliapi.dev'
120+
api-key: ${{ secrets.RELIAPI_KEY }}
121+
endpoint: '/proxy/http'
122+
method: 'POST'
123+
body: '{"target": "my-api", "method": "GET", "path": "/health"}'
124+
```
125+
126+
## API Endpoints
127+
128+
### HTTP Proxy
129+
130+
```
131+
POST /proxy/http
132+
```
133+
134+
Proxy any HTTP API with reliability layers.
135+
136+
### LLM Proxy
137+
138+
```
139+
POST /proxy/llm
140+
```
141+
142+
Proxy LLM requests with idempotency, caching, and cost control.
143+
144+
### Health Check
145+
146+
```
147+
GET /healthz
148+
```
149+
150+
Health check endpoint for monitoring.
151+
152+
## Self-Hosting
153+
154+
```bash
155+
docker run -d -p 8000:8000 \
156+
-e REDIS_URL="redis://localhost:6379/0" \
157+
kikudoc/reliapi:latest
158+
```
159+
160+
## Documentation
161+
162+
- [GitHub Wiki](https://github.com/KikuAI-Lab/reliapi/wiki) - Complete documentation and guides
163+
- [Full Documentation](https://reliapi.kikuai.dev)
164+
165+
## License
166+
167+
MIT License - see [LICENSE](./LICENSE) for details.
168+
169+
## Support
170+
171+
- GitHub Issues: https://github.com/KikuAI-Lab/reliapi/issues
172+
- Email: dev@kikuai.dev
173+

0 commit comments

Comments
 (0)