semvec/pypi-packages huggingface dataset:
cito-api 1.0.0
Python SDK for Cito API - Call of Duty & Fortnite Esports Data
License: MIT
Requires Python: >=3.8
Keywords: call of duty, cod, fortnite, esports, api, gaming, cdl, competitive gaming, statistics, players, tournaments

# Cito API - Python SDK

Official Python SDK for [Cito API](https://citoapi.com) - the esports data API for Call of Duty and Fortnite.

## Installation

```bash
pip install cito-api
```

## Quick Start

```python
from cito_api import CitoAPI

# Initialize with your API key
api = CitoAPI("your-api-key")

# Get COD players
players = api.cod.get_players(limit=10)
print(players)

# Get a specific player
player = api.cod.get_player("Shotzzy")
print(player)

# Get CDL standings
standings = api.cod.get_cdl_standings()
print(standings)
```

## Features

### Call of Duty Esports

- **Players**: Get player profiles, stats, earnings, and career history
- **Teams**: CDL franchises, rosters, tournament results
- **Tournaments**: CDL Majors, Challengers events, match results
- **Transfers**: Roster moves and player transfers
- **CDL Live**: Real-time standings, schedules, live matches
- **Leaderboards**: Earnings, K/D, hardpoint time, S&D stats

### Fortnite Esports

- **Players**: Pro player profiles and earnings
- **Organizations**: Team rosters and results
- **Tournaments**: FNCS, cash cups, and major events
- **Transfers**: Roster changes

## API Reference

### COD Endpoints

```python
# Players
api.cod.get_players(limit=50, nationality="US", team="optic")
api.cod.get_player("player-id")
api.cod.get_player_earnings("player-id")
api.cod.get_player_stats("player-id", season="2024")

# Teams
api.cod.get_teams(limit=50, franchise_only=True)
api.cod.get_team("optic-texas")
api.cod.get_team_roster("optic-texas")
api.cod.get_team_results("optic-texas")

# Tournaments
api.cod.get_tournaments(game="bo6", tier="S")
api.cod.get_tournament("tournament-id")
api.cod.get_tournament_results("tournament-id")
api.cod.get_tournament_matches("tournament-id")

# Transfers
api.cod.get_transfers(type="transfer")

# CDL
api.cod.get_cdl_standings()
api.cod.get_cdl_schedule(upcoming=True)
api.cod.get_cdl_live()

# Leaderboards
api.cod.get_earnings_leaderboard(limit=100)
api.cod.get_leaderboard("hardpoint")
api.cod.get_leaderboard("snd")
api.cod.get_leaderboard("kd")

# Search
api.cod.search("Shotzzy", type="players")
```

### Fortnite Endpoints

```python
api.fortnite.get_players(limit=50)
api.fortnite.get_player("player-id")
api.fortnite.get_teams()
api.fortnite.get_tournaments()
api.fortnite.search("Bugha")
```

## Get Your API Key

Sign up at [citoapi.com](https://citoapi.com) to get your free API key.

## Links

- Website: https://citoapi.com
- Documentation: https://docs.citoapi.com
- RapidAPI: https://rapidapi.com/citoapi

## License

MIT License
django-nanoid-field 0.1.5
Next generation NanoID in Django Model IDs
License: MIT
Keywords: django, nanoid, django-field

# Django NanoID Field

NanoID is an alternative to UUID, CUID for generating random IDs. This package
provides a field to use in models.


## Roadmap

- [ ] Create `AutoField` that uses NanoID instead of regular integer ID.


## Installation

Install it from PyPI:

```sh
pip install django-nanoid-field
```


## Usage

You can use it in your models like:

```python
from django.db import models
from nanoid_field import NanoidField

class Profile(models.Model):
    hash = NanoidField(max_length=10, alphabet='0123456789abcdefghijklmnopqrstuvwxyz')
```


## NanoidField

This model field is based on `CharField`. All of it's parameters can be used.

Additionally following fields affects outcome of NanoID:


### `max_length` Parameter (Optional)
Determines size of the generated ID as well as length of the field in Database.

#### **DEFAULT:**
```
21
```


### `alphabet` Parameter (Optional)
This optional parameter helps you to determine which characters will be used to
build up.

#### **DEFAULT:**
```
0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz-
```


## Using NanoidField as `primary_key`
To use NanoID as default `primary_key` you need to explicitly define it in your
model:

```python
from django.db import models


class SomeModel(models.Model):
    id = NanoidField()
    # ...
```

A good practice is to create a base model. It also helps you to add generic
methods to all of your models.

Create a file named `base_model.py` one of the root `models` directory:

```python
from django.db import models


class BaseModel(models.Model):
    id = NanoidField()

    class Meta:
        abstract = True
```

Then you can exten from it in any model you'd like:

```python
from django.db import models
from app.models.base_model import BaseModel


class Product(BaseModel):
    name = models.CharField()
```


## Changing defaults
`django-nanoid-field` also provides two settings to change defaults of `alphabet`
and `max_length`. You can change those by adding them to your `settings.py` file

```python
# settings.py file

NANOID_ALPHABET = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz-"
NANOID_SIZE = 21
```