mirror of
https://github.com/Redocly/redoc.git
synced 2025-07-03 18:53:02 +03:00
Add one more code sample to demo
This commit is contained in:
parent
620d206ac8
commit
8eaf388624
|
@ -184,26 +184,6 @@
|
||||||
} catch (UnprocessableEntityException $e) {
|
} catch (UnprocessableEntityException $e) {
|
||||||
var_dump($e->getErrors());
|
var_dump($e->getErrors());
|
||||||
}
|
}
|
||||||
-
|
|
||||||
lang: C#
|
|
||||||
source: |-
|
|
||||||
PetStore.v1.Pet pet = new PetStore.v1.Pet();
|
|
||||||
pet.setApiKey("your api key");
|
|
||||||
pet.petType = PetStore.v1.Pet.TYPE_DOG;
|
|
||||||
pet.id = 1;
|
|
||||||
pet.name = "Rex";
|
|
||||||
// set other fields
|
|
||||||
|
|
||||||
PetStoreResponse response = pet.update();
|
|
||||||
if (response.statusCode == HttpStatusCode.OK)
|
|
||||||
{
|
|
||||||
// Successfully updated
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// Something wrong -- check response for errors
|
|
||||||
Console.WriteLine(response.getRawResponse());
|
|
||||||
}
|
|
||||||
security:
|
security:
|
||||||
-
|
-
|
||||||
petstore_auth:
|
petstore_auth:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user