typescript client generation wip
This commit is contained in:
@@ -76,8 +76,32 @@ const actor_spec = specification.ActorSpecification{
|
||||
]
|
||||
},
|
||||
specification.ActorMethod{
|
||||
name: 'createPet'
|
||||
name: 'newPet'
|
||||
summary: 'Create a new pet'
|
||||
parameters: [
|
||||
openrpc.ContentDescriptor{
|
||||
name: 'result'
|
||||
description: 'The response of the operation.'
|
||||
required: true
|
||||
schema: jsonschema.SchemaRef(jsonschema.Schema{
|
||||
id: 'pet'
|
||||
title: 'Pet'
|
||||
typ: 'object'
|
||||
properties: {
|
||||
'id': jsonschema.SchemaRef(jsonschema.Reference{
|
||||
ref: '#/components/schemas/PetId'
|
||||
}),
|
||||
'name': jsonschema.SchemaRef(jsonschema.Schema{
|
||||
typ: 'string'
|
||||
}),
|
||||
'tag': jsonschema.SchemaRef(jsonschema.Schema{
|
||||
typ: 'string'
|
||||
})
|
||||
}
|
||||
required: ['id', 'name']
|
||||
})
|
||||
}
|
||||
]
|
||||
example: openrpc.ExamplePairing{
|
||||
result: openrpc.ExampleRef(openrpc.Example{
|
||||
name: 'Example response'
|
||||
@@ -85,9 +109,14 @@ const actor_spec = specification.ActorSpecification{
|
||||
})
|
||||
}
|
||||
result: openrpc.ContentDescriptor{
|
||||
name: 'result'
|
||||
description: 'The response of the operation.'
|
||||
name: 'petId'
|
||||
summary: 'ID of the created pet'
|
||||
description: 'ID of the created pet'
|
||||
required: true
|
||||
schema: jsonschema.SchemaRef(jsonschema.Schema{
|
||||
...jsonschema.schema_u32,
|
||||
example: 1
|
||||
})
|
||||
}
|
||||
errors: [
|
||||
openrpc.ErrorSpec{
|
||||
|
||||
Reference in New Issue
Block a user