Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/aditeyabaral/redirector
A simple link redirecting service built using Flask
https://github.com/aditeyabaral/redirector
flask flask-sqlalchemy python3 redirect-urls redirecting-requests sqlalchemy
Last synced: 3 months ago
JSON representation
A simple link redirecting service built using Flask
- Host: GitHub
- URL: https://github.com/aditeyabaral/redirector
- Owner: aditeyabaral
- Created: 2021-02-26T12:31:44.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2022-10-01T06:59:09.000Z (over 2 years ago)
- Last Synced: 2023-04-28T22:11:38.664Z (almost 2 years ago)
- Topics: flask, flask-sqlalchemy, python3, redirect-urls, redirecting-requests, sqlalchemy
- Language: Python
- Homepage: https://goto-link.herokuapp.com
- Size: 17.6 KB
- Stars: 4
- Watchers: 2
- Forks: 2
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# redirector
Redirector is a simple link redirecting service. Built using Flask and SQLAlchemy, it aims to provide a way to shorten and redirect links but usually fails at the former.
# How to use Redirector?
## Creating redirecting links
Since I'm awful at making pretty interfaces, creation of redirection links can currently only take place using POST requests.
Use the following Python script to make a POST request and create your link.
```Python
import sys
import requestsparams = {
"source_url" = sys.argv[1],
"alias_url" = sys.argv[2]
}response = requests.post("https://goto-link.herokuapp.com/register", data=params)
print(str(response.content))
```Execute the above script using
```bash
python3 source_url alias_url
```Example, use
```bash
python3 https://github.com/ git
```## Accessing redirecting links
You can access an alias link using `goto-link/alias_name`
# Why use Redirector?
* Open Source
Yup, that's the only advantage I can think of.
# Why not to use Redirector?
* The alias links may not be always shorter because of the size of the link prefix
* Creation of alias links is tedious (for now)It is not as bad as it sounds though.
# How to contribute to Redirector?
A pretty interface to create alias links would be a good starting point.
# Why did I make a link redirecting service?
Honestly, even I do not know why this exists.