-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
4 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
|
||
# About | ||
|
||
This library contains the official auto generated models to represent a [TypeAPI](https://typeapi.org/) or [TypeSchema](https://typeschema.org/) specification. | ||
The model classes can be used to build i.e. code generators or other tools which need to process a TypeAPI or TypeSchema specification. | ||
This library contains the official auto generated models to represent a [TypeAPI](https://typeapi.org/) specification. | ||
The model classes can be used to build i.e. code generators or other tools which need to process a TypeAPI specification. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"typehub/typeapi":{"operations":[],"definitions":{"Argument":{"description":"","type":"struct","properties":{"contentType":{"description":"In case the data is not a JSON payload which you can describe with a schema you can select a content type","type":"string"},"in":{"description":"The location where the value can be found either in the path, query, header or body. If you choose path, then your path must have a fitting variable path fragment","type":"string"},"name":{"description":"Optional the actual path, query or header name. If not provided the key of the argument map is used","type":"string"},"schema":{"description":"","type":"reference","target":"typeschema:PropertyType"}}},"Operation":{"description":"","type":"struct","properties":{"arguments":{"description":"All arguments provided to this operation. Each argument is mapped to a location from the HTTP request i.e. query or body","type":"map","schema":{"type":"reference","target":"Argument"}},"authorization":{"description":"Indicates whether this operation needs authorization, if set to false the client will not send an authorization header, default it is true","type":"boolean"},"description":{"description":"A short description of this operation. The generated code will include this description at the method so it is recommend to use simple alphanumeric characters and no new lines","type":"string"},"method":{"description":"The HTTP method which is associated with this operation, must be a valid HTTP method i.e. GET, POST, PUT etc.","type":"string"},"path":{"description":"The HTTP path which is associated with this operation. A path can also include variable path fragments i.e. /my/path/:year then you can map the variable year path fragment to a specific argument","type":"string"},"return":{"description":"The return type of this operation. The return has also an assigned HTTP success status code which is by default 200","type":"reference","target":"Response"},"security":{"description":"An array of scopes which are required to access this operation","type":"array","schema":{"type":"string"}},"stability":{"description":"Indicates the stability of this operation: 0 - Deprecated, 1 - Experimental, 2 - Stable, 3 - Legacy. If not explicit provided the operation is by default experimental.","type":"integer"},"tags":{"description":"Optional an array of tags to group operations","type":"array","schema":{"type":"string"}},"throws":{"description":"All exceptional states which can occur in case the operation fails. Each exception is assigned to an HTTP error status code","type":"array","schema":{"type":"reference","target":"Response"}}}},"Response":{"description":"","type":"struct","properties":{"code":{"description":"The associated HTTP response code. For error responses it is possible to use the 499, 599 or 999 status code to catch all errors","type":"integer"},"contentType":{"description":"In case the data is not a JSON payload which you can describe with a schema you can select a content type","type":"string"},"schema":{"description":"","type":"reference","target":"typeschema:PropertyType"}}},"Security":{"description":"","type":"struct","base":true,"properties":{"type":{"description":"The global security type of the API must be one of: httpBasic, httpBearer, apiKey or oauth2","type":"string"}},"discriminator":"type","mapping":{"SecurityApiKey":"apiKey","SecurityHttpBasic":"httpBasic","SecurityHttpBearer":"httpBearer","SecurityOAuth":"oauth2"}},"SecurityApiKey":{"type":"struct","parent":{"type":"reference","target":"Security"},"properties":{"in":{"description":"Must be either \"header\" or \"query\"","type":"string"},"name":{"description":"The name of the header or query parameter i.e. \"X-Api-Key\"","type":"string"}}},"SecurityHttpBasic":{"type":"struct","parent":{"type":"reference","target":"Security"}},"SecurityHttpBearer":{"type":"struct","parent":{"type":"reference","target":"Security"}},"SecurityOAuth":{"type":"struct","parent":{"type":"reference","target":"Security"},"properties":{"authorizationUrl":{"description":"Optional the OAuth2 authorization endpoint","type":"string"},"scopes":{"description":"Optional OAuth2 scopes","type":"array","schema":{"type":"string"}},"tokenUrl":{"description":"The OAuth2 token endpoint","type":"string"}}},"TypeAPI":{"description":"The TypeAPI Root","type":"struct","parent":{"type":"reference","target":"typeschema:TypeSchema"},"properties":{"baseUrl":{"description":"Optional the base url of the service, if provided the user does not need to provide a base url for your client","type":"string"},"operations":{"description":"A map of operations which are provided by the API. The key of the operation should be separated by a dot to group operations into logical units i.e. product.getAll or enterprise.product.execute","type":"map","schema":{"type":"reference","target":"Operation"}},"security":{"description":"Describes the authorization mechanism which is used by your API","type":"reference","target":"Security"}}},"typeschema:AnyPropertyType":{"description":"Represents an any value which allows any kind of value","type":"struct","parent":{"type":"reference","target":"typeschema:PropertyType"}},"typeschema:ArrayDefinitionType":{"description":"Represents an array which contains a dynamic list of values of the same type","type":"struct","parent":{"type":"reference","target":"typeschema:CollectionDefinitionType"}},"typeschema:ArrayPropertyType":{"description":"Represents an array which contains a dynamic list of values of the same type","type":"struct","parent":{"type":"reference","target":"typeschema:CollectionPropertyType"}},"typeschema:BooleanPropertyType":{"description":"Represents a boolean value","type":"struct","parent":{"type":"reference","target":"typeschema:ScalarPropertyType"}},"typeschema:CollectionDefinitionType":{"description":"Base collection type","type":"struct","parent":{"type":"reference","target":"typeschema:DefinitionType"},"base":true,"properties":{"schema":{"description":"","type":"reference","target":"typeschema:PropertyType"},"type":{"description":"","type":"string"}},"discriminator":"type","mapping":{"typeschema:ArrayDefinitionType":"array","typeschema:MapDefinitionType":"map"}},"typeschema:CollectionPropertyType":{"description":"Base collection property type","type":"struct","parent":{"type":"reference","target":"typeschema:PropertyType"},"base":true,"properties":{"schema":{"description":"","type":"reference","target":"typeschema:PropertyType"},"type":{"description":"","type":"string"}},"discriminator":"type","mapping":{"typeschema:ArrayPropertyType":"array","typeschema:MapPropertyType":"map"}},"typeschema:DefinitionType":{"description":"Base definition type","type":"struct","base":true,"properties":{"deprecated":{"description":"","type":"boolean"},"description":{"description":"","type":"string"},"type":{"description":"","type":"string"}},"discriminator":"type","mapping":{"typeschema:ArrayDefinitionType":"array","typeschema:MapDefinitionType":"map","typeschema:StructDefinitionType":"struct"}},"typeschema:GenericPropertyType":{"description":"Represents a generic value which can be replaced with a dynamic type","type":"struct","parent":{"type":"reference","target":"typeschema:PropertyType"},"properties":{"name":{"description":"The name of the generic, it is recommended to use common generic names like T or TValue. These generics can then be replaced on usage with a concrete type through the template property at a reference.","type":"string"}}},"typeschema:IntegerPropertyType":{"description":"Represents an integer value","type":"struct","parent":{"type":"reference","target":"typeschema:ScalarPropertyType"}},"typeschema:MapDefinitionType":{"description":"Represents a map which contains a dynamic set of key value entries of the same type","type":"struct","parent":{"type":"reference","target":"typeschema:CollectionDefinitionType"}},"typeschema:MapPropertyType":{"description":"Represents a map which contains a dynamic set of key value entries of the same type","type":"struct","parent":{"type":"reference","target":"typeschema:CollectionPropertyType"}},"typeschema:NumberPropertyType":{"description":"Represents a float value","type":"struct","parent":{"type":"reference","target":"typeschema:ScalarPropertyType"}},"typeschema:PropertyType":{"description":"Base property type","type":"struct","base":true,"properties":{"deprecated":{"description":"","type":"boolean"},"description":{"description":"","type":"string"},"nullable":{"description":"","type":"boolean"},"type":{"description":"","type":"string"}},"discriminator":"type","mapping":{"typeschema:AnyPropertyType":"any","typeschema:ArrayPropertyType":"array","typeschema:BooleanPropertyType":"boolean","typeschema:GenericPropertyType":"generic","typeschema:IntegerPropertyType":"integer","typeschema:MapPropertyType":"map","typeschema:NumberPropertyType":"number","typeschema:ReferencePropertyType":"reference","typeschema:StringPropertyType":"string"}},"typeschema:ReferencePropertyType":{"description":"Represents a reference to a definition type","type":"struct","parent":{"type":"reference","target":"typeschema:PropertyType"},"properties":{"target":{"description":"The target type, this must be a key which is available under the definitions keyword.","type":"string"},"template":{"description":"A map where the key is the name of the generic and the value must point to a key under the definitions keyword. This can be used in case the target points to a type which contains generics, then it is possible to replace those generics with a concrete type.","type":"map","schema":{"type":"string"}}}},"typeschema:ScalarPropertyType":{"description":"Base scalar property type","type":"struct","parent":{"type":"reference","target":"typeschema:PropertyType"},"base":true,"properties":{"type":{"description":"","type":"string"}},"discriminator":"type","mapping":{"typeschema:BooleanPropertyType":"boolean","typeschema:IntegerPropertyType":"integer","typeschema:NumberPropertyType":"number","typeschema:StringPropertyType":"string"}},"typeschema:StringPropertyType":{"description":"Represents a string value","type":"struct","parent":{"type":"reference","target":"typeschema:ScalarPropertyType"},"properties":{"format":{"description":"Optional describes the format of the string. Supported are the following types: date, date-time and time. A code generator may use a fitting data type to represent such a format, if not supported it should fall back to a string.","type":"string"}}},"typeschema:StructDefinitionType":{"description":"A struct represents a class/structure with a fix set of defined properties.","type":"struct","parent":{"type":"reference","target":"typeschema:DefinitionType"},"properties":{"base":{"description":"Indicates whether this is a base structure, default is false. If true the structure is used a base type, this means it is not possible to create an instance from this structure.","type":"boolean"},"discriminator":{"description":"Optional the property name of a discriminator property. This should be only used in case this is also a base structure.","type":"string"},"mapping":{"description":"In case a discriminator is configured it is required to configure a mapping. The mapping is a map where the key is the type name and the value the actual discriminator type value.","type":"map","schema":{"type":"string"}},"parent":{"description":"Defines a parent type for this structure. Some programming languages like Go do not support the concept of an extends, in this case the code generator simply copies all properties into this structure.","type":"reference","target":"typeschema:ReferencePropertyType"},"properties":{"description":"Contains a map of available properties for this struct.","type":"map","schema":{"type":"reference","target":"typeschema:PropertyType"}}}},"typeschema:TypeSchema":{"description":"TypeSchema specification","type":"struct","properties":{"definitions":{"description":"","type":"map","schema":{"type":"reference","target":"typeschema:DefinitionType"}},"import":{"description":"Through the import keyword it is possible to import other TypeSchema documents. It contains a map where the key is the namespace and the value points to a remote document. The value is a URL and a code generator should support at least the following schemes: file, http, https.","type":"map","schema":{"type":"string"}},"root":{"description":"Specifies the root type of your specification.","type":"string"}}}}}} |