Metadata-Version: 2.4
Name: signupcheck-sdk
Version: 0.1.3
Summary: Python client for the SignupCheck anti-abuse API
Author-email: Visian Systems <support@signupcheck.com>
License-Expression: MIT
Project-URL: Homepage, https://signupcheck.com
Project-URL: Repository, https://gitlab.com/visian/infra-structure/signupcheck-sdk
Project-URL: Issues, https://gitlab.com/visian/infra-structure/signupcheck-sdk/-/issues
Keywords: signupcheck,anti-abuse,api,sdk,openapi
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: urllib3<3.0.0,>=2.1.0
Requires-Dist: python-dateutil>=2.8.2
Requires-Dist: pydantic>=2.11
Requires-Dist: typing-extensions>=4.7.1
Provides-Extra: dev
Requires-Dist: pytest>=7.2.1; extra == "dev"
Requires-Dist: pytest-cov>=2.8.1; extra == "dev"
Requires-Dist: build>=1.0.0; extra == "dev"
Requires-Dist: twine>=5.0.0; extra == "dev"

# signupcheck-sdk

Python client for the [SignupCheck](https://signupcheck.com) anti-abuse API — block disposable emails, VPNs, proxies, bots, and malicious IPs at signup.

## Install

```bash
pip install signupcheck-sdk
```

Requires Python 3.9+.

## Quick start

```python
import os
import signupcheck
from signupcheck.models.evaluate_signup_request import EvaluateSignupRequest

cfg = signupcheck.Configuration(host="https://api.signupcheck.com")
cfg.api_key["API Key"] = os.environ["SIGNUPCHECK_API_KEY"]

with signupcheck.ApiClient(cfg) as client:
    api = signupcheck.DecisionEngineApi(client)
    resp = api.evaluate_signup(EvaluateSignupRequest(
        email="user@example.com",
        ip="1.2.3.4",
    ))
    print(resp.decision, resp.risk_score)
```

The client reads the API key via the `X-API-Key` header. To use Bearer auth instead:

```python
cfg.api_key["Bearer"] = os.environ["SIGNUPCHECK_API_KEY"]
cfg.api_key_prefix["Bearer"] = "Bearer"
```

## Available APIs

| Class              | Endpoint prefix          | Purpose                                |
|--------------------|--------------------------|----------------------------------------|
| `DecisionEngineApi`| `/v1/evaluate/signup`    | ALLOW / CHALLENGE / BLOCK decision     |
| `ChecksApi`        | `/v1/evaluate/{email,ip}`| Standalone email / IP risk checks      |
| `ListsApi`         | `/v1/lists`              | Manage allow / block lists             |
| `RulesApi`         | `/v1/rules`              | Manage custom rules                    |
| `FeedbackApi`      | `/v1/feedback/signup`    | Submit outcome feedback                |
| `ObservabilityApi` | `/v1/events`, `/v1/metrics/signup` | Query events and metrics   |
| `AccountApi`       | `/v1/me`                 | Validate API key (no credit charge)    |

## Development

This package is generated from the OpenAPI spec in the [signupcheck API repo](https://gitlab.com/visian/infra-structure/signupcheck). To regenerate after a schema change, run `make sdk-python` in the API repo.

Local build and test from this directory:

```bash
make build      # python -m build → dist/
make check      # twine check dist/*
```

## License

Proprietary. See the repository for terms.
