gpt4 book ai didi

android - IBM 蓝调 : make POST request from Android and how to handle it in NodeJS

转载 作者:行者123 更新时间:2023-11-29 20:03:07 25 4
gpt4 key购买 nike

我是 bluemix mobilefirst 平台的新手,一直卡在需要使用来自 android 客户端的一些参数发出发布请求的地步。我已经搜索了文档,但找不到所需的 .

最佳答案

显然,发送 POST 请求的方法不止一种,我将概述其中一种。

为了查看端到端场景,您可以使用 HelloTodo Android 示例,它使用基于 node.js 的 Bluemix 托管后端 - https://github.com/ibm-bluemix-mobile-services/bms-samples-android-hellotodo .

此 Android 示例中的 POST 请求是使用 Request 类发出的,它是 Bluemix Mobile Services SDK 的一部分 - https://github.com/ibm-bluemix-mobile-services/bms-samples-android-hellotodo/blob/master/helloTodo/app/src/main/java/com/ibm/hellotodo/MainActivity.java#L255

服务器端实现取决于您选择使用的框架。最流行的 nodejs 框架可能是 expressjs - http://expressjs.com/en/4x/api.html#app.post.method

关于android - IBM 蓝调 : make POST request from Android and how to handle it in NodeJS,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36012484/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com