如何使用POST參數在外部URL中調用rails 3中的某些webservices?我通常使用類似這樣的命令行POST在rails 3中
curl -X POST -u "v10REVkw:XuCqIhyCw" \
-H "Content-Type: application/json" \
--data '{"apids": ["c80-d363237c-e513b"], "android": {"alert": "Android Test!"}}' \
https://url/to/push
這是一個很好的資源,感謝分享:) +1;) – apneadiving 2011-04-24 15:51:34
你如何傳遞用戶名? – ed1t 2011-04-25 01:16:04
如果您正在進行http basic auth,您應該可以在url:https:// username:[email protected]上使用它。 Github正在幫助我的假鏈接變成真正的鏈接,但你明白了。 – mikewilliamson 2011-04-25 03:00:12