Skip to content

Instantly share code, notes, and snippets.

general_settings:
master_key: sk-ADMIN-KEY # your admin key
user_header_name: X-OpenWebUI-User-Email
litellm_settings:
disable_end_user_cost_tracking: false
disable_end_user_cost_tracking_prometheus_only: false
extra_spend_tag_headers:
- "X-OpenWebUI-User-Email"
curl -H "Authorization: Bearer $OPENWEBUI_API_KEY" http://localhost:3000/api/models
{
"$schema": "https://opencode.ai/config.json",
// 3-a. Register WebUI as a provider
"provider": {
"openwebui": {
"npm": "@ai-sdk/openai-compatible", // tells OpenCode the wire protocol
"name": "Open WebUI (local)", // label shown in the /models list
"options": {
"baseURL": "http://localhost:3000/api" /* <-- your URL here */
ARG PY_BASE=fcr.fmr.com/python:3.11-slim
FROM ${PY_BASE} as runtime
ENV HOME=/home/litellm
RUN useradd -m -s /bin/bash litellm && python -m venv ${HOME}/venv
ENV PATH="${HOME}/venv/bin:${PATH}" PYTHONHTTPSVERIFY=0
USER litellm
WORKDIR /app
ARG LITELLM_VERSION=1.74.3
ARG EXTRAS="proxy,prometheus,prisma,langfuse"
RUN --mount=type=cache,target=${HOME}/.cache/pip pip install --no-cache-dir --trusted-host pypi.org --trusted-host files.pythonhosted.org "litellm[${EXTRAS}]==${LITELLM_VERSION}"
import { useQueries } from '@tanstack/react-query';
function useAggregatedIncidents() {
const queryClient = useQueryClient();
const groupIds = ['group1', 'group2', 'group3'];
// Dynamically create queries for each group
const groupQueries = useQueries({
queries: groupIds.map((groupId) => ({
queryKey: ['incidents', groupId],
import React from ‘react’;
import { Box, Typography, Chip, Link, Paper, useTheme } from ‘@mui/material’;
import { AssetCodeCoverageInfo } from ‘../../types/api’;
import DonutChart from ‘./DonutChart’;
import moment from ‘moment’;
interface ExtendedAssetCodeCoverageInfo extends AssetCodeCoverageInfo {
codeSmells?: number;
codeQuality?: string;
codeCoverageReportUrl?: string;
import React from ‘react’;
import { Box, Typography, Chip, Link, Paper } from ‘@mui/material’;
import { PieChart, Pie, Cell, ResponsiveContainer } from ‘recharts’;
const ExpandedCodeCoverageContent = ({ data }) => {
// Transform coverage percentage for the donut chart
const chartData = [
{ name: ‘Covered’, value: data.coverage },
{ name: ‘Uncovered’, value: 100 - data.coverage }
];
{
"apNumber": "49201",
"certificates": [
{
"id": "83d1042f-c9da-48b0-a4b0-35cfdb7b4d31",
"certName": "www.store-east.example.com",
"expiresAt": "2025-10-04T18:25:43Z",
"daysRemaining": 103
},
{
const BlueEntityRefLink = styled(EntityRefLink)({
'& a': {
color: '#1976d2',
textDecoration: 'none',
'&:hover': {
color: '#1565c0',
textDecoration: 'underline',
},
},
});
import React, { useState } from 'react';
import {
Box,
IconButton,
styled,
Stack,
Typography,
} from '@mui/material';
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
import ExpandLessIcon from '@mui/icons-material/ExpandLess';