Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project’s status.
Connect AnythingLLM’s native MCP client to Magic Hour, then use @agent to retrieve
an image project you already created. This setup enables only the read-only image
retrieval tool. It does not require another generation or a new model-provider key
when you use your own local Ollama model.
Use a protected self-hosted AnythingLLM instance with administrator access, a
Magic Hour API key, and an existing
image project owned by that account. These instructions cover self-hosted
AnythingLLM 1.18.0.Have a tool-capable model installed and reachable from AnythingLLM. This flow was
verified with Ollama 0.40.10 and qwen2.5:7b-instruct-q4_K_M at a 4096-token context:
one native agent run retrieved an existing completed image project. No new Magic
Hour generation was needed. Other models may choose or format tool calls differently.
AnythingLLM stores MCP headers as plaintext in its instance-wide configuration
file. Administrators and anyone who can read that file can access the API key;
other enabled Magic Hour tools could spend credits. Use a dedicated key, restrict
the file to the application owner with permissions 0600, protect the instance,
and keep configuration exports, logs and screenshots private. Do not put the key
in a chat prompt.
In the instance’s storage directory, open or create
plugins/anythingllm_mcp_servers.json. Merge this entry into any existing
mcpServers object; preserve other servers:
The full path is <STORAGE_DIR>/plugins/anythingllm_mcp_servers.json. The
standard Docker storage path is
/app/server/storage/plugins/anythingllm_mcp_servers.json; edit the corresponding
file in the host storage mount.
Open Settings → Agent Skills. In the MCP section, click Refresh and
confirm the server restart. Select Magic Hour. Public discovery returns
tools without an API key; it does not prove account access.
Turn off every Magic Hour tool except image_projects_retrieve_details.
The verified inventory had 48 tools, leaving 1/48 tools enabled.
Turn off RAG & long-term memory, View & summarize documents,
Scrape websites, and Web Search, then click Save. Keep other agent
skills, imported skills, flows and clarifying questions disabled for this
read-only setup.
Reload the page and refresh the MCP server once more. Confirm that only the
image retrieval tool remains enabled and the four core skills remain off.
Tool selection and MCP configuration apply across the instance. Use a dedicated
instance if changing these settings would affect other users or workspaces.
Replace the placeholder with your actual key in the protected configuration file.
AnythingLLM reads this as a literal header: ${MAGIC_HOUR_API_KEY} is not expanded
from an environment variable. Keep the Bearer prefix and never commit the file.Refresh the MCP server through the same native UI, then check that the one-tool
selection is still saved. A connected server or successful discovery alone does
not verify the API key; the authenticated project request does.
Open AI Providers → LLM and select Ollama. Set its reachable base URL,
select your installed model, set the context size, and click Save changes.
If AnythingLLM runs in Docker, localhost refers to that container; use the
Ollama service’s reachable address on your configured network.
Create a workspace. In its Agent Configuration, select Ollama and the
same model. Allow the normal settings save to finish.
Send one message in that workspace, replacing YOUR_PROJECT_ID with your own
saved image project ID:
@agent Use only magic-hour-image_projects_retrieve_details with id YOUR_PROJECT_ID. Return only a JSON object with the returned id and status. Do not call other tools or include download URLs.
The request retrieves a status snapshot; it does not poll, create a replacement
job or download an image. If the project is still processing, check the same ID
again later. Your model’s inference may have costs even though this Magic Hour
operation creates no new generation.
Look for the native tool invocation and its completion before relying on the
agent’s answer. Confirm that the returned ID matches your saved project and inspect
its status. A model-written complete without an actual successful tool invocation
is not evidence that Magic Hour was contacted.For an authorization error, check the literal bearer header and that the project
belongs to the key’s account. After editing the configuration, refresh the native
MCP server and recheck the saved tool selection. Do not enable creation or deletion
tools to troubleshoot a read-only retrieval.Project results may contain temporary signed download URLs. Keep raw tool results
and instance logs private; do not share them with the configuration file or key.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Magic Hour API Docs","description":"Easily generate videos, images, and audio using Magic Hour's API. Follow our documentation to seamlessly integrate AI content creation into your applications.","colors":{"primary":"#3b82f6","light":"#0564ff","dark":"#3b82f6"},"logo":{"light":"https://mintcdn.com/magichour/5sgGJpuuipkw5s5v/icons/logo-light.svg?fit=max\u0026auto=format\u0026n=5sgGJpuuipkw5s5v\u0026q=85\u0026s=1f167e30baf11927bc2e0932411e455b","dark":"https://mintcdn.com/magichour/5sgGJpuuipkw5s5v/icons/logo-dark.svg?fit=max\u0026auto=format\u0026n=5sgGJpuuipkw5s5v\u0026q=85\u0026s=15c8bda28931ac4e1e2fab2c0ba6f0d5"},"favicon":"https://mintcdn.com/magichour/kbUwXh9ksnVyRSci/icons/favicon.png?fit=max\u0026auto=format\u0026n=kbUwXh9ksnVyRSci\u0026q=85\u0026s=c4fda903b24dd7067dadd1bb75508987","appearance":{"default":"dark","strict":false},"background":{"decoration":"gradient"},"navbar":{"links":[{"href":"mailto:support@magichour.ai","label":"Support"}],"primary":{"type":"button","label":"Get API key","href":"https://magichour.ai/developer?tab=api-keys\u0026ref=docs-navbar\u0026utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=navbar"}},"footer":{"socials":{"website":"https://magichour.ai/?utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=footer","x":"https://x.com/magichourai","github":"https://github.com/magichourhq","linkedin":"https://linkedin.com/company/magichour","instagram":"https://instagram.com/magichourai","youtube":"https://youtube.com/@magichourai"}},"seo":{"metatags":{"og:image":"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg","twitter:image":"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg"}},"integrations":{"ga4":{"measurementId":"G-CZ9Q9NBZB3"},"posthog":{"apiKey":"phc_EmzSy2RU0TOPhpouazMzxFedNdMyhze8HakyjffW2Wr","apiHost":"https://us.i.posthog.com"}},"contextual":{"options":["chatgpt","claude","perplexity","mcp","cursor","vscode","copy","view"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"API quickstart","icon":"forward-fast","href":"/get-started/quick-start"},{"anchor":"API pricing","icon":"credit-card","href":"/billing/overview"},{"anchor":"Community","icon":"discord","href":"https://discord.com/invite/JX5rgsZaJp"},{"anchor":"Status","icon":"wave-pulse","href":"https://status.magichour.ai"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"magichour","hasAudioNarration":false,"actualSubdomain":"magichour","customDomains":["docs.magichour.ai"],"gitSource":{"type":"github","owner":"magichourhq","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6add0474a858e98981adee7c","collectionId":"9d773285-8d57-4639-859d-4a3937e2df09","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6add0474a858e98981adee7c"},"feedback":{"thumbs":true,"issues":true,"edits":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6add1bb329f48133ead159ab","clientVersion":"0.0.3965","searchFilterCounts":[{"language":"default","tag":"Documentation","count":85},{"language":"default","tag":"Integration","count":44},{"language":"default","tag":"API Reference","count":42},{"language":"default","tag":"Tools","count":30},{"language":"default","tag":"Image Projects","count":16},{"language":"default","tag":"Images","count":15},{"language":"default","tag":"Video Projects","count":14},{"language":"default","tag":"Video","count":12},{"language":"default","tag":"Webhook Reference","count":10},{"language":"default","tag":"Get Started","count":7}]},"assistantConfig":{},"hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#sidebar,#table-of-contents-content{scrollbar-width:thin;scrollbar-gutter:none;scrollbar-color:gray transparent}"}],"page":{"pagePath":"integration/anythingllm","slug":"/integration/anythingllm","pageMetadata":{"title":"AnythingLLM","description":"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project's status.","href":"/integration/anythingllm"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project’s status.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,..._provideComponents(),...props.components},{CodeBlock,Heading,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Connect AnythingLLM’s native MCP client to Magic Hour, then use `,_jsx(_components.code,{children:`@agent`}),` to retrieve\nan image project you already created. This setup enables only the read-only image\nretrieval tool. It does not require another generation or a new model-provider key\nwhen you use your own local Ollama model.`]}),`\n`,_jsx(Heading,{level:`2`,id:`before-you-start`,children:`Before you start`}),`\n`,_jsxs(_components.p,{children:[`Use a protected `,_jsx(_components.a,{href:`https://docs.anythingllm.com/installation-docker/local-docker`,children:`self-hosted AnythingLLM instance`}),` with administrator access, a\n`,_jsx(_components.a,{href:`https://magichour.ai/developer?tab=api-keys`,children:`Magic Hour API key`}),`, and an existing\nimage project owned by that account. These instructions cover self-hosted\nAnythingLLM 1.18.0.`]}),`\n`,_jsxs(_components.p,{children:[`Have a tool-capable model installed and reachable from AnythingLLM. This flow was\nverified with Ollama 0.40.10 and `,_jsx(_components.code,{children:`qwen2.5:7b-instruct-q4_K_M`}),` at a 4096-token context:\none native agent run retrieved an existing completed image project. No new Magic\nHour generation was needed. Other models may choose or format tool calls differently.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`AnythingLLM stores MCP headers as plaintext in its instance-wide configuration\nfile. Administrators and anyone who can read that file can access the API key;\nother enabled Magic Hour tools could spend credits. Use a dedicated key, restrict\nthe file to the application owner with permissions `,_jsx(_components.code,{children:`0600`}),`, protect the instance,\nand keep configuration exports, logs and screenshots private. Do not put the key\nin a chat prompt.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`discover-and-restrict-the-tools`,children:`Discover and restrict the tools`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`In the instance’s storage directory, open or create\n`,_jsx(_components.code,{children:`plugins/anythingllm_mcp_servers.json`}),`. Merge this entry into any existing\n`,_jsx(_components.code,{children:`mcpServers`}),` object; preserve other servers:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`9`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`9`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"mcpServers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"magic-hour\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"streamable\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"url\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://mcp.magichour.ai/\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"headers\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {}`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The full path is `,_jsx(_components.code,{children:`\u003cSTORAGE_DIR>/plugins/anythingllm_mcp_servers.json`}),`. The\nstandard Docker storage path is\n`,_jsx(_components.code,{children:`/app/server/storage/plugins/anythingllm_mcp_servers.json`}),`; edit the corresponding\nfile in the host storage mount.`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Open `,_jsx(_components.strong,{children:`Settings → Agent Skills`}),`. In the MCP section, click `,_jsx(_components.strong,{children:`Refresh`}),` and\nconfirm the server restart. Select `,_jsx(_components.strong,{children:`Magic Hour`}),`. Public discovery returns\ntools without an API key; it does not prove account access.`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Turn off every Magic Hour tool except `,_jsx(_components.code,{children:`image_projects_retrieve_details`}),`.\nThe verified inventory had 48 tools, leaving `,_jsx(_components.strong,{children:`1/48 tools enabled`}),`.`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Turn off `,_jsx(_components.strong,{children:`RAG \u0026 long-term memory`}),`, `,_jsx(_components.strong,{children:`View \u0026 summarize documents`}),`,\n`,_jsx(_components.strong,{children:`Scrape websites`}),`, and `,_jsx(_components.strong,{children:`Web Search`}),`, then click `,_jsx(_components.strong,{children:`Save`}),`. Keep other agent\nskills, imported skills, flows and clarifying questions disabled for this\nread-only setup.`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsx(_components.p,{children:`Reload the page and refresh the MCP server once more. Confirm that only the\nimage retrieval tool remains enabled and the four core skills remain off.`}),`\n`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`Tool selection and MCP configuration apply across the instance. Use a dedicated\ninstance if changing these settings would affect other users or workspaces.`}),`\n`,_jsx(Heading,{level:`2`,id:`add-the-api-key`,children:`Add the API key`}),`\n`,_jsxs(_components.p,{children:[`Replace the empty `,_jsx(_components.code,{children:`headers`}),` object with:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`3`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`3`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"Authorization\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Bearer YOUR_MAGIC_HOUR_API_KEY\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Replace the placeholder with your actual key in the protected configuration file.\nAnythingLLM reads this as a literal header: `,_jsx(_components.code,{children:\"${MAGIC_HOUR_API_KEY}\"}),` is not expanded\nfrom an environment variable. Keep the `,_jsx(_components.code,{children:`Bearer `}),` prefix and never commit the file.`]}),`\n`,_jsx(_components.p,{children:`Refresh the MCP server through the same native UI, then check that the one-tool\nselection is still saved. A connected server or successful discovery alone does\nnot verify the API key; the authenticated project request does.`}),`\n`,_jsx(Heading,{level:`2`,id:`configure-the-model-and-workspace`,children:`Configure the model and workspace`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Open `,_jsx(_components.strong,{children:`AI Providers → LLM`}),` and select `,_jsx(_components.strong,{children:`Ollama`}),`. Set its reachable base URL,\nselect your installed model, set the context size, and click `,_jsx(_components.strong,{children:`Save changes`}),`.\nIf AnythingLLM runs in Docker, `,_jsx(_components.code,{children:`localhost`}),` refers to that container; use the\nOllama service’s reachable address on your configured network.`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Create a workspace. In its `,_jsx(_components.strong,{children:`Agent Configuration`}),`, select `,_jsx(_components.strong,{children:`Ollama`}),` and the\nsame model. Allow the normal settings save to finish.`]}),`\n`]}),`\n`,_jsxs(_components.li,{children:[`\n`,_jsxs(_components.p,{children:[`Send one message in that workspace, replacing `,_jsx(_components.code,{children:`YOUR_PROJECT_ID`}),` with your own\nsaved image project ID:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`@agent Use only magic-hour-image_projects_retrieve_details with id YOUR_PROJECT_ID. Return only a JSON object with the returned id and status. Do not call other tools or include download URLs.`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`The request retrieves a status snapshot; it does not poll, create a replacement\njob or download an image. If the project is still processing, check the same ID\nagain later. Your model’s inference may have costs even though this Magic Hour\noperation creates no new generation.`}),`\n`,_jsx(Heading,{level:`2`,id:`check-the-result`,children:`Check the result`}),`\n`,_jsxs(_components.p,{children:[`Look for the native tool invocation and its completion before relying on the\nagent’s answer. Confirm that the returned ID matches your saved project and inspect\nits status. A model-written `,_jsx(_components.code,{children:`complete`}),` without an actual successful tool invocation\nis not evidence that Magic Hour was contacted.`]}),`\n`,_jsx(_components.p,{children:`For an authorization error, check the literal bearer header and that the project\nbelongs to the key’s account. After editing the configuration, refresh the native\nMCP server and recheck the saved tool selection. Do not enable creation or deletion\ntools to troubleshoot a read-only retrieval.`}),`\n`,_jsx(_components.p,{children:`Project results may contain temporary signed download URLs. Keep raw tool results\nand instance logs private; do not share them with the configuration file or key.`})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"AnythingLLM","description":"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project's status.","href":"/integration/anythingllm"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Before you start","slug":"before-you-start","depth":2,"children":[]},{"title":"Discover and restrict the tools","slug":"discover-and-restrict-the-tools","depth":2,"children":[]},{"title":"Add the API key","slug":"add-the-api-key","depth":2,"children":[]},{"title":"Configure the model and workspace","slug":"configure-the-model-and-workspace","depth":2,"children":[]},{"title":"Check the result","slug":"check-the-result","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"magichour","siteName":"Magic Hour API Docs","title":"AnythingLLM - Magic Hour API Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-10-24T19:18:26.994Z","originalFileLocation":"integration/anythingllm.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project\u0026#x27;s status.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Magic Hour API Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"AnythingLLM - Magic Hour API Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project\u0026#x27;s status.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Magic Hour API Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.magichour.ai/integration/anythingllm\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"AnythingLLM - Magic Hour API Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project\u0026#x27;s status.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Magic Hour API Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3b82f6\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.magichour.ai/integration/anythingllm\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/integration/anythingllm.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.magichour.ai/#organization\",\"name\":\"Magic Hour API Docs\",\"url\":\"https://docs.magichour.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/magichour/5sgGJpuuipkw5s5v/icons/logo-light.svg?fit=max\u0026auto=format\u0026n=5sgGJpuuipkw5s5v\u0026q=85\u0026s=1f167e30baf11927bc2e0932411e455b\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.magichour.ai#website\",\"name\":\"Magic Hour API Docs\",\"url\":\"https://docs.magichour.ai\",\"publisher\":{\"@id\":\"https://docs.magichour.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.magichour.ai/integration/anythingllm#webpage\",\"url\":\"https://docs.magichour.ai/integration/anythingllm\",\"name\":\"AnythingLLM\",\"description\":\"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project's status.\",\"dateModified\":\"2026-10-24T19:18:26.994Z\",\"isPartOf\":{\"@id\":\"https://docs.magichour.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.magichour.ai/integration/anythingllm#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.magichour.ai/integration/anythingllm#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Integration\",\"item\":\"https://docs.magichour.ai/integration/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"AnythingLLM\",\"item\":\"https://docs.magichour.ai/integration/anythingllm\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.magichour.ai/integration/anythingllm#article\",\"headline\":\"AnythingLLM\",\"name\":\"AnythingLLM\",\"description\":\"Connect self-hosted AnythingLLM to Magic Hour MCP and retrieve a saved image project's status.\",\"url\":\"https://docs.magichour.ai/integration/anythingllm\",\"mainEntityOfPage\":{\"@id\":\"https://docs.magichour.ai/integration/anythingllm#webpage\"},\"image\":\"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg\",\"dateModified\":\"2026-10-24T19:18:26.994Z\",\"publisher\":{\"@id\":\"https://docs.magichour.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.magichour.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Magic Hour API Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Magic Hour API Docs","nav":{"global":{"anchors":[{"anchor":"API quickstart","icon":"forward-fast","href":"/get-started/quick-start"},{"anchor":"API pricing","icon":"credit-card","href":"/billing/overview"},{"anchor":"Community","icon":"discord","href":"https://discord.com/invite/JX5rgsZaJp"},{"anchor":"Status","icon":"wave-pulse","href":"https://status.magichour.ai"}]},"tabs":[{"tab":"Documentation","pages":[{"group":"Get Started","pages":[{"title":"Magic Hour API Documentation","sidebarTitle":"Introduction","href":"/introduction"},{"title":"Magic Hour API Quickstart","sidebarTitle":"Quick Start","href":"/get-started/quick-start"},{"title":"Authentication","href":"/get-started/authentication"},{"title":"Magic Hour MCP","href":"/integration/model-context-protocol"},{"title":"API Cookbook - Google Colab","href":"/get-started/cookbook"},{"title":"Product Video and Lip-Sync Recipes","href":"/get-started/starter-recipes"},{"title":"Bulk Face Swap API: Safe Batch Processing","sidebarTitle":"Bulk Face Swap","href":"/get-started/bulk-face-swap"}]},{"group":"Integration","pages":[{"title":"Integration Overview","sidebarTitle":"Overview","href":"/integration/overview"},{"title":"Compare AI Media APIs on Your Workload","sidebarTitle":"Evaluate API Providers","href":"/integration/evaluating-media-apis"},{"title":"Choose a Commercial AI Media Workflow","sidebarTitle":"Choose a Workflow","href":"/integration/commercial-media-workflows"},{"title":"Evaluate Lip Sync for Agency and Localization Work","sidebarTitle":"Agency Lip-Sync Pilot","href":"/integration/agency-lip-sync"},{"title":"smolagents","href":"/integration/smolagents"},{"title":"Creating Your First Integration","sidebarTitle":"Creating Your First Integration","href":"/integration/first-integration"},{"title":"PydanticAI","href":"/integration/pydantic-ai"},{"title":"Vercel AI SDK","href":"/integration/vercel-ai-sdk"},{"title":"OpenAI Agents SDK","href":"/integration/openai-agents-sdk"},{"title":"Google ADK","href":"/integration/google-adk"},{"title":"Genkit","href":"/integration/genkit"},{"title":"DSPy","href":"/integration/dspy"},{"title":"VoltAgent","href":"/integration/voltagent"},{"title":"Strands Agents","href":"/integration/strands-agents"},{"title":"LlamaIndex","href":"/integration/llamaindex"},{"title":"Spring AI","href":"/integration/spring-ai"},{"title":"Open WebUI","description":"Connect Open WebUI to Magic Hour's hosted MCP server with its native Streamable HTTP integration.","href":"/integration/open-webui"},{"title":"AnythingLLM","href":"/integration/anythingllm"},{"title":"Goose","description":"Connect Goose CLI to Magic Hour MCP and retrieve an existing image project's status.","href":"/integration/goose"},{"title":"Node-RED","href":"/integration/node-red"},{"title":"Windmill","href":"/integration/windmill"},{"title":"Prefect","href":"/integration/prefect"},{"title":"Dagster","href":"/integration/dagster"},{"title":"CrewAI","href":"/integration/crewai"},{"title":"Eino","href":"/integration/eino"},{"title":"Langflow","href":"/integration/langflow"},{"title":"Haystack","href":"/integration/haystack"},{"title":"Figma plugin","href":"/integration/figma"},{"title":"Framer plugin","href":"/integration/framer"},{"title":"Adobe Express add-on","href":"/integration/adobe-express"},{"title":"Canva app","href":"/integration/canva"},{"title":"Webflow extension","href":"/integration/webflow"},{"title":"Postman Collection","href":"/integration/postman"},{"title":"Adding API to Your App","href":"/integration/adding-api-to-your-app"},{"title":"Handling Inputs and Outputs","sidebarTitle":"Inputs \u0026 Outputs","href":"/integration/inputs-and-outputs"},{"title":"LangChain and LangGraph","href":"/integration/langchain"},{"title":"Mastra","href":"/integration/mastra"},{"title":"Development and Testing","href":"/integration/development-and-testing"},{"group":"Webhook","pages":[{"title":"Webhook Quickstart","sidebarTitle":"Quick Start","href":"/integration/webhook/overview"},{"title":"Create a Webhook","href":"/integration/webhook/create-webhook"},{"title":"Securing Your Webhook Handler","sidebarTitle":"Securing Handler","href":"/integration/webhook/secure-handler"},{"title":"Production Webhook Handler","sidebarTitle":"Production Setup","href":"/integration/webhook/create-handler"},{"title":"Webhook Event Types","sidebarTitle":"Event Types","href":"/integration/webhook/event-types"}]},{"title":"Postman Collection","href":"/integration/postman"},{"title":"API Docs MCP","href":"/integration/api-docs-mcp"}]},{"group":"Billing","pages":[{"title":"Magic Hour API Pricing","sidebarTitle":"Pricing Overview","href":"/billing/overview"},{"title":"Subscription Pricing","href":"/billing/subscription-pricing"},{"title":"Usage-Based Billing","href":"/billing/usage-based-pricing"},{"title":"Resolution Limits","href":"/billing/resolution-limits"}]},{"group":"Tools","pages":[{"group":"Video","pages":[{"title":"Video Tools","href":"/tools/video-tools"},{"title":"Face Swap Video API","sidebarTitle":"Face Swap Video","href":"/tools/video/face-swap-video"},{"title":"AI Talking Photo API","sidebarTitle":"Talking Photo","href":"/tools/video/talking-photo"},{"title":"Text to Video API","sidebarTitle":"Text to Video","href":"/tools/video/text-to-video"},{"title":"Lip Sync API","sidebarTitle":"Lip Sync","href":"/tools/video/lip-sync"},{"title":"Character Replace API","sidebarTitle":"Character Replace","href":"/tools/video/character-replace"},{"title":"Video to Video API","sidebarTitle":"Video to Video","href":"/tools/video/video-to-video"},{"title":"AI Video Editor API","sidebarTitle":"AI Video Editor","href":"/tools/video/video-editor"},{"title":"Audio to Video API","sidebarTitle":"Audio to Video","href":"/tools/video/audio-to-video"},{"title":"Auto Subtitle Generator API","sidebarTitle":"Auto Subtitle","href":"/tools/video/auto-subtitle-generator"},{"title":"Image to Video API","sidebarTitle":"Image to Video","href":"/tools/video/image-to-video"},{"title":"Animation API","sidebarTitle":"Animation","href":"/tools/video/animation"}]},{"group":"Images","pages":[{"title":"Image Tools","href":"/tools/image-tools"},{"title":"AI Image Editor API","sidebarTitle":"Image Editor","href":"/tools/image/image-editor"},{"title":"Face Swap Photo API","sidebarTitle":"Face Swap Photo","href":"/tools/image/face-swap-photo"},{"title":"AI Image Upscaler API","sidebarTitle":"Image Upscaler","href":"/tools/image/image-upscaler"},{"title":"AI Image Generator API","sidebarTitle":"Image Generator","href":"/tools/image/image-generator"},{"title":"Head Swap API","sidebarTitle":"Head Swap","href":"/tools/image/head-swap"},{"title":"AI Clothes Changer API","sidebarTitle":"Clothes Changer","href":"/tools/image/clothes-changer"},{"title":"Image Background Remover API","sidebarTitle":"Background Remover","href":"/tools/image/background-remover"},{"title":"Body Swap API","sidebarTitle":"Body Swap","href":"/tools/image/body-swap"},{"title":"AI Headshot Generator API","sidebarTitle":"Headshot Generator","href":"/tools/image/headshot-generator"},{"title":"AI Face Editor API","sidebarTitle":"Face Editor","href":"/tools/image/face-editor"},{"title":"Photo Colorizer API","sidebarTitle":"Photo Colorizer","href":"/tools/image/photo-colorizer"},{"title":"AI GIF Generator API","sidebarTitle":"GIF Generator API","href":"/tools/image/gif-generator"},{"title":"AI Meme Generator API","sidebarTitle":"Meme Generator","href":"/tools/image/meme-generator"},{"title":"AI QR Code Generator API","sidebarTitle":"QR Code Generator","href":"/tools/image/qr-code-generator"}]},{"group":"Audio","pages":[{"title":"Audio Tools","href":"/tools/audio-tools"},{"title":"AI Voice Cloner API","sidebarTitle":"Voice Cloner","href":"/tools/audio/voice-cloner"},{"title":"AI Voice Generator API","sidebarTitle":"Voice Generator","href":"/tools/audio/voice-generator"}]}]}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/overview"}]},{"tab":"Webhook Reference","pages":[{"title":"Webhook Reference","href":"/webhook-reference/overview"}]},{"tab":"Changelog","pages":[{"title":"Changelog","href":"/changelog"}]}]},"title":"AnythingLLM - Magic Hour API Docs","buildId":"dpl_849ArpqvBiCczQiT1Y1stNGpbqHT","deploymentId":"dpl_849ArpqvBiCczQiT1Y1stNGpbqHT","dynamics":[],"chunks":[]}