An open API service indexing awesome lists of open source software.

https://github.com/dogukanurker/astronomicaldistanceconverterapi

Astronomical unit converter API built with FastAPI.🌌
https://github.com/dogukanurker/astronomicaldistanceconverterapi

Last synced: 3 months ago
JSON representation

Astronomical unit converter API built with FastAPI.🌌

Awesome Lists containing this project

README

        

# AstronomicalDistanceConverterAPI

Astronomical unit converter API built with FastAPI.🌌

### [Demo Video 📺](https://youtu.be/-jrgWP_N6xk)

## Requirements 📦

- FastAPI
- Uvicorn

## Installation ⬇️

download source code from Github 💾
`git clone https://github.com/DogukanUrker/AstronomicalDistanceConverterAPI.git`

go to directory 📁
`cd AstronomicalDistanceConverterAPI`

install requirements.txt 🔽
`pip install -r requirements.txt`

it's ready to run 🎉
`python main.py`

## Requests 📚

Convert X to Y.

```
/x/y/{int}
```
X and Y can be:
- astronomical-unit / au
- kilometer / km
- light-minute / lm
- light-second / ls
- light-year / ly
- miles / mi
- parsec / pc

Note:
If X value is abbreviation then Y value must be abbreviated to, same for full unit names.

Examples:

```
/ly/km/1
```

```
9460730472580.8
```

```
/astronomical-unit/light-second/1
```

```
499.00478
```

```
/parsec/mi/1
```

```json
{
"detail": "Not Found"
}
```

### Contributors 💕

### Support 💰

Buy Me A Coffee