2
头图

The common request bodies in Eoapi are as follows:

  1. Json
 {
  "string": "test",
  "array": [{ "dom1": {}, "dom2": false, "dom3": [] }],
  "object": { "dom1": "", "dom2": 0 },
  "null": null,
  "float": 11.11,
  "int": 1,
  "boolean": false
}
  1. Form-data
    There are two formats Form-data (form-data), multipart/form-data and application/x-www-form-urlencoded;

In modern browsers, the use of forms to submit requests is relatively rare, so application/x-www-form-urlencoded is used more, but there is a special case. If your request needs to upload a file, the request body format Undoubtedly multipart/form-data.

1. Form-data[content-type="multipart/form-data;"]
formdata.32aa69c7.png

 ------WebKitFormBoundaryNWnXbkVpqUPjFVZq
Content-Disposition: form-data; name="multiple"

2
------WebKitFormBoundaryNWnXbkVpqUPjFVZq
Content-Disposition: form-data; name="formDataStructure"

formDataStructure
------WebKitFormBoundaryNWnXbkVpqUPjFVZq--

2. Form-data[content-type="application/x-www-form-urlencoded"]

a=1&b=2

3.XML

 <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<root>
  <type version="1.0">projectMember</type>
  <statusCode version="webGlobalVal">000000</statusCode>
  <memberList>
    <memberNickName/>
    <inviteCall>2177295417@qq.com</inviteCall>
    <userNickName>[\u968f\u673a]\u65e0\u5d16\u5b50</userNickName>
    <userImage/>
  </memberList>
</root>

4. Raw
random text string

Eoapi is a simple and easy-to-use open source API tool. The basic functions only include API documentation and testing.
Meet the core needs of our developers.

Documentation address: https://docs.eoapi.io/?utm_source=SF080201
Project address: https://github.com/eolinker/eoapi
Demo address: https://demo.eoapi.io/zh/home/api/test


气势凌人的柿子
310 声望3 粉丝