A backend service for processing and managing images with basic transformations. Designed to handle low to medium workloads, this service integrates seamlessly with AWS S3 and supports modern API practices.
- Transformations:
- Resize
- Crop
- Rotate
- Flip
- Filters
- Modulation
- Gamma
- Gaussian Blur
- Grayscale
- Sharpness
- Format (in dev)
- Storage: Upload images to AWS S3 with optional metadata and manage storage efficiently.
- OpenAPI:
- Fully documented APIs for easy integration.
- Backend
- Go for image processing backend service
- Storage
- AWS S3 for reliable and scalable file storage
- Image Processing
- Leveraging the
govipslibrary for faster and memory-efficient operations
- Leveraging the
OpenAPI documentation is available at /swagger/index.html once the service is running
- Go 1.18+ installed.
- AWS account with S3 access
git clone https://github.com/yourusername/image-processing-service.git
cd image-processing-service- Create a
.envfile in the project root:AWS_ACCESS_KEY_ID=your-access-key AWS_SECRET_ACCESS_KEY=your-secret-key S3_BUCKET_NAME=your-bucket-name S3_REGION=your-region
go run cmd/main.go- POST
/images/upload- Upload an image to AWS S3 bucket.
- Request body:
multipart/form-data
- GET
images?key=image.jpg- Fetch the required image if available
- GET
images/all?page=2&limit=15- Fetch a paginated list of images
- POST
/images/transform - Request body:
{ "image": "image-key-in-s3", "output": "output-image-name", "transformation": { "resize": { "width": 200, "height": 200 }, "crop": { "x": 10, "y": 10, "width": 100, "height": 100 }, "rotate": { "angle": 90 }, "filters": { "brightness": 1.2, "contrast": 1.0 } } }
- Scalable Architecture:
- Microservices-based architecture with a Gateway and OAuth2 for authentication.
- Performance Optimization
- User Account Management
- Front-End (e.g React, HTMX)/Mobile App (e.g iOS)
- GraphQL based requests
- Implement CI/CD pipeline
- Expand Cloud Support
- Advanced Transformations