Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

87 Commits

Repository files navigation

OneLogin Dot Net Client

This is a portable library for consuming the OneLogin REST-API in (almost) any C# application. If you find bugs or have any suggestions, feel free to create an issue.

Quickstart

Including OneLogin Dot Net Client

The OneLogin API is avaiable through NuGet:

> Install-Package OneLogin.API

Status

Nuget

Supported Plattforms

OneLogin API is built on top of the new .NET Standard targeting netstandard versions 1.3 - therefore it should work on the following plaforms:

  • .NET Framework 4.6 and newer
  • .NET Core 1.1 or newer
  • Universal Windows Platform (uap)
  • Windows 8.0 and newer
  • Windows Phone (WinRT, not Silverlight)
  • Mono / Xamarin

Quickstart: Using the API Wrapper

// Initializevarclient=newOneLoginClient("Your Onelogin client id","Your Onelogin client secret");

That's it! The token will be generated and managed for you by the OneLoginClient.

// UsersvaruserResponse=await_oneLoginClient.GetUserById(userId);varuserAppsResponse=await_oneLoginClient.GetAppsForUser(userId);// EventsvareventTypesResponse=awaitclient.GetEventTypes();vareventById=(await_oneLoginClient.GetEventById(eventId);varmanyEvents=await_oneLoginClient.CreateEvent(newCreateEventRequest{EventTypeId=eventTypeId,UserId=userId,AppId=appId,});// Interpolate Event datavareventsResponse=await_oneLoginClient.GetEvents());varallEventTypes=await_oneLoginClient.GetEventTypes();varresults=eventsResponse.SelectMany(response =>response.Data).Select(@event =>@event.InterpolateEvent(allEventTypes.Data)).ToList();

Contribution Guidelines

We're very happy to get input from the community on this project! To keep the code clean we ask you to follow a few simple contribution guidelines.

First, create an issue describing what feature you want to add or what problem you're trying to solve, just to make sure no one is already working on that. That also gives us a chance to debate whether a feature is wihtin the scope of this project.

Second, please try to stick to the official C# coding guidelines. https://msdn.microsoft.com/en-us/library/ms229002(v=vs.110).aspx

Also, make sure to write some tests covering your new or modified code.

About

A .net library for accessing the Onelogin management API

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages