Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/jorgechato/short-url

Just a simple, yet effective toolset for personal use. I don't want to be tracked with shorten url servers.
https://github.com/jorgechato/short-url

Last synced: about 2 months ago
JSON representation

Just a simple, yet effective toolset for personal use. I don't want to be tracked with shorten url servers.

Awesome Lists containing this project

README

        

# SHORT URL Toolset

> [!WARNING]
> Set up the repository with the proper hooks. Run `pre-commit install` in the root directory of the repository.

## API

| Method | Endpoint | Description | Response | isPublic |
| --- | --- | --- | --- | --- |
| GET | `/{id}` | Redirects to the original URL | Redirect | :o: |
| POST | `/` *Body:* `{ "original": "string" }` | Creates a new short URL | `{ "short": "string", "original": "string" }` | :x: |
| DELETE | `/{id}` | Deletes the short URL | `{ "message": "string" }` | :x: |
| GET | `/search?query={string}` | Returns all short URLs matching the query | `[{ "short": "string", "original": "string", "hits": "number" }]` | :x: |

## Authentication

To authenticate use a signature ssh key. The key must be added to the repository secrets.

## Folder Structure

```sh
.
├── db # SQLite3 schema for short URLs and SSH Auth
├── docs # Documentation for the DB schema
├── src # Source code
└── tf # Terraform files for infrastructure and deployment
```