better code format in java jersey doc (#5031)

This commit is contained in:
William Cheng 2020-01-18 19:11:51 +08:00 committed by GitHub
parent 2722c602ac
commit d1948c4b41
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
19 changed files with 128 additions and 397 deletions

View File

@ -14,8 +14,12 @@ Method | HTTP request | Description
## {{operationId}}
{{^vendorExtensions.x-group-parameters}}> {{#returnType}}{{returnType}} {{/returnType}}{{operationId}}({{#allParams}}{{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}}){{/vendorExtensions.x-group-parameters}}
{{#vendorExtensions.x-group-parameters}}> {{#returnType}}{{returnType}} {{/returnType}}{{operationId}}({{#pathParams}}{{paramName}}{{#hasMore}}, {{/hasMore}}{{/pathParams}}){{#allParams}}{{^isPathParam}}.{{paramName}}({{paramName}}){{/isPathParam}}{{/allParams}}.execute();{{/vendorExtensions.x-group-parameters}}
{{^vendorExtensions.x-group-parameters}}
> {{#returnType}}{{returnType}} {{/returnType}}{{operationId}}({{#allParams}}{{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}})
{{/vendorExtensions.x-group-parameters}}
{{#vendorExtensions.x-group-parameters}}
> {{#returnType}}{{returnType}} {{/returnType}}{{operationId}}({{#pathParams}}{{paramName}}{{#hasMore}}, {{/hasMore}}{{/pathParams}}){{#allParams}}{{^isPathParam}}.{{paramName}}({{paramName}}){{/isPathParam}}{{/allParams}}.execute();
{{/vendorExtensions.x-group-parameters}}
{{summary}}{{#notes}}
@ -60,12 +64,18 @@ public class Example {
{{#allParams}}
{{{dataType}}} {{{paramName}}} = {{{example}}}; // {{{dataType}}} | {{{description}}}
{{/allParams}}
try { {{^vendorExtensions.x-group-parameters}}
{{#returnType}}{{{returnType}}} result = {{/returnType}}apiInstance.{{{operationId}}}({{#allParams}}{{{paramName}}}{{#hasMore}}, {{/hasMore}}{{/allParams}});{{/vendorExtensions.x-group-parameters}}
{{#vendorExtensions.x-group-parameters}}{{#returnType}}{{{returnType}}} result = {{/returnType}}api.{{operationId}}({{#pathParams}}{{paramName}}{{#hasMore}}, {{/hasMore}}{{/pathParams}}){{#allParams}}{{^isPathParam}}
try {
{{^vendorExtensions.x-group-parameters}}
{{#returnType}}{{{returnType}}} result = {{/returnType}}apiInstance.{{{operationId}}}({{#allParams}}{{{paramName}}}{{#hasMore}}, {{/hasMore}}{{/allParams}});
{{/vendorExtensions.x-group-parameters}}
{{#vendorExtensions.x-group-parameters}}
{{#returnType}}{{{returnType}}} result = {{/returnType}}api.{{operationId}}({{#pathParams}}{{paramName}}{{#hasMore}}, {{/hasMore}}{{/pathParams}}){{#allParams}}{{^isPathParam}}
.{{paramName}}({{paramName}}){{/isPathParam}}{{/allParams}}
.execute();{{/vendorExtensions.x-group-parameters}}
{{#returnType}}System.out.println(result);{{/returnType}}
.execute();
{{/vendorExtensions.x-group-parameters}}
{{#returnType}}
System.out.println(result);
{{/returnType}}
} catch (ApiException e) {
System.err.println("Exception when calling {{{classname}}}#{{{operationId}}}");
System.err.println("Status code: " + e.getCode());

View File

@ -12,7 +12,6 @@ Method | HTTP request | Description
> Client call123testSpecialTags(body)
To test special tags
To test special tags and operation ID starting with number
@ -36,7 +35,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.call123testSpecialTags(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AnotherFakeApi#call123testSpecialTags");

View File

@ -25,7 +25,6 @@ Method | HTTP request | Description
> createXmlItem(xmlItem)
creates an XmlItem
this route creates an XmlItem
@ -49,8 +48,6 @@ public class Example {
XmlItem xmlItem = new XmlItem(); // XmlItem | XmlItem Body
try {
apiInstance.createXmlItem(xmlItem);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#createXmlItem");
System.err.println("Status code: " + e.getCode());
@ -94,7 +91,6 @@ No authorization required
Test serialization of outer boolean types
### Example
@ -116,7 +112,6 @@ public class Example {
Boolean body = true; // Boolean | Input boolean as post body
try {
Boolean result = apiInstance.fakeOuterBooleanSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterBooleanSerialize");
@ -161,7 +156,6 @@ No authorization required
Test serialization of object with outer number type
### Example
@ -183,7 +177,6 @@ public class Example {
OuterComposite body = new OuterComposite(); // OuterComposite | Input composite as post body
try {
OuterComposite result = apiInstance.fakeOuterCompositeSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterCompositeSerialize");
@ -228,7 +221,6 @@ No authorization required
Test serialization of outer number types
### Example
@ -250,7 +242,6 @@ public class Example {
BigDecimal body = new BigDecimal(); // BigDecimal | Input number as post body
try {
BigDecimal result = apiInstance.fakeOuterNumberSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterNumberSerialize");
@ -295,7 +286,6 @@ No authorization required
Test serialization of outer string types
### Example
@ -317,7 +307,6 @@ public class Example {
String body = "body_example"; // String | Input string as post body
try {
String result = apiInstance.fakeOuterStringSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterStringSerialize");
@ -362,7 +351,6 @@ No authorization required
For this test, the body for this request much reference a schema named `File`.
### Example
@ -384,8 +372,6 @@ public class Example {
FileSchemaTestClass body = new FileSchemaTestClass(); // FileSchemaTestClass |
try {
apiInstance.testBodyWithFileSchema(body);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testBodyWithFileSchema");
System.err.println("Status code: " + e.getCode());
@ -429,7 +415,6 @@ No authorization required
### Example
```java
@ -450,8 +435,6 @@ public class Example {
User body = new User(); // User |
try {
apiInstance.testBodyWithQueryParams(query, body);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testBodyWithQueryParams");
System.err.println("Status code: " + e.getCode());
@ -494,7 +477,6 @@ No authorization required
> Client testClientModel(body)
To test \"client\" model
To test "client" model
@ -518,7 +500,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.testClientModel(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testClientModel");
@ -561,7 +542,6 @@ No authorization required
> testEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback)
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
Fake endpoint for testing various parameters
@ -607,8 +587,6 @@ public class Example {
String paramCallback = "paramCallback_example"; // String | None
try {
apiInstance.testEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testEndpointParameters");
System.err.println("Status code: " + e.getCode());
@ -664,7 +642,6 @@ null (empty response body)
> testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString)
To test enum parameters
To test enum parameters
@ -695,8 +672,6 @@ public class Example {
String enumFormString = "-efg"; // String | Form parameter enum test (string)
try {
apiInstance.testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testEnumParameters");
System.err.println("Status code: " + e.getCode());
@ -744,7 +719,6 @@ No authorization required
## testGroupParameters
> testGroupParameters().requiredStringGroup(requiredStringGroup).requiredBooleanGroup(requiredBooleanGroup).requiredInt64Group(requiredInt64Group).stringGroup(stringGroup).booleanGroup(booleanGroup).int64Group(int64Group).execute();
Fake endpoint to test group parameters (optional)
@ -782,7 +756,6 @@ public class Example {
.booleanGroup(booleanGroup)
.int64Group(int64Group)
.execute();
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testGroupParameters");
System.err.println("Status code: " + e.getCode());
@ -829,7 +802,6 @@ No authorization required
> testInlineAdditionalProperties(param)
test inline additionalProperties
### Example
@ -851,8 +823,6 @@ public class Example {
Map<String, String> param = new HashMap(); // Map<String, String> | request body
try {
apiInstance.testInlineAdditionalProperties(param);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testInlineAdditionalProperties");
System.err.println("Status code: " + e.getCode());
@ -894,7 +864,6 @@ No authorization required
> testJsonFormData(param, param2)
test json serialization of form data
### Example
@ -917,8 +886,6 @@ public class Example {
String param2 = "param2_example"; // String | field2
try {
apiInstance.testJsonFormData(param, param2);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testJsonFormData");
System.err.println("Status code: " + e.getCode());
@ -963,7 +930,6 @@ No authorization required
To test the collection format in query parameters
### Example
@ -989,8 +955,6 @@ public class Example {
List<String> context = Arrays.asList(); // List<String> |
try {
apiInstance.testQueryParameterCollectionFormat(pipe, ioutil, http, url, context);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testQueryParameterCollectionFormat");
System.err.println("Status code: " + e.getCode());

View File

@ -12,7 +12,6 @@ Method | HTTP request | Description
> Client testClassname(body)
To test class name in snake case
To test class name in snake case
@ -43,7 +42,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.testClassname(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeClassnameTags123Api#testClassname");

View File

@ -20,7 +20,6 @@ Method | HTTP request | Description
> addPet(body)
Add a new pet to the store
### Example
@ -47,8 +46,6 @@ public class Example {
Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
try {
apiInstance.addPet(body);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#addPet");
System.err.println("Status code: " + e.getCode());
@ -91,7 +88,6 @@ null (empty response body)
> deletePet(petId, apiKey)
Deletes a pet
### Example
@ -119,8 +115,6 @@ public class Example {
String apiKey = "apiKey_example"; // String |
try {
apiInstance.deletePet(petId, apiKey);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#deletePet");
System.err.println("Status code: " + e.getCode());
@ -164,7 +158,6 @@ null (empty response body)
> List&lt;Pet&gt; findPetsByStatus(status)
Finds Pets by status
Multiple status values can be provided with comma separated strings
@ -193,7 +186,6 @@ public class Example {
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
try {
List<Pet> result = apiInstance.findPetsByStatus(status);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#findPetsByStatus");
@ -237,7 +229,6 @@ Name | Type | Description | Notes
> List&lt;Pet&gt; findPetsByTags(tags)
Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
@ -266,7 +257,6 @@ public class Example {
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
try {
List<Pet> result = apiInstance.findPetsByTags(tags);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#findPetsByTags");
@ -310,7 +300,6 @@ Name | Type | Description | Notes
> Pet getPetById(petId)
Find pet by ID
Returns a single pet
@ -341,7 +330,6 @@ public class Example {
Long petId = 56L; // Long | ID of pet to return
try {
Pet result = apiInstance.getPetById(petId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#getPetById");
@ -386,7 +374,6 @@ Name | Type | Description | Notes
> updatePet(body)
Update an existing pet
### Example
@ -413,8 +400,6 @@ public class Example {
Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
try {
apiInstance.updatePet(body);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#updatePet");
System.err.println("Status code: " + e.getCode());
@ -459,7 +444,6 @@ null (empty response body)
> updatePetWithForm(petId, name, status)
Updates a pet in the store with form data
### Example
@ -488,8 +472,6 @@ public class Example {
String status = "status_example"; // String | Updated status of the pet
try {
apiInstance.updatePetWithForm(petId, name, status);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#updatePetWithForm");
System.err.println("Status code: " + e.getCode());
@ -533,7 +515,6 @@ null (empty response body)
> ModelApiResponse uploadFile(petId, additionalMetadata, file)
uploads an image
### Example
@ -562,7 +543,6 @@ public class Example {
File file = new File("/path/to/file"); // File | file to upload
try {
ModelApiResponse result = apiInstance.uploadFile(petId, additionalMetadata, file);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#uploadFile");
@ -607,7 +587,6 @@ Name | Type | Description | Notes
> ModelApiResponse uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata)
uploads an image (required)
### Example
@ -636,7 +615,6 @@ public class Example {
String additionalMetadata = "additionalMetadata_example"; // String | Additional data to pass to server
try {
ModelApiResponse result = apiInstance.uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#uploadFileWithRequiredFile");

View File

@ -15,7 +15,6 @@ Method | HTTP request | Description
> deleteOrder(orderId)
Delete purchase order by ID
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
@ -39,8 +38,6 @@ public class Example {
String orderId = "orderId_example"; // String | ID of the order that needs to be deleted
try {
apiInstance.deleteOrder(orderId);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#deleteOrder");
System.err.println("Status code: " + e.getCode());
@ -83,7 +80,6 @@ No authorization required
> Map&lt;String, Integer&gt; getInventory()
Returns pet inventories by status
Returns a map of status codes to quantities
@ -113,7 +109,6 @@ public class Example {
StoreApi apiInstance = new StoreApi(defaultClient);
try {
Map<String, Integer> result = apiInstance.getInventory();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#getInventory");
@ -153,7 +148,6 @@ This endpoint does not need any parameter.
> Order getOrderById(orderId)
Find purchase order by ID
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
@ -177,7 +171,6 @@ public class Example {
Long orderId = 56L; // Long | ID of pet that needs to be fetched
try {
Order result = apiInstance.getOrderById(orderId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#getOrderById");
@ -222,7 +215,6 @@ No authorization required
> Order placeOrder(body)
Place an order for a pet
### Example
@ -244,7 +236,6 @@ public class Example {
Order body = new Order(); // Order | order placed for purchasing the pet
try {
Order result = apiInstance.placeOrder(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#placeOrder");

View File

@ -19,7 +19,6 @@ Method | HTTP request | Description
> createUser(body)
Create user
This can only be done by the logged in user.
@ -43,8 +42,6 @@ public class Example {
User body = new User(); // User | Created user object
try {
apiInstance.createUser(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUser");
System.err.println("Status code: " + e.getCode());
@ -86,7 +83,6 @@ No authorization required
> createUsersWithArrayInput(body)
Creates list of users with given input array
### Example
@ -108,8 +104,6 @@ public class Example {
List<User> body = Arrays.asList(); // List<User> | List of user object
try {
apiInstance.createUsersWithArrayInput(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUsersWithArrayInput");
System.err.println("Status code: " + e.getCode());
@ -151,7 +145,6 @@ No authorization required
> createUsersWithListInput(body)
Creates list of users with given input array
### Example
@ -173,8 +166,6 @@ public class Example {
List<User> body = Arrays.asList(); // List<User> | List of user object
try {
apiInstance.createUsersWithListInput(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUsersWithListInput");
System.err.println("Status code: " + e.getCode());
@ -216,7 +207,6 @@ No authorization required
> deleteUser(username)
Delete user
This can only be done by the logged in user.
@ -240,8 +230,6 @@ public class Example {
String username = "username_example"; // String | The name that needs to be deleted
try {
apiInstance.deleteUser(username);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#deleteUser");
System.err.println("Status code: " + e.getCode());
@ -284,7 +272,6 @@ No authorization required
> User getUserByName(username)
Get user by user name
### Example
@ -306,7 +293,6 @@ public class Example {
String username = "username_example"; // String | The name that needs to be fetched. Use user1 for testing.
try {
User result = apiInstance.getUserByName(username);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#getUserByName");
@ -351,7 +337,6 @@ No authorization required
> String loginUser(username, password)
Logs user into the system
### Example
@ -374,7 +359,6 @@ public class Example {
String password = "password_example"; // String | The password for login in clear text
try {
String result = apiInstance.loginUser(username, password);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#loginUser");
@ -419,7 +403,6 @@ No authorization required
> logoutUser()
Logs out current logged in user session
### Example
@ -440,8 +423,6 @@ public class Example {
UserApi apiInstance = new UserApi(defaultClient);
try {
apiInstance.logoutUser();
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#logoutUser");
System.err.println("Status code: " + e.getCode());
@ -480,7 +461,6 @@ No authorization required
> updateUser(username, body)
Updated user
This can only be done by the logged in user.
@ -505,8 +485,6 @@ public class Example {
User body = new User(); // User | Updated user object
try {
apiInstance.updateUser(username, body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#updateUser");
System.err.println("Status code: " + e.getCode());

View File

@ -12,7 +12,6 @@ Method | HTTP request | Description
> Client call123testSpecialTags(body)
To test special tags
To test special tags and operation ID starting with number
@ -36,7 +35,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.call123testSpecialTags(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AnotherFakeApi#call123testSpecialTags");

View File

@ -25,7 +25,6 @@ Method | HTTP request | Description
> createXmlItem(xmlItem)
creates an XmlItem
this route creates an XmlItem
@ -49,8 +48,6 @@ public class Example {
XmlItem xmlItem = new XmlItem(); // XmlItem | XmlItem Body
try {
apiInstance.createXmlItem(xmlItem);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#createXmlItem");
System.err.println("Status code: " + e.getCode());
@ -94,7 +91,6 @@ No authorization required
Test serialization of outer boolean types
### Example
@ -116,7 +112,6 @@ public class Example {
Boolean body = true; // Boolean | Input boolean as post body
try {
Boolean result = apiInstance.fakeOuterBooleanSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterBooleanSerialize");
@ -161,7 +156,6 @@ No authorization required
Test serialization of object with outer number type
### Example
@ -183,7 +177,6 @@ public class Example {
OuterComposite body = new OuterComposite(); // OuterComposite | Input composite as post body
try {
OuterComposite result = apiInstance.fakeOuterCompositeSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterCompositeSerialize");
@ -228,7 +221,6 @@ No authorization required
Test serialization of outer number types
### Example
@ -250,7 +242,6 @@ public class Example {
BigDecimal body = new BigDecimal(); // BigDecimal | Input number as post body
try {
BigDecimal result = apiInstance.fakeOuterNumberSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterNumberSerialize");
@ -295,7 +286,6 @@ No authorization required
Test serialization of outer string types
### Example
@ -317,7 +307,6 @@ public class Example {
String body = "body_example"; // String | Input string as post body
try {
String result = apiInstance.fakeOuterStringSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterStringSerialize");
@ -362,7 +351,6 @@ No authorization required
For this test, the body for this request much reference a schema named `File`.
### Example
@ -384,8 +372,6 @@ public class Example {
FileSchemaTestClass body = new FileSchemaTestClass(); // FileSchemaTestClass |
try {
apiInstance.testBodyWithFileSchema(body);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testBodyWithFileSchema");
System.err.println("Status code: " + e.getCode());
@ -429,7 +415,6 @@ No authorization required
### Example
```java
@ -450,8 +435,6 @@ public class Example {
User body = new User(); // User |
try {
apiInstance.testBodyWithQueryParams(query, body);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testBodyWithQueryParams");
System.err.println("Status code: " + e.getCode());
@ -494,7 +477,6 @@ No authorization required
> Client testClientModel(body)
To test \&quot;client\&quot; model
To test "client" model
@ -518,7 +500,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.testClientModel(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testClientModel");
@ -561,7 +542,6 @@ No authorization required
> testEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback)
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
Fake endpoint for testing various parameters
@ -607,8 +587,6 @@ public class Example {
String paramCallback = "paramCallback_example"; // String | None
try {
apiInstance.testEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testEndpointParameters");
System.err.println("Status code: " + e.getCode());
@ -664,7 +642,6 @@ null (empty response body)
> testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString)
To test enum parameters
To test enum parameters
@ -695,8 +672,6 @@ public class Example {
String enumFormString = "-efg"; // String | Form parameter enum test (string)
try {
apiInstance.testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testEnumParameters");
System.err.println("Status code: " + e.getCode());
@ -744,7 +719,6 @@ No authorization required
## testGroupParameters
> testGroupParameters().requiredStringGroup(requiredStringGroup).requiredBooleanGroup(requiredBooleanGroup).requiredInt64Group(requiredInt64Group).stringGroup(stringGroup).booleanGroup(booleanGroup).int64Group(int64Group).execute();
Fake endpoint to test group parameters (optional)
@ -782,7 +756,6 @@ public class Example {
.booleanGroup(booleanGroup)
.int64Group(int64Group)
.execute();
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testGroupParameters");
System.err.println("Status code: " + e.getCode());
@ -829,7 +802,6 @@ No authorization required
> testInlineAdditionalProperties(param)
test inline additionalProperties
### Example
@ -851,8 +823,6 @@ public class Example {
Map<String, String> param = new HashMap(); // Map<String, String> | request body
try {
apiInstance.testInlineAdditionalProperties(param);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testInlineAdditionalProperties");
System.err.println("Status code: " + e.getCode());
@ -894,7 +864,6 @@ No authorization required
> testJsonFormData(param, param2)
test json serialization of form data
### Example
@ -917,8 +886,6 @@ public class Example {
String param2 = "param2_example"; // String | field2
try {
apiInstance.testJsonFormData(param, param2);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testJsonFormData");
System.err.println("Status code: " + e.getCode());
@ -963,7 +930,6 @@ No authorization required
To test the collection format in query parameters
### Example
@ -989,8 +955,6 @@ public class Example {
List<String> context = Arrays.asList(); // List<String> |
try {
apiInstance.testQueryParameterCollectionFormat(pipe, ioutil, http, url, context);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testQueryParameterCollectionFormat");
System.err.println("Status code: " + e.getCode());

View File

@ -12,7 +12,6 @@ Method | HTTP request | Description
> Client testClassname(body)
To test class name in snake case
To test class name in snake case
@ -43,7 +42,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.testClassname(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeClassnameTags123Api#testClassname");

View File

@ -20,7 +20,6 @@ Method | HTTP request | Description
> addPet(body)
Add a new pet to the store
### Example
@ -47,8 +46,6 @@ public class Example {
Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
try {
apiInstance.addPet(body);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#addPet");
System.err.println("Status code: " + e.getCode());
@ -91,7 +88,6 @@ null (empty response body)
> deletePet(petId, apiKey)
Deletes a pet
### Example
@ -119,8 +115,6 @@ public class Example {
String apiKey = "apiKey_example"; // String |
try {
apiInstance.deletePet(petId, apiKey);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#deletePet");
System.err.println("Status code: " + e.getCode());
@ -164,7 +158,6 @@ null (empty response body)
> List&lt;Pet&gt; findPetsByStatus(status)
Finds Pets by status
Multiple status values can be provided with comma separated strings
@ -193,7 +186,6 @@ public class Example {
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
try {
List<Pet> result = apiInstance.findPetsByStatus(status);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#findPetsByStatus");
@ -237,7 +229,6 @@ Name | Type | Description | Notes
> List&lt;Pet&gt; findPetsByTags(tags)
Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
@ -266,7 +257,6 @@ public class Example {
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
try {
List<Pet> result = apiInstance.findPetsByTags(tags);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#findPetsByTags");
@ -310,7 +300,6 @@ Name | Type | Description | Notes
> Pet getPetById(petId)
Find pet by ID
Returns a single pet
@ -341,7 +330,6 @@ public class Example {
Long petId = 56L; // Long | ID of pet to return
try {
Pet result = apiInstance.getPetById(petId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#getPetById");
@ -386,7 +374,6 @@ Name | Type | Description | Notes
> updatePet(body)
Update an existing pet
### Example
@ -413,8 +400,6 @@ public class Example {
Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
try {
apiInstance.updatePet(body);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#updatePet");
System.err.println("Status code: " + e.getCode());
@ -459,7 +444,6 @@ null (empty response body)
> updatePetWithForm(petId, name, status)
Updates a pet in the store with form data
### Example
@ -488,8 +472,6 @@ public class Example {
String status = "status_example"; // String | Updated status of the pet
try {
apiInstance.updatePetWithForm(petId, name, status);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#updatePetWithForm");
System.err.println("Status code: " + e.getCode());
@ -533,7 +515,6 @@ null (empty response body)
> ModelApiResponse uploadFile(petId, additionalMetadata, file)
uploads an image
### Example
@ -562,7 +543,6 @@ public class Example {
File file = new File("/path/to/file"); // File | file to upload
try {
ModelApiResponse result = apiInstance.uploadFile(petId, additionalMetadata, file);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#uploadFile");
@ -607,7 +587,6 @@ Name | Type | Description | Notes
> ModelApiResponse uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata)
uploads an image (required)
### Example
@ -636,7 +615,6 @@ public class Example {
String additionalMetadata = "additionalMetadata_example"; // String | Additional data to pass to server
try {
ModelApiResponse result = apiInstance.uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#uploadFileWithRequiredFile");

View File

@ -15,7 +15,6 @@ Method | HTTP request | Description
> deleteOrder(orderId)
Delete purchase order by ID
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
@ -39,8 +38,6 @@ public class Example {
String orderId = "orderId_example"; // String | ID of the order that needs to be deleted
try {
apiInstance.deleteOrder(orderId);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#deleteOrder");
System.err.println("Status code: " + e.getCode());
@ -83,7 +80,6 @@ No authorization required
> Map&lt;String, Integer&gt; getInventory()
Returns pet inventories by status
Returns a map of status codes to quantities
@ -113,7 +109,6 @@ public class Example {
StoreApi apiInstance = new StoreApi(defaultClient);
try {
Map<String, Integer> result = apiInstance.getInventory();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#getInventory");
@ -153,7 +148,6 @@ This endpoint does not need any parameter.
> Order getOrderById(orderId)
Find purchase order by ID
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
@ -177,7 +171,6 @@ public class Example {
Long orderId = 56L; // Long | ID of pet that needs to be fetched
try {
Order result = apiInstance.getOrderById(orderId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#getOrderById");
@ -222,7 +215,6 @@ No authorization required
> Order placeOrder(body)
Place an order for a pet
### Example
@ -244,7 +236,6 @@ public class Example {
Order body = new Order(); // Order | order placed for purchasing the pet
try {
Order result = apiInstance.placeOrder(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#placeOrder");

View File

@ -19,7 +19,6 @@ Method | HTTP request | Description
> createUser(body)
Create user
This can only be done by the logged in user.
@ -43,8 +42,6 @@ public class Example {
User body = new User(); // User | Created user object
try {
apiInstance.createUser(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUser");
System.err.println("Status code: " + e.getCode());
@ -86,7 +83,6 @@ No authorization required
> createUsersWithArrayInput(body)
Creates list of users with given input array
### Example
@ -108,8 +104,6 @@ public class Example {
List<User> body = Arrays.asList(); // List<User> | List of user object
try {
apiInstance.createUsersWithArrayInput(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUsersWithArrayInput");
System.err.println("Status code: " + e.getCode());
@ -151,7 +145,6 @@ No authorization required
> createUsersWithListInput(body)
Creates list of users with given input array
### Example
@ -173,8 +166,6 @@ public class Example {
List<User> body = Arrays.asList(); // List<User> | List of user object
try {
apiInstance.createUsersWithListInput(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUsersWithListInput");
System.err.println("Status code: " + e.getCode());
@ -216,7 +207,6 @@ No authorization required
> deleteUser(username)
Delete user
This can only be done by the logged in user.
@ -240,8 +230,6 @@ public class Example {
String username = "username_example"; // String | The name that needs to be deleted
try {
apiInstance.deleteUser(username);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#deleteUser");
System.err.println("Status code: " + e.getCode());
@ -284,7 +272,6 @@ No authorization required
> User getUserByName(username)
Get user by user name
### Example
@ -306,7 +293,6 @@ public class Example {
String username = "username_example"; // String | The name that needs to be fetched. Use user1 for testing.
try {
User result = apiInstance.getUserByName(username);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#getUserByName");
@ -351,7 +337,6 @@ No authorization required
> String loginUser(username, password)
Logs user into the system
### Example
@ -374,7 +359,6 @@ public class Example {
String password = "password_example"; // String | The password for login in clear text
try {
String result = apiInstance.loginUser(username, password);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#loginUser");
@ -419,7 +403,6 @@ No authorization required
> logoutUser()
Logs out current logged in user session
### Example
@ -440,8 +423,6 @@ public class Example {
UserApi apiInstance = new UserApi(defaultClient);
try {
apiInstance.logoutUser();
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#logoutUser");
System.err.println("Status code: " + e.getCode());
@ -480,7 +461,6 @@ No authorization required
> updateUser(username, body)
Updated user
This can only be done by the logged in user.
@ -505,8 +485,6 @@ public class Example {
User body = new User(); // User | Updated user object
try {
apiInstance.updateUser(username, body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#updateUser");
System.err.println("Status code: " + e.getCode());

View File

@ -12,7 +12,6 @@ Method | HTTP request | Description
> Client call123testSpecialTags(body)
To test special tags
To test special tags and operation ID starting with number
@ -36,7 +35,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.call123testSpecialTags(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AnotherFakeApi#call123testSpecialTags");

View File

@ -25,7 +25,6 @@ Method | HTTP request | Description
> createXmlItem(xmlItem)
creates an XmlItem
this route creates an XmlItem
@ -49,8 +48,6 @@ public class Example {
XmlItem xmlItem = new XmlItem(); // XmlItem | XmlItem Body
try {
apiInstance.createXmlItem(xmlItem);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#createXmlItem");
System.err.println("Status code: " + e.getCode());
@ -94,7 +91,6 @@ No authorization required
Test serialization of outer boolean types
### Example
@ -116,7 +112,6 @@ public class Example {
Boolean body = true; // Boolean | Input boolean as post body
try {
Boolean result = apiInstance.fakeOuterBooleanSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterBooleanSerialize");
@ -161,7 +156,6 @@ No authorization required
Test serialization of object with outer number type
### Example
@ -183,7 +177,6 @@ public class Example {
OuterComposite body = new OuterComposite(); // OuterComposite | Input composite as post body
try {
OuterComposite result = apiInstance.fakeOuterCompositeSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterCompositeSerialize");
@ -228,7 +221,6 @@ No authorization required
Test serialization of outer number types
### Example
@ -250,7 +242,6 @@ public class Example {
BigDecimal body = new BigDecimal(); // BigDecimal | Input number as post body
try {
BigDecimal result = apiInstance.fakeOuterNumberSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterNumberSerialize");
@ -295,7 +286,6 @@ No authorization required
Test serialization of outer string types
### Example
@ -317,7 +307,6 @@ public class Example {
String body = "body_example"; // String | Input string as post body
try {
String result = apiInstance.fakeOuterStringSerialize(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#fakeOuterStringSerialize");
@ -362,7 +351,6 @@ No authorization required
For this test, the body for this request much reference a schema named `File`.
### Example
@ -384,8 +372,6 @@ public class Example {
FileSchemaTestClass body = new FileSchemaTestClass(); // FileSchemaTestClass |
try {
apiInstance.testBodyWithFileSchema(body);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testBodyWithFileSchema");
System.err.println("Status code: " + e.getCode());
@ -429,7 +415,6 @@ No authorization required
### Example
```java
@ -450,8 +435,6 @@ public class Example {
User body = new User(); // User |
try {
apiInstance.testBodyWithQueryParams(query, body);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testBodyWithQueryParams");
System.err.println("Status code: " + e.getCode());
@ -494,7 +477,6 @@ No authorization required
> Client testClientModel(body)
To test \&quot;client\&quot; model
To test "client" model
@ -518,7 +500,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.testClientModel(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testClientModel");
@ -561,7 +542,6 @@ No authorization required
> testEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback)
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
Fake endpoint for testing various parameters
@ -607,8 +587,6 @@ public class Example {
String paramCallback = "paramCallback_example"; // String | None
try {
apiInstance.testEndpointParameters(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testEndpointParameters");
System.err.println("Status code: " + e.getCode());
@ -664,7 +642,6 @@ null (empty response body)
> testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString)
To test enum parameters
To test enum parameters
@ -695,8 +672,6 @@ public class Example {
String enumFormString = "-efg"; // String | Form parameter enum test (string)
try {
apiInstance.testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testEnumParameters");
System.err.println("Status code: " + e.getCode());
@ -744,7 +719,6 @@ No authorization required
## testGroupParameters
> testGroupParameters().requiredStringGroup(requiredStringGroup).requiredBooleanGroup(requiredBooleanGroup).requiredInt64Group(requiredInt64Group).stringGroup(stringGroup).booleanGroup(booleanGroup).int64Group(int64Group).execute();
Fake endpoint to test group parameters (optional)
@ -782,7 +756,6 @@ public class Example {
.booleanGroup(booleanGroup)
.int64Group(int64Group)
.execute();
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testGroupParameters");
System.err.println("Status code: " + e.getCode());
@ -829,7 +802,6 @@ No authorization required
> testInlineAdditionalProperties(param)
test inline additionalProperties
### Example
@ -851,8 +823,6 @@ public class Example {
Map<String, String> param = new HashMap(); // Map<String, String> | request body
try {
apiInstance.testInlineAdditionalProperties(param);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testInlineAdditionalProperties");
System.err.println("Status code: " + e.getCode());
@ -894,7 +864,6 @@ No authorization required
> testJsonFormData(param, param2)
test json serialization of form data
### Example
@ -917,8 +886,6 @@ public class Example {
String param2 = "param2_example"; // String | field2
try {
apiInstance.testJsonFormData(param, param2);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testJsonFormData");
System.err.println("Status code: " + e.getCode());
@ -963,7 +930,6 @@ No authorization required
To test the collection format in query parameters
### Example
@ -989,8 +955,6 @@ public class Example {
List<String> context = Arrays.asList(); // List<String> |
try {
apiInstance.testQueryParameterCollectionFormat(pipe, ioutil, http, url, context);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testQueryParameterCollectionFormat");
System.err.println("Status code: " + e.getCode());

View File

@ -12,7 +12,6 @@ Method | HTTP request | Description
> Client testClassname(body)
To test class name in snake case
To test class name in snake case
@ -43,7 +42,6 @@ public class Example {
Client body = new Client(); // Client | client model
try {
Client result = apiInstance.testClassname(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FakeClassnameTags123Api#testClassname");

View File

@ -20,7 +20,6 @@ Method | HTTP request | Description
> addPet(body)
Add a new pet to the store
### Example
@ -47,8 +46,6 @@ public class Example {
Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
try {
apiInstance.addPet(body);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#addPet");
System.err.println("Status code: " + e.getCode());
@ -91,7 +88,6 @@ null (empty response body)
> deletePet(petId, apiKey)
Deletes a pet
### Example
@ -119,8 +115,6 @@ public class Example {
String apiKey = "apiKey_example"; // String |
try {
apiInstance.deletePet(petId, apiKey);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#deletePet");
System.err.println("Status code: " + e.getCode());
@ -164,7 +158,6 @@ null (empty response body)
> List&lt;Pet&gt; findPetsByStatus(status)
Finds Pets by status
Multiple status values can be provided with comma separated strings
@ -193,7 +186,6 @@ public class Example {
List<String> status = Arrays.asList("available"); // List<String> | Status values that need to be considered for filter
try {
List<Pet> result = apiInstance.findPetsByStatus(status);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#findPetsByStatus");
@ -237,7 +229,6 @@ Name | Type | Description | Notes
> List&lt;Pet&gt; findPetsByTags(tags)
Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
@ -266,7 +257,6 @@ public class Example {
List<String> tags = Arrays.asList(); // List<String> | Tags to filter by
try {
List<Pet> result = apiInstance.findPetsByTags(tags);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#findPetsByTags");
@ -310,7 +300,6 @@ Name | Type | Description | Notes
> Pet getPetById(petId)
Find pet by ID
Returns a single pet
@ -341,7 +330,6 @@ public class Example {
Long petId = 56L; // Long | ID of pet to return
try {
Pet result = apiInstance.getPetById(petId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#getPetById");
@ -386,7 +374,6 @@ Name | Type | Description | Notes
> updatePet(body)
Update an existing pet
### Example
@ -413,8 +400,6 @@ public class Example {
Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
try {
apiInstance.updatePet(body);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#updatePet");
System.err.println("Status code: " + e.getCode());
@ -459,7 +444,6 @@ null (empty response body)
> updatePetWithForm(petId, name, status)
Updates a pet in the store with form data
### Example
@ -488,8 +472,6 @@ public class Example {
String status = "status_example"; // String | Updated status of the pet
try {
apiInstance.updatePetWithForm(petId, name, status);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#updatePetWithForm");
System.err.println("Status code: " + e.getCode());
@ -533,7 +515,6 @@ null (empty response body)
> ModelApiResponse uploadFile(petId, additionalMetadata, file)
uploads an image
### Example
@ -562,7 +543,6 @@ public class Example {
File file = new File("/path/to/file"); // File | file to upload
try {
ModelApiResponse result = apiInstance.uploadFile(petId, additionalMetadata, file);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#uploadFile");
@ -607,7 +587,6 @@ Name | Type | Description | Notes
> ModelApiResponse uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata)
uploads an image (required)
### Example
@ -636,7 +615,6 @@ public class Example {
String additionalMetadata = "additionalMetadata_example"; // String | Additional data to pass to server
try {
ModelApiResponse result = apiInstance.uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PetApi#uploadFileWithRequiredFile");

View File

@ -15,7 +15,6 @@ Method | HTTP request | Description
> deleteOrder(orderId)
Delete purchase order by ID
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
@ -39,8 +38,6 @@ public class Example {
String orderId = "orderId_example"; // String | ID of the order that needs to be deleted
try {
apiInstance.deleteOrder(orderId);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#deleteOrder");
System.err.println("Status code: " + e.getCode());
@ -83,7 +80,6 @@ No authorization required
> Map&lt;String, Integer&gt; getInventory()
Returns pet inventories by status
Returns a map of status codes to quantities
@ -113,7 +109,6 @@ public class Example {
StoreApi apiInstance = new StoreApi(defaultClient);
try {
Map<String, Integer> result = apiInstance.getInventory();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#getInventory");
@ -153,7 +148,6 @@ This endpoint does not need any parameter.
> Order getOrderById(orderId)
Find purchase order by ID
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
@ -177,7 +171,6 @@ public class Example {
Long orderId = 56L; // Long | ID of pet that needs to be fetched
try {
Order result = apiInstance.getOrderById(orderId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#getOrderById");
@ -222,7 +215,6 @@ No authorization required
> Order placeOrder(body)
Place an order for a pet
### Example
@ -244,7 +236,6 @@ public class Example {
Order body = new Order(); // Order | order placed for purchasing the pet
try {
Order result = apiInstance.placeOrder(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling StoreApi#placeOrder");

View File

@ -19,7 +19,6 @@ Method | HTTP request | Description
> createUser(body)
Create user
This can only be done by the logged in user.
@ -43,8 +42,6 @@ public class Example {
User body = new User(); // User | Created user object
try {
apiInstance.createUser(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUser");
System.err.println("Status code: " + e.getCode());
@ -86,7 +83,6 @@ No authorization required
> createUsersWithArrayInput(body)
Creates list of users with given input array
### Example
@ -108,8 +104,6 @@ public class Example {
List<User> body = Arrays.asList(); // List<User> | List of user object
try {
apiInstance.createUsersWithArrayInput(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUsersWithArrayInput");
System.err.println("Status code: " + e.getCode());
@ -151,7 +145,6 @@ No authorization required
> createUsersWithListInput(body)
Creates list of users with given input array
### Example
@ -173,8 +166,6 @@ public class Example {
List<User> body = Arrays.asList(); // List<User> | List of user object
try {
apiInstance.createUsersWithListInput(body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#createUsersWithListInput");
System.err.println("Status code: " + e.getCode());
@ -216,7 +207,6 @@ No authorization required
> deleteUser(username)
Delete user
This can only be done by the logged in user.
@ -240,8 +230,6 @@ public class Example {
String username = "username_example"; // String | The name that needs to be deleted
try {
apiInstance.deleteUser(username);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#deleteUser");
System.err.println("Status code: " + e.getCode());
@ -284,7 +272,6 @@ No authorization required
> User getUserByName(username)
Get user by user name
### Example
@ -306,7 +293,6 @@ public class Example {
String username = "username_example"; // String | The name that needs to be fetched. Use user1 for testing.
try {
User result = apiInstance.getUserByName(username);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#getUserByName");
@ -351,7 +337,6 @@ No authorization required
> String loginUser(username, password)
Logs user into the system
### Example
@ -374,7 +359,6 @@ public class Example {
String password = "password_example"; // String | The password for login in clear text
try {
String result = apiInstance.loginUser(username, password);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#loginUser");
@ -419,7 +403,6 @@ No authorization required
> logoutUser()
Logs out current logged in user session
### Example
@ -440,8 +423,6 @@ public class Example {
UserApi apiInstance = new UserApi(defaultClient);
try {
apiInstance.logoutUser();
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#logoutUser");
System.err.println("Status code: " + e.getCode());
@ -480,7 +461,6 @@ No authorization required
> updateUser(username, body)
Updated user
This can only be done by the logged in user.
@ -505,8 +485,6 @@ public class Example {
User body = new User(); // User | Updated user object
try {
apiInstance.updateUser(username, body);
} catch (ApiException e) {
System.err.println("Exception when calling UserApi#updateUser");
System.err.println("Status code: " + e.getCode());