用于Azure移动/Web应用程序的POST(从Arduino工作) [英] POST for Azure Mobile/Web App (working from Arduino)

查看:104
本文介绍了用于Azure移动/Web应用程序的POST(从Arduino工作)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想通过发送POST查找有关如何使用Mobile/Web App的示例.
以前在移动服务中可以这样发送POST:

I want to find samples of how to work with Mobile/Web App by sending POST.
Previously in Mobile Services it was possible to send POST like this:

POST /tables/table_name HTTP/1.1
Host: http://arduinounoserver.azure-mobile.net/
X-ZUMO-APPLICATION: YaRWxxxxzKGRxxxxLPiNxxxxXYOvxxxx
{"value": 234}

但是现在身份验证已完全更改.
现在该怎么办?有可能在某个地方找到POST样本吗?

But now authentication was absolutely changed.
How to do it now and is it possible to find somewhere POST samples?

仅找到表服务REST API ,但它仍然对我不清楚

Have found only Table Service REST API but it's still not clear for me

推荐答案

您仍然可以使用下一个URL表示法访问表:

you can still use next URL notation to access tables:

https://yoursite/tables/tablename

但是,您会得到一个错误:

but, you can get an error:

{"error":"An invalid API version was specified in the request, this request needs to specify a ZUMO-API-VERSION of 2.0.0."}

例如,对于Web App Easy Table,您应该使用下一个ZUMO标头

so with Web App Easy Table you should use next ZUMO-header, for example

POST https://vyutest.azurewebsites.net/Tables/Test HTTP/1.1

Accept: application/json 
Content-Type: application/json 
Content-Length: 49 
ZUMO-API-VERSION: 2.0.0 
Host: vyutest.azurewebsites.net

{"text":"Complete the tutorial","complete":false}

有效.

这篇关于用于Azure移动/Web应用程序的POST(从Arduino工作)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆