create image with dynamic data in node js - node.js

I am working on a chatbot project. The chatbot makes a request to my API with data from the user and it expects an image back with the data it sent so it can serve it to the user. what is the best way to create
this images dynamically with node js ?

Related

How to post JSON data from NodeJS to Django?

The architecture of our app uses NodeJS and Django together.
I need to post a JSON data from NodeJS to Django without receiving any request before that from Django. Because, there is a function in NodeJS that generates and returns JSON data such that whenever this data returned, NodeJS must post it to Django.
I don't know any thing about that and have not any idea for that.
What should I do? What APIs/modules do I need to use and how should I work with NodeJS and Django to fulfill it?
api can be created in django with necessary permissions & authentication, then can continue with function call in nodejs (any medium to trigger code to submit data in django api).

sending data from nodejs to static javascript through fetch api without using template library

I want to send the data from my nodejs application to my local static javascript,so that I can do various operation using local javascript logic. Can I do it. I can use it through template engine but i want to do it by sending the data from nodejs server to the local javascript so that the page will load with the information fetched by the node js.

Can users see the api source code composed of nodejs that is on the website composed of react and nodejs?

I heard that users can see react source code that is on the website composed of react and nodejs.
Can users see the api source code composed of nodejs that is on the website composed of react and nodejs?

How to return JSON response when an Item changes in MongoDB using NodeJs

I have a NodeJS server and mongoDB where I have get and post API for the data. And I was wondering if I want to change something for example in my Users collection and have the changes directly send to my frontend react project. I was reading about socket-io, and can't find how to send the data as I am sending it in the API.
Is there any resources or examples on this ?

How would my node.js application access an uploaded image on react?

I am working on a react mobile application where the user can take an image with their camera and then my node application can do image processing on that uploaded picture, finally information is sent back to the react side from the node application. The problem I'm currently receiving is that I'm not really sure how to get my node application to access the taken photo.
Would the only way to do this would be to save the photo into some database and then have my node application access it there? Would it be possible to do this without saving the photo to a database?
Thanks for the help.
you could storage the taken photo using a database,but it depends of your requirements if you don't need to have an historical from your image processors (like receive a image X from user USERNAME and it was processed as image Y ).
If you just need to make the process the photo you can send it as base64 string encoded, so you can make a POST request and send that string in a JSON field from your React app to Node.js and when you receive that string you need to decode the message to generate an image, next you cold make your image processing and finally send that image as was received before

Resources