Metadata-Version: 2.4
Name: apihunterx
Version: 0.1.1
Summary: Scan projects for APIs, URLs and environment variables
Author: Samarth Patil
License-Expression: MIT
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Dynamic: license-file

# APIHunterX

🔍 Scan projects for APIs, URLs, SDKs, and environment variables.

APIHunterX helps developers quickly discover external services, API dependencies, and required environment variables used within a codebase.

---

## Features

* Detect API SDKs and libraries
* Find API URLs and endpoints
* Discover environment variables
* Generate API inventory reports
* Scan entire projects recursively
* Simple command-line interface

---

## Installation

```bash
pip install apihunterx
```

---

## Usage

Scan the current project:

```bash
api-hunter scan .
```

Scan a specific directory:

```bash
api-hunter scan /path/to/project
```

Alternative:

```bash
python -m api_hunter scan .
```

---

## Example

### Sample Code

```python
import openai
import boto3
import os

client = openai.OpenAI()

api_key = os.getenv("OPENAI_API_KEY")

url = "https://api.openai.com/v1/chat/completions"
```

### Command

```bash
api-hunter scan .
```

### Output

```text
==================================================
API HUNTER REPORT
==================================================

DETECTED SERVICES
------------------------------
- OpenAI
- AWS

API URLS
------------------------------
- https://api.openai.com/v1/chat/completions

ENVIRONMENT VARIABLES
------------------------------
- OPENAI_API_KEY

FILES SCANNED: 25
```

---

## Currently Supported

### SDK Detection

* OpenAI
* AWS (boto3)
* Anthropic
* Stripe
* Discord
* Google Gemini
* Tweepy
* Requests
* HTTPX

### Environment Variables

Detects:

```python
os.getenv("API_KEY")
os.environ["API_KEY"]
```

### URL Detection

Detects:

```python
"https://api.example.com"
"https://webhook.example.com"
```

---

## Why APIHunterX?

Many projects rely on external APIs but lack documentation about:

* Which APIs are used
* Which API keys are required
* Which services the application depends on
* Which external endpoints are being called

APIHunterX automatically generates an inventory to help developers understand projects faster.

---

## Roadmap

### v0.2

* JSON report output
* Markdown report output
* Requirements.txt analysis
* pyproject.toml analysis

### v0.3

* FastAPI route detection
* Flask route detection
* OpenAPI discovery
* Swagger detection

### v0.4

* Hardcoded API key detection
* Security audit mode
* Secret exposure warnings

### v1.0

* JavaScript support
* TypeScript support
* Dependency graphs
* HTML reports
* GitHub Action integration

---

## Installation From Source

```bash
git clone https://github.com/samarthpatilML/apihunterx.git

cd apihunterx

pip install -e .
```

---

## Contributing

Contributions, bug reports, and feature requests are welcome.

1. Fork the repository
2. Create a feature branch
3. Commit your changes
4. Open a Pull Request

---

## License

MIT License

---

## Author

Samarth Patil

GitHub: https://github.com/samarthpatilML
