I have added few FAQs to my dev store using Shopify KnowledgaBase App. Now when I try the MCP tool search_shop_policies_and_faqs, its not able to get the answer. Although in the UI of KnowledgaBase App, its shown that my question matched with 3 faqs. What might be going wrong? Is it caching issue? I have waited for 12 hours. Should I wait more?
Just to confirm, youâve set up the FAQs as is described here: https://help.shopify.com/en/manual/promoting-marketing/knowledge-base/managing-faqs
Thanks for the response @Liam-Shopify. Thatâs right, I have followed those instructions. When I call the tool (From UI or using curl), I donât get a response:
curl -sX POST âhttps://store-url/api/mcpâ \
-H âcontent-type: application/jsonâ -H âCache-Control: no-cache, no-storeâ -H âPragma: no-cacheâ \
-d '{
"jsonrpc":"2.0",
"id":3,
"method":"tools/call",
"params":{
"name":"search_shop_policies_and_faqs",
"arguments":{
"query":"what is your return policy?",
"context":"customer is asking for return policy"
}
}
}â
{âjsonrpcâ:â2.0â,âidâ:3,âresultâ:{âcontentâ:[{âtypeâ:âtextâ,âtextâ:âUnable to find the answer in the knowledge base, try againâ}],âisErrorâ:true}}%
But in the UI, it shows that my question matched with 3 faqs:
@Liam-Shopify , any updates here? I am still facing this issue.
Still digging into this on my side - will post an update here asap
Hi again @Angela_Ranjeet
This does appear to be a bug on our side - weâre working to address this as soon as possible.
Thanks @Liam-Shopify ! We did a bit of testing at our side and looks like as soon as the number of faqs increase beyond a threshold (around 40 +/- 5), we get into this situation. Would wait for the resolution.
Thanks for sharing that extra info @Angela_Ranjeet - we were able to replicate this issue so thatâs helpful. Will post here when Iâve an update to share on this.
Hi again @Angela_Ranjeet
Just wanted to reconnect to let you know weâre working on a fix to improve this experience. Will update here once that has shipped.
@Liam-Shopify , it it fixed now?
We did ship some recent improvements to the tools that connect with FAQs - are you still seeing an issue on your side? If you are could you share your store (or I can DM you to gather info privately).
HI @Liam-Shopify , there is still some fragility in this tool. After adding a question and using curl to invoke the tool, I get 2 different answers (Success and Failure) for the same question in 2 consecutive calls:
curl -sX POST âhttps://<my_store>.myshopify.com/api/mcp?timestamp=$(date +%s)â \
-H âcontent-type: application/jsonâ -H âCache-Control: no-cache, no-storeâ -H âPragma: no-cacheâ \
-d '{"jsonrpc":"2.0",
"id":3,
"method":"tools/call",
"params":{
"name":"search_shop_policies_and_faqs",
"arguments":{
"query":"What is your return policy?"
}
}
}â
{âjsonrpcâ:â2.0â,âidâ:3,âresultâ:{âcontentâ:[{âtypeâ:âtextâ,âtextâ:â[{\âquestion\â:\âWhat is your return policy?\â,\âanswer\â:\âYou can return most new, unused items within 30 days of delivery for a full refund. Clearance, engraved jewellery, and worn snow gear are final sale. \â},{\âquestion\â:\âWhat is your return window?\â,\âanswer\â:\âYou can return most new, unused items within 30 days of delivery for a full refund. Clearance, engraved jewellery, and worn snow gear are final sale. \â}]â}],âisErrorâ:false}}%
curl -sX POST âhttps://<my_store>.myshopify.com/api/mcp?timestamp=$(date +%s)â \
-H âcontent-type: application/jsonâ -H âCache-Control: no-cache, no-storeâ -H âPragma: no-cacheâ \
-d '{ "jsonrpc":"2.0",
"id":3,
"method":"tools/call",
"params":{
"name":"search_shop_policies_and_faqs",
"arguments":{
"query":"What is your return policy?"
}
}
}â
{âjsonrpcâ:â2.0â,âidâ:3,âresultâ:{âcontentâ:[{âtypeâ:âtextâ,âtextâ:âUnable to find the answer in the knowledge base, try againâ}],âisErrorâ:true}}%
This is a dev store, where I am testing. Yes, we can connect and I can give you the required information.
