Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use the api? #30

Open
Suyashjain05 opened this issue Apr 20, 2021 · 2 comments
Open

How to use the api? #30

Suyashjain05 opened this issue Apr 20, 2021 · 2 comments

Comments

@Suyashjain05
Copy link

Hi there, i was wondering on how to use the api?
What exact data should pe posted and in what form to the api?
I tried using the given example in Readme.md But wasn't clear enough.
Please help.
Thank you

@Inside4ndroid
Copy link

Inside4ndroid commented Jul 16, 2021

I have the same issue here...

a little more explanation on accessing the api would be good...

for example if i put the files in a folder at mydomain.com/api then how do i access that api cause making a post with correct data in android is not working.... :(

thanks

########### EDIT ###########

So after changing the port in app.js and allowing port in ufw i now get this error when making the post request>>>

TypeError: First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.
at Function.Buffer.from (buffer.js:183:11)
at exports.index (/var/www/html/node-urlresolver-api/servers/bitporno.js:14:29)
at Layer.handle [as handle_request] (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/layer.js:95:5)
at next (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/route.js:137:13)
at Route.dispatch (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/route.js:112:3)
at Layer.handle [as handle_request] (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/layer.js:95:5)
at /var/www/html/node-urlresolver-api/node_modules/express/lib/router/index.js:281:22
at Function.process_params (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/index.js:335:12)
at next (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/index.js:275:10)
at Function.handle (/var/www/html/node-urlresolver-api/node_modules/express/lib/router/index.js:174:3)

@lscofield
Copy link
Owner

See full app created for Android with this API here: https://github.com/lscofield/url-resolver-android-simple

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants