Module Token.Response

type token_type =
  1. | Bearer
type t = {
  1. token_type : token_type;
  2. scope : Scopes.t list;
  3. expires_in : int option;
  4. access_token : string option;
  5. refresh_token : string option;
  6. id_token : string option;
}

A token response

val make : ?token_type:token_type -> ?scope:Scopes.t list -> ?expires_in:int -> ?access_token:string -> ?refresh_token:string -> ?id_token:string -> unit -> t
val of_yojson : Yojson.Safe.t -> (t, [> `Msg of string ]) Stdlib.result
val of_string : string -> (t, [> `Msg of string ]) Stdlib.result
val to_yojson : t -> Yojson.Safe.t
val validate : ?clock_tolerance:int -> ?nonce:string -> jwks:Jose.Jwks.t -> client:Client.t -> discovery:Discover.t -> t -> (t, [> IDToken.validation_error ]) Stdlib.result