Skip to main content

Festival API — Python Client

Client library for the Festival API.

pip install festivalapi

Usage

from festivalapi import FestivalAPI

client = FestivalAPI("fes_your_api_key")

# Search festivals by category (supports page/per_page pagination)
festivals = client.festivals.list(category="short_film")
# Pagination: client.festivals.list(category="short_film", page=2, per_page=50)

# Keyword search
results = client.festivals.list(q="Cambodia")

# Get festival detail
festival = client.festivals.get(1)

# Get festival roster (past winners / screened films, supports pagination)
roster = client.festivals.roster(1)
# Pagination: client.festivals.roster(1, page=2, per_page=50)

# Get scored festivals (supports page/per_page)
scored = client.festivals.scored(min_score=70)
# Pagination: client.festivals.scored(page=2, per_page=50)

# List available category codes (requires auth)
categories = client.categories()
for cat in categories["results"]:
    print(f'{cat["category"]} ({cat["count"]})')

# List available countries with festival counts (requires auth)
countries = client.countries()
for c in countries["results"]:
    print(f'{c["country"]} ({c["count"]})')

# Health check (no auth)
client.health()

Categories

Call client.categories() to get all available category codes. Returns:

{
  "count": 158,
  "results": [
    {"category": "short_film", "count": 60},
    {"category": "feature", "count": 55},
    {"category": "documentary", "count": 31},
    {"category": "animation", "count": 14},
    {"category": "horror", "count": 12},
    {"category": "experimental", "count": 10},
    {"category": "ai", "count": 10},
    {"category": "music_video", "count": 14},
    {"category": "web_series", "count": 9},
    {"category": "comedy", "count": 5},
    {"category": "sci_fi", "count": 5},
    {"category": "student", "count": 5},
    {"category": "lgbtq", "count": 3},
    {"category": "vr_360", "count": 2},
    ...
  ]
}

Common filters: short_film, feature, documentary, animation, horror, sci_fi, comedy, experimental, music_video, ai, web_series, student, lgbtq, vr_360.

Use the category field (lowercase) as the filter value — e.g. client.festivals.list(category="horror").

Countries

Call client.countries() to get all countries with festival counts. Returns:

{
  "count": 70,
  "results": [
    {"country": "United States", "count": 448},
    {"country": "United Kingdom", "count": 48},
    {"country": "Canada", "count": 46},
    {"country": "India", "count": 35},
    {"country": "Germany", "count": 37},
    {"country": "Italy", "count": 33},
    {"country": "France", "count": 20},
    ...
  ]
}

Use the country name as the filter value — e.g. client.festivals.list(country="United States").

API Key

Sign up at festivalapi.com to get your API key (starts with fes_). You can also set the FESTIVALAPI_KEY environment variable.

Error Handling

from festivalapi import FestivalAPI, NotFoundError, InsufficientCreditsError

client = FestivalAPI("fes_your_api_key")

try:
    festival = client.festivals.get(999999)
except NotFoundError:
    print("Festival not found")
except InsufficientCreditsError as e:
    print(f"Need more credits: {e}")

Requirements

  • Python 3.9+
  • Zero dependencies (uses only stdlib urllib)

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

festivalapi-0.2.4.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

festivalapi-0.2.4-py3-none-any.whl (5.5 kB view details)

Uploaded Python 3

File details

Details for the file festivalapi-0.2.4.tar.gz.

File metadata

  • Download URL: festivalapi-0.2.4.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for festivalapi-0.2.4.tar.gz
Algorithm Hash digest
SHA256 6345f09a5e93f03bf8e52fac07d886f594c1cb1f8eca0085e922ad75ec0f2632
MD5 0f3c6cc8a946def497b7ad5038caeb06
BLAKE2b-256 396257a35e77179f4bc93f1b55606c2c7c3b0d7d43b7de6862a640c713af6014

See more details on using hashes here.

File details

Details for the file festivalapi-0.2.4-py3-none-any.whl.

File metadata

  • Download URL: festivalapi-0.2.4-py3-none-any.whl
  • Upload date:
  • Size: 5.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for festivalapi-0.2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 23da0a6803cbd6b8211724248efb975d807580a6f674ed1420152ee71799a068
MD5 d707651b774bb65fe92b6e01a6d6eafe
BLAKE2b-256 d0f1ef733b46cf103a1f26c5ac006511a69bc11eec803f8b50e0b921d6b716b8

See more details on using hashes here.

Release history Release notifications | RSS feed

0.2.8

2 files

0.2.7

2 files

0.2.6

2 files

0.2.5

2 files

This release

0.2.4 This release

2 files

0.2.3

1 file

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page