Skip to content

yuukis/yamanashi-event-api

Repository files navigation

Test DockerHub

Yamanashi Tech Events API

About The Project

This is a simple API for Yamanashi Tech Events. It retrieves event data from Connpass via API.

This API is available at the following URL.

https://api.event.yamanashi.dev

Getting Started

Prerequisites

  • Python 3.9 or later
  • Redis

Installation

  1. Clone the repo
    git clone https://github.com/yuukis/yamanashi-events-api.git
  2. Install Python packages
    pip install -r requirements.txt
  3. Copy .env.example to .env and set environment variables
    REDIS_URL=redis://localhost:6379
  4. Run the app
    uvicorn app.main:app --reload
  5. Access to http://localhost:8000

Docker Compose Installation

If you have Docker and Docker Compose installed, you can use the following steps to get the project running:

  1. Clone the repo

    git clone https://github.com/yuukis/yamanashi-events-api.git
  2. Build and run the Docker services

    docker-compose up --build
  3. Access to http://localhost:8000

Usage

  • Get recent events

    curl http://localhost:8000/events
  • Get today's events

    curl http://localhost:8000/events/today
  • Get events by year/month

    curl http://localhost:8000/events/in/2023/12
  • Get events by date range

    curl http://localhost:8000/events/from/2023/12/to/2024/02
  • Get events by keyword

    curl http://localhost:8000/events?keyword=Python

See API document for more details.

License

Distributed under the Apache License, Version 2.0. See LICENSE for more information.

Contact

Yuuki Shimizu - @yuuki_maxio

Acknowledgements