Skip to content

Commit

Permalink
chore: update autogenerated files
Browse files Browse the repository at this point in the history
  • Loading branch information
link2xt committed Dec 2, 2023
1 parent 31481fa commit 38f6a1d
Show file tree
Hide file tree
Showing 6 changed files with 242 additions and 146 deletions.
134 changes: 69 additions & 65 deletions examples/axum/typescript/generated/jsonrpc.ts
Original file line number Diff line number Diff line change
@@ -1,83 +1,87 @@
// AUTO-GENERATED by typescript-type-def

export type JSONValue=(null|boolean|number|string|(JSONValue)[]|{[key:string]:JSONValue;});
export type Params=((JSONValue)[]|Record<string,JSONValue>);
export type U32=number;
export type JSONValue = (null | boolean | number | string | (JSONValue)[] | {
[key:string]:JSONValue;
});
export type Params = ((JSONValue)[] | Record<string, JSONValue>);
export type U32 = number;

/**
* Request identifier as found in Request and Response objects.
*/
export type Id=(U32|string);
export type Id = (U32 | string);

/**
* Request object.
*/
export type Request=
/**
* Request object.
*/
{
/**
* JSON-RPC protocol version.
*/
"jsonrpc"?:"2.0";
/**
* Name of the method to be invoked.
*/
"method":string;
/**
* Method parameters.
*/
"params"?:Params;
/**
* Request identifier.
*/
"id"?:Id;};
export type I32=number;
export type Request = {

/**
* JSON-RPC protocol version.
*/
"jsonrpc"?: "2.0";

/**
* Name of the method to be invoked.
*/
"method": string;

/**
* Method parameters.
*/
"params"?: Params;

/**
* Request identifier.
*/
"id"?: Id;
};
export type I32 = number;

/**
* Error object returned in response to a failed RPC call.
*/
export type Error=
/**
* Error object returned in response to a failed RPC call.
*/
{
/**
* Error code indicating the error type.
*/
"code":I32;
/**
* Short error description.
*/
"message":string;
/**
* Additional information about the error.
*/
"data"?:JSONValue;};
export type Error = {

/**
* Error code indicating the error type.
*/
"code": I32;

/**
* Short error description.
*/
"message": string;

/**
* Additional information about the error.
*/
"data"?: JSONValue;
};

/**
* Response object.
*/
export type Response=
/**
* Response object.
*/
{
/**
* JSON-RPC protocol version.
*/
"jsonrpc":"2.0";
/**
* Request identifier.
*/
"id":(Id|null);
/**
* Return value of the method.
*/
"result"?:JSONValue;
/**
* Error occured during the method invocation.
*/
"error"?:Error;};
export type Message=(Request|Response);
export type Response = {

/**
* JSON-RPC protocol version.
*/
"jsonrpc": "2.0";

/**
* Request identifier.
*/
"id": (Id | null);

/**
* Return value of the method.
*/
"result"?: JSONValue;

/**
* Error occured during the method invocation.
*/
"error"?: Error;
};
export type Message = (Request | Response);
12 changes: 9 additions & 3 deletions examples/axum/typescript/generated/types.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
// AUTO-GENERATED by typescript-type-def

export type User={"name":string;"color":string;};
export type ChatMessage={"content":string;"user":User;};
export type Usize=number;
export type User = {
"name": string;
"color": string;
};
export type ChatMessage = {
"content": string;
"user": User;
};
export type Usize = number;
134 changes: 69 additions & 65 deletions examples/tide/typescript/generated/jsonrpc.ts
Original file line number Diff line number Diff line change
@@ -1,83 +1,87 @@
// AUTO-GENERATED by typescript-type-def

export type JSONValue=(null|boolean|number|string|(JSONValue)[]|{[key:string]:JSONValue;});
export type Params=((JSONValue)[]|Record<string,JSONValue>);
export type U32=number;
export type JSONValue = (null | boolean | number | string | (JSONValue)[] | {
[key:string]:JSONValue;
});
export type Params = ((JSONValue)[] | Record<string, JSONValue>);
export type U32 = number;

/**
* Request identifier as found in Request and Response objects.
*/
export type Id=(U32|string);
export type Id = (U32 | string);

/**
* Request object.
*/
export type Request=
/**
* Request object.
*/
{
/**
* JSON-RPC protocol version.
*/
"jsonrpc"?:"2.0";
/**
* Name of the method to be invoked.
*/
"method":string;
/**
* Method parameters.
*/
"params"?:Params;
/**
* Request identifier.
*/
"id"?:Id;};
export type I32=number;
export type Request = {

/**
* JSON-RPC protocol version.
*/
"jsonrpc"?: "2.0";

/**
* Name of the method to be invoked.
*/
"method": string;

/**
* Method parameters.
*/
"params"?: Params;

/**
* Request identifier.
*/
"id"?: Id;
};
export type I32 = number;

/**
* Error object returned in response to a failed RPC call.
*/
export type Error=
/**
* Error object returned in response to a failed RPC call.
*/
{
/**
* Error code indicating the error type.
*/
"code":I32;
/**
* Short error description.
*/
"message":string;
/**
* Additional information about the error.
*/
"data"?:JSONValue;};
export type Error = {

/**
* Error code indicating the error type.
*/
"code": I32;

/**
* Short error description.
*/
"message": string;

/**
* Additional information about the error.
*/
"data"?: JSONValue;
};

/**
* Response object.
*/
export type Response=
/**
* Response object.
*/
{
/**
* JSON-RPC protocol version.
*/
"jsonrpc":"2.0";
/**
* Request identifier.
*/
"id":(Id|null);
/**
* Return value of the method.
*/
"result"?:JSONValue;
/**
* Error occured during the method invocation.
*/
"error"?:Error;};
export type Message=(Request|Response);
export type Response = {

/**
* JSON-RPC protocol version.
*/
"jsonrpc": "2.0";

/**
* Request identifier.
*/
"id": (Id | null);

/**
* Return value of the method.
*/
"result"?: JSONValue;

/**
* Error occured during the method invocation.
*/
"error"?: Error;
};
export type Message = (Request | Response);
12 changes: 9 additions & 3 deletions examples/tide/typescript/generated/types.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
// AUTO-GENERATED by typescript-type-def

export type User={"name":string;"color":string;};
export type ChatMessage={"content":string;"user":User;};
export type Usize=number;
export type User = {
"name": string;
"color": string;
};
export type ChatMessage = {
"content": string;
"user": User;
};
export type Usize = number;
Loading

0 comments on commit 38f6a1d

Please sign in to comment.