Create a list of users
Create a list of users with the given input list.
POST https://petstore3.swagger.io/api/v3/user/createWithList
Examples
- API Key
- OAuth 2.0
cURL
POST "https://petstore3.swagger.io/api/v3/user/createWithList" \
-H "accept: application/json" \
-H "Content-Type: application/json" \
-H "api_key: <YOUR_API_KEY>" \
-d \
[
{
"id": 0,
"username": "string",
"firstName": "string",
"lastName": "string",
"email": "string",
"password": "string",
"phone": "string",
"userStatus": 0
}
]
cURL
POST "https://petstore3.swagger.io/api/v3/user/createWithList" \
-H "accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <YOUR_OAUTH_TOKEN>" \
-d \
[
{
"id": 0,
"username": "string",
"firstName": "string",
"lastName": "string",
"email": "string",
"password": "string",
"phone": "string",
"userStatus": 0
}
]
Responses
| Code | Description |
|---|---|
| 200 | Successful operation |
| default | Successful operation |
Response example
200: Successful operation
Response
{
"id": 0,
"username": "string",
"firstName": "string",
"lastName": "string",
"email": "string",
"password": "string",
"phone": "string",
"userStatus": 0
}
Parameters
Request body
| Name | Type | Description |
|---|---|---|
body | Array of User objects | Required. The list of User objects to create. |