New in 2.4: Test runs you can trust See what's new →

Corpos de requisição

Análise do corpo da requisição por tipo de conteúdo. Os endpoints tipados só aceitam o próprio Content-Type (senão, 415) e informam o que analisaram; /any detecta o formato do conteúdo; /large mede uploads de até 10MB.

Requisição de exemplo

Detects a body's real type from its content and compares it with the declared Content-Type. Referência completa e botão Send (em inglês).

cURL
curl -X POST "https://api.testingapis.com/api/bodies/any" \
  -H "Content-Type: application/json" \
  -d '{"hello": "world"}'
Executar no Studio
Resposta · 200 OK
{
  "method": "POST",
  "declaredContentType": "application/json",
  "detectedType": "application/json",
  "matchesDeclared": true,
  "length": 18,
  "sha256": "5f8f04f6a3a892aaabbddb6cf273894493773960d4a325b105fee46eef4304f1"
}