No, you cannot do that. If you see the basic of Http response packet. It has header section( with several sub heading ) and a response body. These are the protocol that guide the communication between client and server.
If you are directly adding a field ( i.e. abc ) in the response , it cannot create its own section apart from what is defined in the protocol ,right?
I think this would answer you question.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hey Rajan,
Thanks for your input
I know that we can add it by setting header, but my question is if we don't add it in header & only assign the value can it be got from frontend.
No, you cannot do that. If you see the basic of Http response packet. It has header section( with several sub heading ) and a response body. These are the protocol that guide the communication between client and server.
If you are directly adding a field ( i.e. abc ) in the response , it cannot create its own section apart from what is defined in the protocol ,right?
I think this would answer you question.