Skip to content

tayleighr/moxiworks-dotnet

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

moxiworks-dotnet Codacy Badge

.net Standards 2.0 SDK for interacting with Moxi Works API.

Getting Started

Prerequisites

Access to NuGet Package Manger or .NET CLI

Installing

Install through Package Manager

PM> Install-Package MoxiWorks.Platform -Version 1.2.7

Install through .NET CLI

> dotnet add package MoxiWorks.Platform --version 1.2.7

ASP.NET Core

MVC Application Example Here.

appsettings.json

{
    "AppSettings": {
        "Secret": "the_secret",
        "Identifier": "the_identifier"
    }
}

.Net Core requires AppSettings to be passed to the ConfigurationManager in Startup.cs .

public class Startup
{
   public Startup(IConfiguration configuration)
   {
       Configuration = configuration;
       ConfigurationManager.AppSettings["Secret"] = Configuration["Secret"];
       ConfigurationManager.AppSettings["Identifier"] = Configuration["Identifier"];
   }

}

Inject services as singletons

public void ConfigureServices(IServiceCollection services)
{

    services.AddSingleton<IMoxiWorksClient, MoxiWorksClient>();
    services.AddSingleton<IAgentService, AgentService>();
    services.AddSingleton<ICompanyService, CompanyService>();
    services.AddSingleton<IOfficeService, OfficeService>();
    services.AddMvc();

}

Built With

Versioning

For the versions available, see the tags on this repository.

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C# 100.0%