Beispiel #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSuccessfulSelfServiceRegistrationWithoutBrowser" /> class.
 /// </summary>
 /// <param name="identity">identity (required).</param>
 /// <param name="session">session.</param>
 /// <param name="sessionToken">The Session Token  This field is only set when the session hook is configured as a post-registration hook.  A session token is equivalent to a session cookie, but it can be sent in the HTTP Authorization Header:  Authorization: bearer ${session-token}  The session token is only issued for API flows, not for Browser flows!.</param>
 public KratosSuccessfulSelfServiceRegistrationWithoutBrowser(KratosIdentity identity = default(KratosIdentity), KratosSession session = default(KratosSession), string sessionToken = default(string))
 {
     // to ensure "identity" is required (not null)
     this.Identity             = identity ?? throw new ArgumentNullException("identity is a required property for KratosSuccessfulSelfServiceRegistrationWithoutBrowser and cannot be null");
     this.Session              = session;
     this.SessionToken         = sessionToken;
     this.AdditionalProperties = new Dictionary <string, object>();
 }
Beispiel #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosRegistrationViaApiResponse" /> class.
 /// </summary>
 /// <param name="identity">identity (required).</param>
 /// <param name="session">session.</param>
 /// <param name="sessionToken">The Session Token  This field is only set when the session hook is configured as a post-registration hook.  A session token is equivalent to a session cookie, but it can be sent in the HTTP Authorization Header:  Authorization: bearer ${session-token}  The session token is only issued for API flows, not for Browser flows! (required).</param>
 public KratosRegistrationViaApiResponse(KratosIdentity identity = default(KratosIdentity), KratosSession session = default(KratosSession), string sessionToken = default(string))
 {
     // to ensure "identity" is required (not null)
     this.Identity = identity ?? throw new ArgumentNullException("identity is a required property for KratosRegistrationViaApiResponse and cannot be null");
     // to ensure "sessionToken" is required (not null)
     this.SessionToken = sessionToken ?? throw new ArgumentNullException("sessionToken is a required property for KratosRegistrationViaApiResponse and cannot be null");
     this.Session      = session;
 }
Beispiel #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSettingsFlow" /> class.
 /// </summary>
 /// <param name="active">Active, if set, contains the registration method that is being used. It is initially not set..</param>
 /// <param name="expiresAt">ExpiresAt is the time (UTC) when the flow expires. If the user still wishes to update the setting, a new flow has to be initiated. (required).</param>
 /// <param name="id">id (required).</param>
 /// <param name="identity">identity (required).</param>
 /// <param name="issuedAt">IssuedAt is the time (UTC) when the flow occurred. (required).</param>
 /// <param name="requestUrl">RequestURL is the initial URL that was requested from Ory Kratos. It can be used to forward information contained in the URL&#39;s path or query for example. (required).</param>
 /// <param name="state">state (required).</param>
 /// <param name="type">The flow type can either be &#x60;api&#x60; or &#x60;browser&#x60;..</param>
 /// <param name="ui">ui (required).</param>
 public KratosSettingsFlow(string active = default(string), DateTime expiresAt = default(DateTime), string id = default(string), KratosIdentity identity = default(KratosIdentity), DateTime issuedAt = default(DateTime), string requestUrl = default(string), string state = default(string), string type = default(string), KratosUiContainer ui = default(KratosUiContainer))
 {
     this.ExpiresAt = expiresAt;
     // to ensure "id" is required (not null)
     this.Id = id ?? throw new ArgumentNullException("id is a required property for KratosSettingsFlow and cannot be null");
     // to ensure "identity" is required (not null)
     this.Identity = identity ?? throw new ArgumentNullException("identity is a required property for KratosSettingsFlow and cannot be null");
     this.IssuedAt = issuedAt;
     // to ensure "requestUrl" is required (not null)
     this.RequestUrl = requestUrl ?? throw new ArgumentNullException("requestUrl is a required property for KratosSettingsFlow and cannot be null");
     // to ensure "state" is required (not null)
     this.State = state ?? throw new ArgumentNullException("state is a required property for KratosSettingsFlow and cannot be null");
     // to ensure "ui" is required (not null)
     this.Ui     = ui ?? throw new ArgumentNullException("ui is a required property for KratosSettingsFlow and cannot be null");
     this.Active = active;
     this.Type   = type;
     this.AdditionalProperties = new Dictionary <string, object>();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSettingsViaApiResponse" /> class.
 /// </summary>
 /// <param name="flow">flow (required).</param>
 /// <param name="identity">identity (required).</param>
 public KratosSettingsViaApiResponse(KratosSettingsFlow flow = default(KratosSettingsFlow), KratosIdentity identity = default(KratosIdentity))
 {
     // to ensure "flow" is required (not null)
     this.Flow = flow ?? throw new ArgumentNullException("flow is a required property for KratosSettingsViaApiResponse and cannot be null");
     // to ensure "identity" is required (not null)
     this.Identity             = identity ?? throw new ArgumentNullException("identity is a required property for KratosSettingsViaApiResponse and cannot be null");
     this.AdditionalProperties = new Dictionary <string, object>();
 }
Beispiel #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSession" /> class.
 /// </summary>
 /// <param name="active">active.</param>
 /// <param name="authenticatedAt">authenticatedAt (required).</param>
 /// <param name="expiresAt">expiresAt (required).</param>
 /// <param name="id">id (required).</param>
 /// <param name="identity">identity (required).</param>
 /// <param name="issuedAt">issuedAt (required).</param>
 public KratosSession(bool active = default(bool), DateTime authenticatedAt = default(DateTime), DateTime expiresAt = default(DateTime), string id = default(string), KratosIdentity identity = default(KratosIdentity), DateTime issuedAt = default(DateTime))
 {
     this.AuthenticatedAt = authenticatedAt;
     this.ExpiresAt       = expiresAt;
     // to ensure "id" is required (not null)
     this.Id = id ?? throw new ArgumentNullException("id is a required property for KratosSession and cannot be null");
     // to ensure "identity" is required (not null)
     this.Identity             = identity ?? throw new ArgumentNullException("identity is a required property for KratosSession and cannot be null");
     this.IssuedAt             = issuedAt;
     this.Active               = active;
     this.AdditionalProperties = new Dictionary <string, object>();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSuccessfulSelfServiceSettingsWithoutBrowser" /> class.
 /// </summary>
 /// <param name="flow">flow (required).</param>
 /// <param name="identity">identity (required).</param>
 public KratosSuccessfulSelfServiceSettingsWithoutBrowser(KratosSelfServiceSettingsFlow flow = default(KratosSelfServiceSettingsFlow), KratosIdentity identity = default(KratosIdentity))
 {
     // to ensure "flow" is required (not null)
     this.Flow = flow ?? throw new ArgumentNullException("flow is a required property for KratosSuccessfulSelfServiceSettingsWithoutBrowser and cannot be null");
     // to ensure "identity" is required (not null)
     this.Identity             = identity ?? throw new ArgumentNullException("identity is a required property for KratosSuccessfulSelfServiceSettingsWithoutBrowser and cannot be null");
     this.AdditionalProperties = new Dictionary <string, object>();
 }
Beispiel #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSession" /> class.
 /// </summary>
 /// <param name="active">Active state. If false the session is no longer active..</param>
 /// <param name="authenticatedAt">The Session Authentication Timestamp  When this session was authenticated at. If multi-factor authentication was used this is the time when the last factor was authenticated (e.g. the TOTP code challenge was completed)..</param>
 /// <param name="authenticationMethods">A list of authenticators which were used to authenticate the session..</param>
 /// <param name="authenticatorAssuranceLevel">authenticatorAssuranceLevel.</param>
 /// <param name="expiresAt">The Session Expiry  When this session expires at..</param>
 /// <param name="id">id (required).</param>
 /// <param name="identity">identity (required).</param>
 /// <param name="issuedAt">The Session Issuance Timestamp  When this session was issued at. Usually equal or close to &#x60;authenticated_at&#x60;..</param>
 public KratosSession(bool active = default(bool), DateTime authenticatedAt = default(DateTime), List <KratosSessionAuthenticationMethod> authenticationMethods = default(List <KratosSessionAuthenticationMethod>), KratosAuthenticatorAssuranceLevel authenticatorAssuranceLevel = default(KratosAuthenticatorAssuranceLevel), DateTime expiresAt = default(DateTime), string id = default(string), KratosIdentity identity = default(KratosIdentity), DateTime issuedAt = default(DateTime))
 {
     // to ensure "id" is required (not null)
     if (id == null)
     {
         throw new ArgumentNullException("id is a required property for KratosSession and cannot be null");
     }
     this.Id = id;
     // to ensure "identity" is required (not null)
     if (identity == null)
     {
         throw new ArgumentNullException("identity is a required property for KratosSession and cannot be null");
     }
     this.Identity                    = identity;
     this.Active                      = active;
     this.AuthenticatedAt             = authenticatedAt;
     this.AuthenticationMethods       = authenticationMethods;
     this.AuthenticatorAssuranceLevel = authenticatorAssuranceLevel;
     this.ExpiresAt                   = expiresAt;
     this.IssuedAt                    = issuedAt;
     this.AdditionalProperties        = new Dictionary <string, object>();
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosProfileManagementRequest" /> class.
 /// </summary>
 /// <param name="expiresAt">ExpiresAt is the time (UTC) when the request expires. If the user still wishes to update the profile, a new request has to be initiated..</param>
 /// <param name="form">form.</param>
 /// <param name="id">id.</param>
 /// <param name="identity">identity.</param>
 /// <param name="issuedAt">IssuedAt is the time (UTC) when the request occurred..</param>
 /// <param name="requestUrl">RequestURL is the initial URL that was requested from ORY Kratos. It can be used to forward information contained in the URL&#39;s path or query for example..</param>
 /// <param name="updateSuccessful">UpdateSuccessful, if true, indicates that the profile has been updated successfully with the provided data. Done will stay true when repeatedly checking. If set to true, done will revert back to false only when a request with invalid (e.g. \&quot;please use a valid phone number\&quot;) data was sent..</param>
 public KratosProfileManagementRequest(DateTime expiresAt = default(DateTime), KratosForm form = default(KratosForm), string id = default(string), KratosIdentity identity = default(KratosIdentity), DateTime issuedAt = default(DateTime), string requestUrl = default(string), bool updateSuccessful = default(bool))
 {
     this.ExpiresAt        = expiresAt;
     this.Form             = form;
     this.Id               = id;
     this.Identity         = identity;
     this.IssuedAt         = issuedAt;
     this.RequestUrl       = requestUrl;
     this.UpdateSuccessful = updateSuccessful;
 }
Beispiel #9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="KratosSettingsFlow" /> class.
 /// </summary>
 /// <param name="active">Active, if set, contains the registration method that is being used. It is initially not set..</param>
 /// <param name="expiresAt">ExpiresAt is the time (UTC) when the flow expires. If the user still wishes to update the setting, a new flow has to be initiated. (required).</param>
 /// <param name="id">id (required).</param>
 /// <param name="identity">identity (required).</param>
 /// <param name="issuedAt">IssuedAt is the time (UTC) when the flow occurred. (required).</param>
 /// <param name="messages">messages.</param>
 /// <param name="methods">Methods contains context for all enabled registration methods. If a settings flow has been processed, but for example the first name is empty, this will contain error messages. (required).</param>
 /// <param name="requestUrl">RequestURL is the initial URL that was requested from ORY Kratos. It can be used to forward information contained in the URL&#39;s path or query for example. (required).</param>
 /// <param name="state">state (required).</param>
 /// <param name="type">The flow type can either be &#x60;api&#x60; or &#x60;browser&#x60;..</param>
 public KratosSettingsFlow(string active = default(string), DateTime expiresAt = default(DateTime), string id = default(string), KratosIdentity identity = default(KratosIdentity), DateTime issuedAt = default(DateTime), List <KratosMessage> messages = default(List <KratosMessage>), Dictionary <string, KratosSettingsFlowMethod> methods = default(Dictionary <string, KratosSettingsFlowMethod>), string requestUrl = default(string), string state = default(string), string type = default(string))
 {
     this.ExpiresAt = expiresAt;
     // to ensure "id" is required (not null)
     this.Id = id ?? throw new ArgumentNullException("id is a required property for KratosSettingsFlow and cannot be null");
     // to ensure "identity" is required (not null)
     this.Identity = identity ?? throw new ArgumentNullException("identity is a required property for KratosSettingsFlow and cannot be null");
     this.IssuedAt = issuedAt;
     // to ensure "methods" is required (not null)
     this.Methods = methods ?? throw new ArgumentNullException("methods is a required property for KratosSettingsFlow and cannot be null");
     // to ensure "requestUrl" is required (not null)
     this.RequestUrl = requestUrl ?? throw new ArgumentNullException("requestUrl is a required property for KratosSettingsFlow and cannot be null");
     // to ensure "state" is required (not null)
     this.State    = state ?? throw new ArgumentNullException("state is a required property for KratosSettingsFlow and cannot be null");
     this.Active   = active;
     this.Messages = messages;
     this.Type     = type;
 }