mirror of
https://github.com/gethomepage/homepage.git
synced 2025-12-07 09:35:54 -08:00
25 lines
490 B
JavaScript
25 lines
490 B
JavaScript
import genericProxyHandler from "utils/proxy/handlers/generic";
|
|
import { asJson } from "utils/proxy/api-helpers";
|
|
|
|
const widget = {
|
|
api: "{url}/api/v3/{endpoint}?apikey={key}",
|
|
proxyHandler: genericProxyHandler,
|
|
|
|
mappings: {
|
|
series: {
|
|
endpoint: "series",
|
|
map: (data) => ({
|
|
total: asJson(data).length,
|
|
}),
|
|
},
|
|
queue: {
|
|
endpoint: "queue",
|
|
},
|
|
"wanted/missing": {
|
|
endpoint: "wanted/missing",
|
|
},
|
|
},
|
|
};
|
|
|
|
export default widget;
|