Skip to content

Open-source social media scheduler built for AI agents and the teams behind them. Create, schedule and publish posts to every network through MCP or the REST API, or write them yourself in a composer your team will love.

301 B
Raw Blame
export const extractErrorMessage = (error: unknown): string | null => {
    const data = (error as { response?: { data?: string } })?.response?.data;
    if (typeof data !== 'string') return null;
    try {
        return JSON.parse(data)?.message ?? null;
    } catch {
        return null;
    }
};