rush-api is a URL shortener, made in Flask.
- Account registration
- TOTP one time password security, when generating tokens.
- Automatically enabled for all accounts for absolute security.
- In the future, I will add option to enable the requirement for each time the API request is sent.
- Custom URL generation for premium accounts
- Must be set manually for each account in the database.
- Your external billing system should call
/update_account_premium
endpoint to do so.
- Visitor number tracking
- URL validation
- Auto deletion after 30 days of URLs after creation or last visit
- Async task to clean up old URLs is not implemented yet!
- Domain blacklist
curl http://127.0.0.1:8080/create_redirect -X POST -d "url=https://youtu.be/FTQbiNvZqaY"
{"shortened_url": "http://127.0.0.1:8080/u/8IgjK1T"}
curl http://127.0.0.1:8080/my_urls --header "Authorization: tF9y4lcvaY80FkqxIsL1fE7cnCslfeVe"
[
{
"author_id": 1,
"creation_timestamp": 1639675025,
"delete_after": null,
"id": "your-custom-id",
"last_visit": 1639675025,
"premium": 1,
"url": "https://youtu.be/FTQbiNvZqaY",
"visits": 0
}
]