Sitecore项目Web API-未找到模板项目错误

Sitecore项目Web API-未找到模板项目错误,sitecore,sitecore7,Sitecore,Sitecore7,我试图通过ItemWebAPI创建一个项目,但我无法找出我的调用有什么问题 模板ID与父ID不存在 职位: 答复: HTTP/1.1 200 OK Cache-Control: no-cache, no-store Pragma: no-cache Content-Type: application/json; charset=utf-8 Expires: -1 Server: Microsoft-IIS/8.0 X-Powered-By: ASP.NET Date: Wed, 19 Mar 2

我试图通过ItemWebAPI创建一个项目,但我无法找出我的调用有什么问题

模板ID与父ID不存在

职位:

答复:

HTTP/1.1 200 OK
Cache-Control: no-cache, no-store
Pragma: no-cache
Content-Type: application/json; charset=utf-8
Expires: -1
Server: Microsoft-IIS/8.0
X-Powered-By: ASP.NET
Date: Wed, 19 Mar 2014 00:25:34 GMT
Content-Length: 65

{"statusCode":500,"error":{"message":"Template item not found."}}
有什么想法吗


非常感谢

请求URL中有一些额外的编码字符,您的
模板
sc_itemid
参数用%23(#)个字符包装

职位 /-/item/v1/?name=Foo&template=%23%7b57ABCEB7-25E5-4F73-88D8-9E66E79EA87C%7d%23&sc_数据库=主数据和有效负载=内容和字段=数据测试和sc_项目ID=%23%7b110D559F-DEA5-42EA-9C1C-8A5DF7E70EF9%7d%23 HTTP/1.1


检查您的代码以确保它们是如何到达的,但是删除它们应该可以解决问题。

您是否尝试从
模板
sc\u项目
参数中删除
%23
(#)?如果做不到这一点,试着使用相对模板路径,看看它是否完美,我没有注意到这个额外的符号。贴出答案,这样我就可以标记为回答了这个问题。Tks
HTTP/1.1 200 OK
Cache-Control: no-cache, no-store
Pragma: no-cache
Content-Type: application/json; charset=utf-8
Expires: -1
Server: Microsoft-IIS/8.0
X-Powered-By: ASP.NET
Date: Wed, 19 Mar 2014 00:25:34 GMT
Content-Length: 65

{"statusCode":500,"error":{"message":"Template item not found."}}