hvergelmir/4 mfe.image.backend 4.1.50
This Self-contained System provides a web component for backend management of media (images/videos) as a module federation, along with the required frontend API.
#svelte5 #express #typescript #self-contained-systems #module-federation #web-component #docker #sbom #SLSA #signed-image
Endpoints
| 🟢 | Production ready |
| 🟡 | In development |
| 🔴 | Not implemented |
| method endpoint | authorization | execution | tests | contents | |
|---|---|---|---|---|---|
| 🟡 GET | /remoteEntry.js | none | sync | 0 |
This route provides a Web Component of the backoffice application, exposed as a remote module for integration via Module Federation. How to include in host application
// webpack.config
let remotes = {
ModuleImageBackoffice :
'ModuleImageBackoffice@https://mfe-image.neolith.cloud/remoteEntry.js'
}
import('ModuleImageBackoffice/AppImage').then(() => {
// The web component is now defined and can be used in the DOM
});
Usage
<mfe-image name="microfrontend-image-backoffice"></mfe-image>
Example
import('ModuleImageBackoffice/AppImage').then(() => {
const el = document.createElement('mfe-image');
el.setAttribute('name', 'microfrontend-image-backoffice');
document.body.appendChild(el);
});
|
| 🟢 GET | /healthcheck | none | sync | 2 | Used internally for the healthcheck in docker compose. Returns uptime of service. |
| 🟢 GET | /websocket | JWT | sync | 0 | Returns WebSocket endpoint for the AWS Events API, including the required system identifier and authorization token. |
| 🟡 POST | /image | JWT | sync | 0 | |
| 🟢 GET, 🟡 PUT, 🟡 DELETE | /image/:uuid | JWT | sync | 1 | Returns all metadata for an image, updates it, or deletes the image. |
| 🔴 GET | /info | JWT | sync | 0 | |
| 🟢 GET | /tree/latest-categories | JWT | sync | 1 | Returns the latest published category with localized content. |
| 🟢 GET | /tree/:uuid | JWT | sync | 1 | Returns a localized category tree and latest categories. |
| 🟢 POST | /exif | JWT | sync | 0 | Extracts and normalizes EXIF metadata from an uploaded image, with camera-specific corrections for misleading or incorrect dates. |
| 🟢 GET, 🟢 POST | /geocode | JWT | sync | 12 | Provides reverse and forward geocoding with elevation data using Google Maps APIs. |
| 🔴 POST | /translate | JWT | sync | 0 | |
| 🔴 PATCH | /publish | JWT | sync | 0 | |
| 🔴 PATCH | /unpublish/:uuid | JWT | sync | 0 | |
| 🔴 DELETE | /thumbnailcache/:uuid | JWT | sync | 0 | |
Corresponding documentation for both interfaces can be found behind the following links:
- REST API
- Swagger