我在尝试将评论发布到Basecamp Classic上的现有帖子时收到500内部服务器错误。任何有助于解决如何解决此问题的帮助表示赞赏。
一般情况下,是否可以使用新API与Basecamp Classic进行交互?我还没有看到任何关于此的文档,如果有人可以指出它会有所帮助。
$.ajax({
url: _accountHref + '/projects/' + $projectId + '/posts/' + $postId + '/comments.json',
headers: {
'Authorization': 'Bearer ' + _token,
'Content-Type' : 'application/json; charset=utf-8'
},
data: { 'content' : "I'm alive!" },
type: 'POST',
//type: 'PUT',
success: function(data, status) {
}
});
以下是请求标头,如果这有用(标记和会话ID被删除)
POST /projects/12737365/posts/91927305/comments.json HTTP/1.1
Host: anideninteractive.basecamphq.com
Connection: keep-alive
Content-Length: 18
Authorization: Bearer <auth-token>
Origin: https://anideninteractive.basecamphq.com
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.89 Safari/537.36
Content-Type: application/json; charset=UTF-8
Accept: */*
X-Requested-With: XMLHttpRequest
DNT: 1
Referer: https://anideninteractive.basecamphq.com/projects/12737365-graphic-plan-aniden-test/log
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.8,ca;q=0.6
Cookie: twisted_token=<twisted-token>;
session_token=<session-token>; return_to=https%3A%2F%2Fanideninteractive.basecamphq.com%2Fprojects%2F12737365-graphic-plan-aniden-test%2Flog; flashVersion=Shockwave%20Flash%2017.0%20r0; _basecamp_session_v2=<basecamp-session-v2>
答案 0 :(得分:0)
我在Basecamp发送了这个问题。他们说你不能通过新的API访问Basecamp Classic。