简体   繁体   English

使用后端文件nodejs

[英]using backend files nodejs

Sorry, It might be very novice problem but I am new to node and web apps and just have been stuck on this for couples of days. 抱歉,这可能是一个非常新手的问题,但是我对节点和Web应用程序还是陌生的,只是在此问题上停留了几天。

I have been working with a API called "Face++" that requires user to upload images to detect faces. 我一直在使用一个名为“ Face ++”的API,该API需要用户上传图像来检测面部。 So basically users needed to upload images to my webapps backend and my backend would do an API request with that image. 因此,基本上用户需要将图像上传到我的webapps后端,而我的后端将对该图像进行API请求。 I somehow managed to upload the files at my node's backend using tutorial provided below but now I am struggling how to use those image files. 我设法使用下面提供的教程在节点的后端上传了文件,但是现在我在努力使用这些图像文件。 I really don't know how to have access to those files. 我真的不知道如何访问这些文件。 I thought writing just the filepath/filename would help but it did not. 我以为只写文件路径/文件名会有所帮助,但没有帮助。 I am really new at webapps. 我真的是webapp的新手。

I used tutorial from here: https://coligo.io/building-ajax-file-uploader-with-node/ to upload my files at back-end. 我从这里使用了教程: https : //coligo.io/building-ajax-file-uploader-with-node/在后端上传我的文件。

thanks 谢谢

You can also use the Face++ REST API node client https://www.npmjs.com/package/faceppsdk 您还可以使用Face ++ REST API节点客户端https://www.npmjs.com/package/faceppsdk

As per in documentation it requires a live URL on web. 根据文档中的说明,它需要Web上的实时URL。 Then you have to upload your files into remote location (You may upload files to a Amazon S3 Bucket ) 然后,您必须将文件上传到远程位置(您可以将文件上传到Amazon S3存储桶

And also you check the sample codes from Documentation where you can upload directly to Face++ 此外,您还可以查看文档中的示例代码,将其直接上传到Face ++

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM