This API allows you to create and manage shortened URLs. It provides endpoints to create new short URLs, retrieve existing URLs by ID or original URL, redirect to the original URL from the short URL, update existing URLs, and delete URLs.
- URL:
POST /
- Description: Create a new short URL.
- Request Body: JSON object containing the original URL.
- Response: Newly created short URL.
- URL:
GET /all
- Description: Get all existing short URLs.
- Response: List of all short URLs.
- URL:
GET /{id}
- Description: Get a short URL by its ID.
- Response: Short URL object.
- URL:
GET /OriginalUrl/{originalUrl}
- Description: Get a short URL by its original URL.
- Response: Short URL object.
- URL:
GET /{shortUrl}
- Description: Redirect to the original URL associated with the short URL.
- Response: Redirect to the original URL.
- URL:
PUT /{id}
- Description: Update an existing short URL by its ID.
- Request Body: JSON object containing the updated URL details.
- Response: No content.
- URL:
DELETE /{id}
- Description: Delete a short URL by its ID.
- Response: No content.
To get started with the Paroot API, follow these steps:
- Clone this repository to your local machine.
- Restore dependencies using
dotnet restore
. - Run the application using
dotnet run
. - Use the provided endpoints to interact with the API.
If you have any questions or feedback, feel free to contact us at juanesbs2003@hotmail.com.
This API is designed to provide URL shortening functionality and can be integrated into various applications where such functionality is required.