Example #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TokenInfo" /> class.
 /// </summary>
 /// <param name="Organization">The current organization.</param>
 /// <param name="HomeOrganization">The token&#39;s home organization.</param>
 /// <param name="AuthorizedScope">The list of scopes authorized for the OAuth client.</param>
 /// <param name="OAuthClient">OAuthClient.</param>
 public TokenInfo(NamedEntity Organization = null, NamedEntity HomeOrganization = null, List <string> AuthorizedScope = null, OrgOAuthClient OAuthClient = null)
 {
     this.Organization     = Organization;
     this.HomeOrganization = HomeOrganization;
     this.AuthorizedScope  = AuthorizedScope;
     this.OAuthClient      = OAuthClient;
 }
        /// <summary>
        /// Initializes a new instance of the <see cref="TokenInfo" /> class.
        /// </summary>


        /// <param name="Organization">The current organization.</param>



        /// <param name="HomeOrganization">The token&#39;s home organization.</param>



        /// <param name="OAuthClient">OAuthClient.</param>


        public TokenInfo(NamedEntity Organization = null, NamedEntity HomeOrganization = null, OrgOAuthClient OAuthClient = null)
        {
            this.Organization = Organization;



            this.HomeOrganization = HomeOrganization;



            this.OAuthClient = OAuthClient;
        }
Example #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TrusteeBillingOverview" /> class.
 /// </summary>
 /// <param name="Name">Name.</param>
 /// <param name="Organization">Organization (required).</param>
 /// <param name="Currency">The currency type. (required).</param>
 /// <param name="EnabledProducts">The charge short names for products enabled during the specified period. (required).</param>
 /// <param name="SubscriptionType">The subscription type. (required).</param>
 /// <param name="RampPeriodStartDate">Date-time the ramp period starts. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="RampPeriodEndDate">Date-time the ramp period ends. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="BillingPeriodStartDate">Date-time the billing period started. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="BillingPeriodEndDate">Date-time the billing period ended. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="Usages">Usages for the specified period. (required).</param>
 /// <param name="ContractAmendmentDate">Date-time the contract was last amended. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="ContractEffectiveDate">Date-time the contract became effective. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="ContractEndDate">Date-time the contract ends. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="MinimumMonthlyAmount">Minimum amount that will be charged for the month.</param>
 /// <param name="InRampPeriod">InRampPeriod.</param>
 public TrusteeBillingOverview(string Name = null, NamedEntity Organization = null, string Currency = null, List <string> EnabledProducts = null, SubscriptionTypeEnum?SubscriptionType = null, DateTime?RampPeriodStartDate = null, DateTime?RampPeriodEndDate = null, DateTime?BillingPeriodStartDate = null, DateTime?BillingPeriodEndDate = null, List <SubscriptionOverviewUsage> Usages = null, DateTime?ContractAmendmentDate = null, DateTime?ContractEffectiveDate = null, DateTime?ContractEndDate = null, string MinimumMonthlyAmount = null, bool?InRampPeriod = null)
 {
     this.Name                   = Name;
     this.Organization           = Organization;
     this.Currency               = Currency;
     this.EnabledProducts        = EnabledProducts;
     this.SubscriptionType       = SubscriptionType;
     this.RampPeriodStartDate    = RampPeriodStartDate;
     this.RampPeriodEndDate      = RampPeriodEndDate;
     this.BillingPeriodStartDate = BillingPeriodStartDate;
     this.BillingPeriodEndDate   = BillingPeriodEndDate;
     this.Usages                 = Usages;
     this.ContractAmendmentDate  = ContractAmendmentDate;
     this.ContractEffectiveDate  = ContractEffectiveDate;
     this.ContractEndDate        = ContractEndDate;
     this.MinimumMonthlyAmount   = MinimumMonthlyAmount;
     this.InRampPeriod           = InRampPeriod;
 }
        /// <summary>
        /// Initializes a new instance of the <see cref="OrgOAuthClient" /> class.
        /// </summary>



        /// <param name="Name">The name of the OAuth client. (required).</param>



        /// <param name="DateCreated">Date this client was created. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>



        /// <param name="DateModified">Date this client was last modified. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>



        /// <param name="CreatedBy">User that created this client.</param>



        /// <param name="ModifiedBy">User that last modified this client.</param>



        /// <param name="AuthorizedGrantType">The OAuth Grant/Client type supported by this client. Code Authorization Grant/Client type - Preferred client type where the Client ID and Secret are required to create tokens. Used where the secret can be secured. Implicit grant type - Client ID only is required to create tokens. Used in browser and mobile apps where the secret can not be secured. SAML2-Bearer extension grant type - SAML2 assertion provider for user authentication at the token endpoint. Client Credential grant type - Used to created access tokens that are tied only to the client.  (required).</param>



        /// <param name="Organization">The  oauth client&#39;s organization..</param>


        public OrgOAuthClient(string Name = null, DateTime?DateCreated = null, DateTime?DateModified = null, UriReference CreatedBy = null, UriReference ModifiedBy = null, AuthorizedGrantTypeEnum?AuthorizedGrantType = null, NamedEntity Organization = null)
        {
            // to ensure "Name" is required (not null)
            if (Name == null)
            {
                throw new InvalidDataException("Name is a required property for OrgOAuthClient and cannot be null");
            }
            else
            {
                this.Name = Name;
            }



            // to ensure "AuthorizedGrantType" is required (not null)
            if (AuthorizedGrantType == null)
            {
                throw new InvalidDataException("AuthorizedGrantType is a required property for OrgOAuthClient and cannot be null");
            }
            else
            {
                this.AuthorizedGrantType = AuthorizedGrantType;
            }



            this.DateCreated = DateCreated;



            this.DateModified = DateModified;



            this.CreatedBy = CreatedBy;



            this.ModifiedBy = ModifiedBy;



            this.Organization = Organization;
        }
Example #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="OrgOAuthClient" /> class.
 /// </summary>
 /// <param name="Name">The name of the OAuth client. (required).</param>
 /// <param name="DateCreated">Date this client was created. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="DateModified">Date this client was last modified. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ.</param>
 /// <param name="CreatedBy">User that created this client.</param>
 /// <param name="ModifiedBy">User that last modified this client.</param>
 /// <param name="AuthorizedGrantType">The OAuth Grant/Client type supported by this client. Code Authorization Grant/Client type - Preferred client type where the Client ID and Secret are required to create tokens. Used where the secret can be secured. Implicit grant type - Client ID only is required to create tokens. Used in browser and mobile apps where the secret can not be secured. SAML2-Bearer extension grant type - SAML2 assertion provider for user authentication at the token endpoint. Client Credential grant type - Used to created access tokens that are tied only to the client.  (required).</param>
 /// <param name="Scope">The scope requested by this client. Scopes only apply to clients not using the client_credential grant.</param>
 /// <param name="RoleDivisions">Set of roles and their corresponding divisions associated with this client. Roles and divisions only apply to clients using the client_credential grant.</param>
 /// <param name="Organization">The  oauth client&#39;s organization..</param>
 public OrgOAuthClient(string Name = null, DateTime?DateCreated = null, DateTime?DateModified = null, UriReference CreatedBy = null, UriReference ModifiedBy = null, AuthorizedGrantTypeEnum?AuthorizedGrantType = null, List <string> Scope = null, List <RoleDivision> RoleDivisions = null, NamedEntity Organization = null)
 {
     this.Name                = Name;
     this.DateCreated         = DateCreated;
     this.DateModified        = DateModified;
     this.CreatedBy           = CreatedBy;
     this.ModifiedBy          = ModifiedBy;
     this.AuthorizedGrantType = AuthorizedGrantType;
     this.Scope               = Scope;
     this.RoleDivisions       = RoleDivisions;
     this.Organization        = Organization;
 }