Receive a json as a Java Servlet parameter

0

I'm developing an API using java servlet , I'd like to know how to get a JSON in the request body as a parameter and write to a database?

Example:

{
    "nome": "José da Silva",
    "email": "[email protected]",
    "telefone": "(21) 99999-99099",
    "ativo": true,
    "empresa": {
      "nome": "Empresa Teste 1",
      "endereco": "Avenida das Américas",
      "site": "www.exemplo.com.br",
      "email": "[email protected]"
    }
  }
    
asked by anonymous 24.10.2018 / 22:26

0 answers